FS#19153 - [pacman] misinterpreted version string
Attached to Project:
Pacman
Opened by Arthur S. (Mvxa) - Sunday, 18 April 2010, 14:27 GMT
Last edited by Dan McGee (toofishes) - Monday, 03 May 2010, 00:18 GMT
Opened by Arthur S. (Mvxa) - Sunday, 18 April 2010, 14:27 GMT
Last edited by Dan McGee (toofishes) - Monday, 03 May 2010, 00:18 GMT
|
Details
Description:
Pacman misinterprets the version string 1.003-4 as being higher then 1.2-1 (spotted on the ttf-isabella package upgrade) :: Starting full system upgrade... warning: ttf-isabella: local (1.003-4) is newer than extra (1.2-1) Additional info: pacman-3.3.3-5-i686 |
This task depends upon
$ vercmp
usage: vercmp <ver1> <ver2>
return values:
< 0 : if ver1 < ver2
0 : if ver1 == ver2
> 0 : if ver1 > ver2
$ vercmp 1.003-4 1.3-4
0
Basically pacman interprets versions as follows:
The "31" block of 2.6.31 means 31, not 31/100, so 2.6.31 > 2.6.8 (see kernel26, for example).
In our case we have a 003 block, which is interpreted as 3 (and not 3/1000). We have an explicit comment for this case in our code (/* throw away any leading zeros - it's a number, right? */), so this is in intentional.
I am not sure what to do here...
Of course there is always the whole epoch idea.