Thanks Jeff.
It work as aspected.
Do you think to commit it in the stable branch ?
On Sun, Mar 23, 2008 at 10:26 PM, Jeff Johnson <n3npq@mac.com> wrote:
>
> On Mar 23, 2008, at 5:08 PM, devzero2000 wrote:
>
> Hi,
>
> In rpm 5.0.3 I have this situation on FC8.
>
> I have the package buggy-nevra-0.99.8.1-17.fc8.noarch.rpm and i want to
> upgrade
> to buggy-nevra-0.99.8.1-17.1.fc8.noarch.rpm.
>
> Now the questions is:
>
> Is it buggy-nevra-0.99.8.1-17.1.fc8 newer of buggy-nevra-0.99.8.1-17.fc8for the rpm rules ?
>
> (for example as in http://people.redhat.com/laroche/pyrpm/pyrpm-devel.htm
> l)
>
>
> But rpm 5.0.3 says:
>
>
> su -c "rpm -Uvh /home/machbuild/rpmbuild/RPMS/buggy-
> nevra-0.99.8.1-17.1.fc8.noarch.rpm
> "
> Parola d'ordine:
> Preparing... ###########################################
> [100%]
> error: Install/Erase problems:
> package buggy-nevra-0.99.8.1-17.fc8.noarch (which is newer than
> buggy-nevra-0.99.8.1-17.1.fc8.noarch) is already installed
>
>
> The comparison is between a digit string (the "1" in ...-17.1) and an
> alpha string (the "fc8" in ... -17.fc8").
>
> For hysterical reasons digit <-> alpha comparisons are arbitrarily defined
> in rpm.
>
> This patch likely "fixes" (by inverting the order of digit <-> alpha
> string comparisons).
>
> Index:
> lib/rpmevr.c===================================================================RCS
> file: /v/rpm/cvs/rpm/lib/rpmevr.c,vretrieving revision 1.3diff -u -b -B -w
> -p -r1.3 rpmevr.c--- lib/rpmevr.c 30 Sep 2007 20:38:25 -0000
> 1.3+++ lib/rpmevr.c 23 Mar 2008 21:21:40 -0000@@ -19,7 +19,7 @@ int
> _rpmevr_debug = 0; /* XXX Force digits to beat alphas. See bugzilla #50977.
> */ /*@unchecked@*/-static int _invert_digits_alphas_comparison = -1;+static
> int _invert_digits_alphas_comparison = 1; /* XXX Punctuation characters
> that are not treated as alphas */ /*@unchecked@*/ /*@observer@*/
>
>
> In rpm 4.4.2.1.2.3.4.5.6.7.9.10 it work, perhaps it is wrong it or i have
> done some error: i don't know.
>
>
> All rpm versions are equally broken in the sense that digit <-> alpha
> comparisons
> are arbitrarily (and unnaturally wrto ASCII collate sequences) defined.
>
> hth
>
> 73 de Jeff
>
Received on Mon Mar 24 09:46:03 2008