Patchwork packagedata.py: Fix get_subpkgedata_fn for multilib

login
register
mail settings
Submitter Matthew McClintock
Date July 6, 2012, 8:08 p.m.
Message ID <1341605280-32431-1-git-send-email-msm@freescale.com>
Download mbox | patch
Permalink /patch/31341/
State Accepted
Commit 4e65ddda5d351bd9f2172e77e656903f61a52f34
Headers show

Comments

Matthew McClintock - July 6, 2012, 8:08 p.m.
This happens when tryng to add libgcc-dev to as a multilib package
(e.g. IMAGE_INSTALL_append = " lib32-libgcc-dev")

| Processing task-core-boot...
| Processing fman-ucode...
| Processing dosfstools...
| Processing lib32-libgcc-dev...
| Unable to find package lib32-libgcc-dev (libgcc-dev)!
NOTE: package fsl-image-full-1.0-r1.1.3.6: task do_rootfs: Failed

RPM (or bitbake?) is looking in the tmp/pkgdata, however some of these file
paths are mungned for the multilib scenario:

$ find tmp/pkgdata/ | grep libgcc-dev$
tmp/pkgdata/ppce5500-fsl-linux/runtime/lib32-libgcc-dev
tmp/pkgdata/ppc64e5500-fsl-linux/runtime/libgcc-dev

This patch fixes where we look for these files so they can be found and
properly installed for the multilib root file system

Signed-off-by: Matthew McClintock <msm@freescale.com>
---
 meta/lib/oe/packagedata.py |    8 ++++++++
 1 file changed, 8 insertions(+)
Saul Wold - July 9, 2012, 4:23 p.m.
On 07/06/2012 01:08 PM, Matthew McClintock wrote:
> This happens when tryng to add libgcc-dev to as a multilib package
> (e.g. IMAGE_INSTALL_append = " lib32-libgcc-dev")
>
> | Processing task-core-boot...
> | Processing fman-ucode...
> | Processing dosfstools...
> | Processing lib32-libgcc-dev...
> | Unable to find package lib32-libgcc-dev (libgcc-dev)!
> NOTE: package fsl-image-full-1.0-r1.1.3.6: task do_rootfs: Failed
>
> RPM (or bitbake?) is looking in the tmp/pkgdata, however some of these file
> paths are mungned for the multilib scenario:
>
> $ find tmp/pkgdata/ | grep libgcc-dev$
> tmp/pkgdata/ppce5500-fsl-linux/runtime/lib32-libgcc-dev
> tmp/pkgdata/ppc64e5500-fsl-linux/runtime/libgcc-dev
>
> This patch fixes where we look for these files so they can be found and
> properly installed for the multilib root file system
>
> Signed-off-by: Matthew McClintock <msm@freescale.com>
> ---
>   meta/lib/oe/packagedata.py |    8 ++++++++
>   1 file changed, 8 insertions(+)
>
> diff --git a/meta/lib/oe/packagedata.py b/meta/lib/oe/packagedata.py
> index a7a40f0..9a28e6b 100644
> --- a/meta/lib/oe/packagedata.py
> +++ b/meta/lib/oe/packagedata.py
> @@ -27,6 +27,14 @@ def read_pkgdatafile(fn):
>
>   def get_subpkgedata_fn(pkg, d):
>       archs = d.expand("${PACKAGE_ARCHS}").split(" ")
> +    mlarchs = d.getVar("MULTILIB_PACKAGE_ARCHS", d) or None
> +
> +    if mlarchs:
> +        for mlarch in mlarchs.split(" "):
> +            if "_" in mlarch:
> +                prefix, split, new_arch = mlarch.partition("_")
> +                archs.append(new_arch)
> +
>       archs.reverse()
>       pkgdata = d.expand('${TMPDIR}/pkgdata/')
>       targetdir = d.expand('${TARGET_VENDOR}-${TARGET_OS}/runtime/')
>

Merged into OE-Core

Thanks
	Sau!

Patch

diff --git a/meta/lib/oe/packagedata.py b/meta/lib/oe/packagedata.py
index a7a40f0..9a28e6b 100644
--- a/meta/lib/oe/packagedata.py
+++ b/meta/lib/oe/packagedata.py
@@ -27,6 +27,14 @@  def read_pkgdatafile(fn):
 
 def get_subpkgedata_fn(pkg, d):
     archs = d.expand("${PACKAGE_ARCHS}").split(" ")
+    mlarchs = d.getVar("MULTILIB_PACKAGE_ARCHS", d) or None
+
+    if mlarchs:
+        for mlarch in mlarchs.split(" "):
+            if "_" in mlarch:
+                prefix, split, new_arch = mlarch.partition("_")
+                archs.append(new_arch)
+
     archs.reverse()
     pkgdata = d.expand('${TMPDIR}/pkgdata/')
     targetdir = d.expand('${TARGET_VENDOR}-${TARGET_OS}/runtime/')