Re: [Pkgutil-users] patch to support non-standard VERSION entries
Status: Beta
Brought to you by:
bonivart
|
From: Dagobert M. <da...@op...> - 2010-07-27 07:12:19
|
Hi Mark, Am 26.07.2010 um 16:56 schrieb ma...@pr...: >> What we at CSW have found is that it's more or less impossible to >> compare unknown version strings and _know_ which one is newer, simply >> due to not knowing which ruleset the author of that software used. >> Not >> to mention when they all of a sudden change it. > > Understood we might not catch 100% of cases, but if we can catch 98% > of cases, the outlying 2% can be treated as exceptions. 1.0 vs. > 1.0b2 would actually still work given the patch I presented you, > because the b would be stripped leaving 1.0 vs. 1.02. What wouldn't > have worked was 1.0 vs. 1.0b. But I have yet to find an example > like this from one of our vendors (all the examples I can find will > work with the patch I sent you). Ok. But I would either rely 100% on the builtin-mechanism or 100% on the mapping file. Don't try to guess or hell breaks loose. >> How about adding a script to the pkgutilplus package that unpacks a >> package, adds a REV-field and repacks it again? ;-) > > Dago's suggestion of a separate mapfile is also a good idea, where > the comparison logic can be fine tuned, although expecting this to > be done for every non-CSW package is onerous. You would write a REV-string extractor for every vendor, for VRTS this could be taken from "PSTAMP=VERITAS-5.0:25-May-2006" > Start with good built-in logic that works for 98% of cases, then use > a mapfile to clean up the exceptions. ...and bail out on the remaining 2% if there is no mapfile. > I realise pkgutil was originally only written for CSW, but I believe > there is a gain to be had in building in full non-CSW support so a > wider audience can realise its benefits. It's a great tool that > plugs a sizeable gap in Solaris package management. > > The other issue I'm going to be looking into shortly is that of > supporting multiple versions of the same package. Usually you use different catalogs for this and then use overlays in pkgutil.conf on all these, e.g. veritas41/ veritas50/ veritas51/ > Can I check, is bldcat GPLed? It didn't say so in the comment at > the top of the script. I guess so. Best regards -- Dago |