[oe-commits] Phil Blundell : rootfs_ipk: Ensure that BAD_RECOMMENDATIONS are honoured for all architectures

git at git.openembedded.org git at git.openembedded.org
Sun Feb 2 22:33:00 UTC 2014


Module: openembedded-core.git
Branch: master
Commit: 12d7b44c817bdf6eea425bda607379594057c3fb
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=12d7b44c817bdf6eea425bda607379594057c3fb

Author: Phil Blundell <pb at pbcl.net>
Date:   Sun Feb  2 12:38:07 2014 +0000

rootfs_ipk: Ensure that BAD_RECOMMENDATIONS are honoured for all architectures

Commit a5362de60c0051f16b88a40bd9cb41915bee0b0f restricted us to writing
only a single entry to the status file for any given package.  This
avoids writing garbage entries (with no Status) when multiple versions
of the same package exist in the feed.  However, in the case where the
same version exists for multiple architectures (for example, has been
built for both cortexa15 and generic armv7a), we do need to write out
status file entries for all of them since we can't trivially determine
which one opkg will decide to install.

Fix this by undoing a5362de60c0051f16b88a40bd9cb41915bee0b0f and writing
out an entry for everything that matches, but ensuring that we force the
Status to the correct value for each one.

Signed-off-by: Phil Blundell <pb at pbcl.net>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 meta/classes/rootfs_ipk.bbclass | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass
index dbe1c79..f97f027 100644
--- a/meta/classes/rootfs_ipk.bbclass
+++ b/meta/classes/rootfs_ipk.bbclass
@@ -44,13 +44,7 @@ fakeroot rootfs_ipk_do_rootfs () {
 	for i in ${BAD_RECOMMENDATIONS}; do
 		pkginfo="`opkg-cl ${OPKG_ARGS} info $i`"
 		if [ ! -z "$pkginfo" ]; then
-			# Take just the first package stanza as otherwise only
-			# the last one will have the right Status line.
-			echo "$pkginfo" | awk "/^Package:/ { print } \
-                        		       /^Architecture:/ { print } \
-                        		       /^Version:/ { print } \
-                        		       /^$/ { exit } \
-                        		       END { print \"Status: deinstall hold not-installed\n\" }" - >> $STATUS
+			echo "$pkginfo" | awk "/^Status:/ { print \"Status: deinstall hold not-installed\n\" }" - >> $STATUS
 		else
 			echo "Requested ignored recommendation $i is not a package"
 		fi



More information about the Openembedded-commits mailing list