[plt-scheme] PlaneT, plts and distributing software.

From: Eli Barzilay (eli at barzilay.org)
Date: Tue Oct 25 22:16:21 EDT 2005

On Oct 25, Yoav Goldberg wrote:
> > But it is installed as a collection.  The planet cache is used as
> > another item on the list of directories to search (when the
> > `planet' syntax is used to specify a module.)
> ... install it as a collection in a way typical users could find it,

Typical users "find it" in the same way they find other sources.
Either in the plt tree, or in the addons dir.


> and from then on require it with "lib".

Planet is specifically designed to not go back to requiring it with
"lib".  If you want the package to be

* installed in a "conventional" way,

* used with a plain "lib",

* works in a way that is independent of some server,

then you should use plan .plt files -- they do exactly that.


> > > While we're at it, I think it will also be extremly usefull to
> > > add the <path-of-main-file>/collects to the
> > > current-library-collection-paths[2] list, [...]
> > How do you determine the "main-file"?  You're talking about the
> > file that is used with "-f" -- what about multiple "-f"'s and
> > direct use of "load"?
> Choose a convention. "The first file specified with -f". Whatever.

That doesn't work.  MzScheme just sees a bunch of loads.  Adding
arcane command-line flags (like something that will load a file, and
add its directory to the collection paths) is *really* not needed...


> > If you want to just require some module relative to the current
> > one, then you should just use a relative name (which is always
> > relative to the source file that does the require).
> Let's say I use two collections, one of them references the other,
> and I'm not sure they will be available on the end-user machine. I
> also don't want to put files outside of "my" directory, esp. on
> Win32.

Make foo/bar.ss use (require "../blah/moo.ss") and tell users to put
"foo" and "blah" in the same place.  If you're not sure that one is
installed, then i don't see how you expect to make things work in any
way.


> > > [...] if I can't control the server, I'm not going to use it.
> > (That's a very 90's thing to say.)
> Not really, in this case.
> I'm not going to distribute software that relies on your server
> being up in order to work, because I can't control it.

That *is* a *very* 90's thing to say.  I use tens of servers every day
that I'm aware of, and that I don't control.  Planet was designed to
make it easy to distribute software for developers in a
near-transparent way.  It takes care getting new versions etc etc.  If
it doesn't fit your needs, you should distribute your packages as .plt
files, or design your own distributed planet alternative.

Like I said, if you don't want to rely on any server at all, and you
want to use a plain "(lib ...)" syntax, then you should use plain .plt
files -- I don't see anything that you want beyond .plt files, and
more than that -- you don't want any of the extra features of a
distributed system.

-- 
          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                  http://www.barzilay.org/                 Maze is Life!


Posted on the users mailing list.