Subject: Re: Comparing version numbers
To: Jeremy C. Reed <reed@reedmedia.net>
From: Julien Letessier <julien.letessier@sun.com>
List: tech-pkg
Date: 08/01/2002 14:49:42
Jeremy C. Reed wrote:
> On Thu, 1 Aug 2002, Julien Letessier wrote:
> 
>>I'm writing a dselect-like tool for NetBSD binary package repositories,
> 
> Sounds interesting and useful. 

Thanks. Since we're aiming to help end-users and sysadmins rather than 
devvies, it seemed pretty logical to develop such a tool.

>>and was wondering if there is an 'official' reference / code blob about:
>>   * how package version strings are to be compared;
>>   * how requirement strings are to be expanded in a boolean expression.
> 
> 
> Maybe have a look at
> /usr/src/usr.sbin/pkg_install/lib/ftpio.c
> /usr/src/usr.sbin/pkg_install/lib/file.c
> /usr/src/usr.sbin/pkg_install/add/perform.c
> and other related files for "wildcard" and expandURL, etc.
> 
> You may want to use that library.

Hmm. Seem quite dense. But I'm sure that there's a mechanism that does 
the same version-comparison inside pkgsrc's *.mk file. clue anyone?

> For perl or other examples, look at code from pkgsrc/pkgtools/ packages.

> Also, please consider making your code so it is easy to develop with new
> user interfaces (console and/or x11).

Development will be (is) done in python2, which should make things 
portable / scalable.
Interested people can have a look at our website, at 
http://solarpack.sourceforge.net

> Good luck!

I'll need that...
-- 
Julien T. Letessier
Sun Labs Europe, Meylan, France
julien.letessier@sun.com