chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Chicken-setup redesign (was: Re: [Chicken-users] Re: getopt, getopt_


From: Mario Domenech Goulart
Subject: Re: Chicken-setup redesign (was: Re: [Chicken-users] Re: getopt, getopt_long?)
Date: 11 Jul 2008 08:55:56 -0300
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Hi folks,

On Fri, 11 Jul 2008 09:32:34 +0200 Peter Bex <address@hidden> wrote:

> On Fri, Jul 11, 2008 at 08:39:21AM +0200, felix winkelmann wrote:
> > On Thu, Jul 10, 2008 at 7:23 PM, Peter Bex <address@hidden> wrote:
> > > On Thu, Jul 10, 2008 at 02:41:27PM +0200, Peter Bex wrote:
> > >> Of course, this would also require the possibility of loading a
> > >> particular version of a library.  I propose this syntax:
> > >>
> > >> (require-library foo (bar 1.2) (qux 1))
> > >>
> > >> This requires the latest installed version of foo (whatever that is),
> > >> and version 1.2 of bar.  From qux the latest installed minor version
> > >> with major version 1 is required (so, if you have 1.1 and 1.2 installed,
> > >> it will pick 1.2).  These semantics match those of the 'versions' egg,
> > >> I think.
> > >
> > > On second thought, the syntax above is needlessly complex.
> > >
> > > (require-library foo bar-1.2 qux-1) is much more straightforward and
> > > maps _directly_ to the code in the 'versions' egg, too.  It also reserves
> > > the "structured library names" like (bar ..) for future enhancements.
> > 
> > Indeed, the list structures are already used ("(srfi 1 2 3)", etc.). There
> > even is a "(version ...)" feature, but I forgot what it does (;-). The only
> > problem is searching for the highest sub-version, which will require
> > comparison of version files and obtaining directory listings. This will
> > have to happen at runtime and it would be unfortunate to make every
> > program depend on the posix unit.
> 
> How about the Unix approach of maintaining symlinks?  On Windows one could
> use the Registry.  Or to keep things simple, chicken-setup could just
> maintain a simple file that contains lists of installed egg versions.

That looks good.  If we don't want to play with Windows registry and
Unix symlinks, couldn't chicken-setup, when installing a `foo' egg,
pick the highest version and generate a foo.scm containing something
like:

   (require-library foo-1.2)

Considering 1.2 is the highest version number for the foo egg in the
local repository.

Would that work?

Best wishes,
Mario





reply via email to

[Prev in Thread] Current Thread [Next in Thread]