rpm 5.4.0: respect to the arch when choose the alternatives
authorRobert Yang <liezhi.yang@windriver.com>
Wed, 23 May 2012 05:55:39 +0000 (13:55 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 24 May 2012 07:51:37 +0000 (08:51 +0100)
commit74e8a91baee129f84fa7f82aef93d584ea7fb32d
treeda8fb4b5957e627967dfbe9b1ff3653c673bd2b5
parent91286e5323dbc4a47e1ccaebf8f398390ad7cdc8
rpm 5.4.0: respect to the arch when choose the alternatives

There is a bug if we:
1) bitbake diffutils with MACHINE=crownbay
2) bitbake diffutils with MACHINE=qemux86
3) bitbake core-image-sato with MACHINE=crownbay

Then the diffutils.i586 would be installed to the crownbay's image, this
is because diffutils.i586 is newer than diffutils.core2, and rpm doesn't
respect to the arch priorities:

We have put the archs in order in _solve_dbpath:

crownbay/solvedb:core2/solvedb:i586/solvedb:all/solvedb

Fix rpm to respect to the order, for example, if it finds a pkg in both
core2/ and i586/, and the core2/ comes first, it should not use the one
in i586/ even if it's build time is newer.

Note: Don't worry about the _free(*ptr), it can check whether ptr is
NULL or not.

This is for the denzil branch, and the master branch also needs it.

[YOCTO #2360]

(From OE-Core rev: d76067ae100623dd6dd4858568b98522d1daf474)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/rpm/rpm/rpm-respect-arch.patch [new file with mode: 0644]
meta/recipes-devtools/rpm/rpm_5.4.0.bb