Patchwork image-mklibs: pass correct libdir to mklibs

login
register
mail settings
Submitter Jesse Zhang
Date Aug. 7, 2012, 2:31 a.m.
Message ID <1344306717-6352-2-git-send-email-sen.zhang@windriver.com>
Download mbox | patch
Permalink /patch/34001/
State Accepted
Commit d2cd2ccea8bc4d110647ba3bd202772e5407000a
Headers show

Comments

Jesse Zhang - Aug. 7, 2012, 2:31 a.m.
libdir should be specified, or else mklibs won't work for 64bit targets.
It wouldn't be able to find the libs.

    Traceback (most recent call last):
      File "<build>/bitbake_build/tmp/sysroots/i686-linux/usr/bin/x86_64-wrs-linux/mklibs", line 553, in <module>
        header = elf_header(find_lib(libraries.copy().pop()))
      File "<build>/bitbake_build/tmp/sysroots/i686-linux/usr/bin/x86_64-wrs-linux/mklibs", line 89, in elf_header
        raise Exception("Cannot find lib: " + obj)
    Exception: Cannot find lib:

Signed-off-by: Jesse Zhang <sen.zhang@windriver.com>
---
 meta/classes/image-mklibs.bbclass |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
Richard Purdie - Aug. 7, 2012, 11:55 a.m.
On Tue, 2012-08-07 at 10:31 +0800, Jesse Zhang wrote:
> libdir should be specified, or else mklibs won't work for 64bit targets.
> It wouldn't be able to find the libs.
> 
>     Traceback (most recent call last):
>       File "<build>/bitbake_build/tmp/sysroots/i686-linux/usr/bin/x86_64-wrs-linux/mklibs", line 553, in <module>
>         header = elf_header(find_lib(libraries.copy().pop()))
>       File "<build>/bitbake_build/tmp/sysroots/i686-linux/usr/bin/x86_64-wrs-linux/mklibs", line 89, in elf_header
>         raise Exception("Cannot find lib: " + obj)
>     Exception: Cannot find lib:
> 
> Signed-off-by: Jesse Zhang <sen.zhang@windriver.com>
> ---
>  meta/classes/image-mklibs.bbclass |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)

Merged to master, thanks.

Richard

Patch

diff --git a/meta/classes/image-mklibs.bbclass b/meta/classes/image-mklibs.bbclass
index 7623815..66b0f52 100644
--- a/meta/classes/image-mklibs.bbclass
+++ b/meta/classes/image-mklibs.bbclass
@@ -38,6 +38,7 @@  mklibs_optimize_image_doit() {
 
 	mklibs -v \
 		--ldlib ${dynamic_loader} \
+		--libdir ${baselib} \
 		--sysroot ${PKG_CONFIG_SYSROOT_DIR} \
 		--root ${IMAGE_ROOTFS} \
 		--target `echo ${TARGET_PREFIX} | sed 's/-$//' ` \