dpkg's version comparison algorithm?

1998-01-09 Thread David Frey
Hello collegues, I don't understand dpkg's version compare algorithm: ([EMAIL PROTECTED]) /var/debian/unstable/binary-i386/math$dpkg --compare-versions 1.15 lt 1.2-1; echo $? 1 ([EMAIL PROTECTED]) /var/debian/unstable/binary-i386/math$dpkg --compare-versions 1.15 lt 1.20-1; echo $? 0 ([EMAIL

Re: dpkg's version comparison algorithm?

1998-01-09 Thread Jason Gunthorpe
On Fri, 9 Jan 1998, David Frey wrote: Hello collegues, I don't understand dpkg's version compare algorithm: ([EMAIL PROTECTED]) /var/debian/unstable/binary-i386/math$dpkg --compare-versions 1.15 lt 1.2-1; echo $? 1 ([EMAIL PROTECTED]) /var/debian/unstable/binary-i386/math$dpkg

Re: dpkg's version comparison algorithm?

1998-01-09 Thread James Troup
David Frey [EMAIL PROTECTED] writes: Why is 1.15 1.2 ? Because 1 = 1 and 15 is 2; dpkg breaks the version number into chunks (in this case delimited by '.'). See verrevcmp() in lib/vercmp.c from the dpkg source for more details. Is it necessary to fill in trailing zeroes? Yes. 20 15 -

Re: dpkg's version comparison algorithm?

1998-01-09 Thread Nathan E Norman
On Fri, 9 Jan 1998, David Frey wrote: : Hello collegues, : : I don't understand dpkg's version compare algorithm: ([EMAIL PROTECTED]) : /var/debian/unstable/binary-i386/math$dpkg --compare-versions 1.15 lt : 1.2-1; echo $? 1 ([EMAIL PROTECTED]) : /var/debian/unstable/binary-i386/math$dpkg