summaryrefslogtreecommitdiffstats
path: root/meta/classes/populate_sdk_rpm.bbclass
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2012-11-30 16:11:37 -0600
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-12-17 17:24:51 +0000
commita6aa74817cce38799b447cd47ef6f77aee9fcc85 (patch)
treee02a6b60d8fb05386b67dd89848c48acec4709d7 /meta/classes/populate_sdk_rpm.bbclass
parentba08a8ccbf11542867b7dd0474599fccb0585b97 (diff)
downloadpoky-a6aa74817cce38799b447cd47ef6f77aee9fcc85.tar.gz
package_rpm: Update the way the multilib package names are translated
The variable MULTILIB_PACKAGE_ARCHS has been removed in favor of a repurposed MULTILIB_PREFIX_LIST. The format of this item is now <libid>:<arch>:<arch1>:...:<archN>. This ensures that we can correctly translate the libid to one of the supported archs in a tri-lib system. All of the users of MULTILIB_PREFIX_LIST and MULTILIB_PACKAGE_ARCHS have been modified accordingly. Also change the way attempted packages are installed, verify the package exists in the translate functions, then perform the install in one single operation. This results in a significantly faster install time. (From OE-Core rev: ffe6cf3a1c57defdbe8531bdeb588e199177bb6c) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/populate_sdk_rpm.bbclass')
-rw-r--r--meta/classes/populate_sdk_rpm.bbclass28
1 files changed, 18 insertions, 10 deletions
diff --git a/meta/classes/populate_sdk_rpm.bbclass b/meta/classes/populate_sdk_rpm.bbclass
index d26867fa9a..eb80e1dd9c 100644
--- a/meta/classes/populate_sdk_rpm.bbclass
+++ b/meta/classes/populate_sdk_rpm.bbclass
@@ -54,8 +54,16 @@ populate_sdk_rpm () {
54 54
55 # List must be prefered to least preferred order 55 # List must be prefered to least preferred order
56 INSTALL_PLATFORM_EXTRA_RPM="" 56 INSTALL_PLATFORM_EXTRA_RPM=""
57 for each_arch in ${MULTILIB_PACKAGE_ARCHS} ${PACKAGE_ARCHS} ; do 57 for i in ${MULTILIB_PREFIX_LIST} ; do
58 INSTALL_PLATFORM_EXTRA_RPM="$each_arch $INSTALL_PLATFORM_EXTRA_RPM" 58 old_IFS="$IFS"
59 IFS=":"
60 set $i
61 IFS="$old_IFS"
62 shift #remove mlib
63 while [ -n "$1" ]; do
64 INSTALL_PLATFORM_EXTRA_RPM="$INSTALL_PLATFORM_EXTRA_RPM $1"
65 shift
66 done
59 done 67 done
60 export INSTALL_PLATFORM_EXTRA_RPM 68 export INSTALL_PLATFORM_EXTRA_RPM
61 69
@@ -81,7 +89,7 @@ populate_sdk_rpm () {
81 done 89 done
82 export INSTALL_PLATFORM_EXTRA_RPM 90 export INSTALL_PLATFORM_EXTRA_RPM
83 91
84 package_install_internal_rpm 92 package_install_internal_rpm --sdk
85 populate_sdk_post_rpm ${INSTALL_ROOTFS_RPM} 93 populate_sdk_post_rpm ${INSTALL_ROOTFS_RPM}
86 94
87 # move host RPM library data 95 # move host RPM library data
@@ -98,8 +106,11 @@ populate_sdk_rpm () {
98 106
99python () { 107python () {
100 # The following code should be kept in sync w/ the rootfs_rpm version. 108 # The following code should be kept in sync w/ the rootfs_rpm version.
101 ml_package_archs = "" 109
102 ml_prefix_list = "" 110 # package_arch order is reversed. This ensures the -best- match is listed first!
111 package_archs = d.getVar("PACKAGE_ARCHS", True) or ""
112 package_archs = ":".join(package_archs.split()[::-1])
113 ml_prefix_list = "%s:%s" % ('default', package_archs)
103 multilibs = d.getVar('MULTILIBS', True) or "" 114 multilibs = d.getVar('MULTILIBS', True) or ""
104 for ext in multilibs.split(): 115 for ext in multilibs.split():
105 eext = ext.split(':') 116 eext = ext.split(':')
@@ -109,11 +120,8 @@ python () {
109 if default_tune: 120 if default_tune:
110 localdata.setVar("DEFAULTTUNE", default_tune) 121 localdata.setVar("DEFAULTTUNE", default_tune)
111 package_archs = localdata.getVar("PACKAGE_ARCHS", True) or "" 122 package_archs = localdata.getVar("PACKAGE_ARCHS", True) or ""
112 package_archs = " ".join([i in "all noarch any".split() and i or eext[1]+"_"+i for i in package_archs.split()]) 123 package_archs = ":".join([i in "all noarch any".split() and i or eext[1]+"_"+i for i in package_archs.split()][::-1])
113 ml_package_archs += " " + package_archs 124 ml_prefix_list += " %s:%s" % (eext[1], package_archs)
114 ml_prefix_list += " " + eext[1]
115 #bb.note("ML_PACKAGE_ARCHS %s %s %s" % (eext[1], localdata.getVar("PACKAGE_ARCHS", True) or "(none)", overrides))
116 d.setVar('MULTILIB_PACKAGE_ARCHS', ml_package_archs)
117 d.setVar('MULTILIB_PREFIX_LIST', ml_prefix_list) 125 d.setVar('MULTILIB_PREFIX_LIST', ml_prefix_list)
118} 126}
119 127