]> code.ossystems Code Review - openembedded-core.git/commitdiff
rootfs_rpm.bbclass: fix a regression introduced by list_installed_packages change
authorMing Liu <ming.liu@windriver.com>
Thu, 29 Nov 2012 09:30:12 +0000 (09:30 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 3 Dec 2012 14:41:25 +0000 (14:41 +0000)
A regression was introduced by commit:190cb591 that it doesn't
consider the situation that some archs contain "_" originally, so it
results in issues when dealing with archs like qemux86_64, x85_64.

Added a conditional statment in to handle that case.

Signed-off-by: Ming Liu <ming.liu@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/rootfs_rpm.bbclass

index 300dd5f75d64c2afd612a83b3253f1fff0dff25b..c4fb47039567d327f78a7f1b4bd76267bbd3e420 100644 (file)
@@ -153,7 +153,7 @@ list_installed_packages() {
 
        # print the info, need to different return counts
        if [ "$1" = "arch" ] ; then
-               echo "$GET_LIST" | awk '{gsub("_", "-", $2); print $1, $2}'
+               echo "$GET_LIST" | awk -v archs="${PACKAGE_ARCHS}" '{if(!index(archs, $2)) {gsub("_", "-", $2)} print $1, $2}'
         elif [ "$1" = "file" ] ; then
                echo "$GET_LIST" | awk '{print $1, $3}'
         else