Patchwork bitbake.conf: search /lib for -native builds

login
register
mail settings
Submitter Enrico Scholz
Date Jan. 12, 2012, 4:30 p.m.
Message ID <1326385824-32201-5-git-send-email-enrico.scholz@sigma-chemnitz.de>
Download mbox | patch
Permalink /patch/19183/
State Accepted
Commit 46bf69dcfa99a3a8677b241bb32bed2f30255ece
Headers show

Comments

Enrico Scholz - Jan. 12, 2012, 4:30 p.m.
Changes to BUILD_LDFLAGS are required due to the recent movement of some
libraries from ${libdir} to ${base_libdir}.  ${base_libdir} must be now
in the linker search path to avoid build problems of -native packages.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
---
 meta/conf/bitbake.conf |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
Saul Wold - Jan. 17, 2012, 7:38 p.m.
On 01/12/2012 08:30 AM, Enrico Scholz wrote:
> Changes to BUILD_LDFLAGS are required due to the recent movement of some
> libraries from ${libdir} to ${base_libdir}.  ${base_libdir} must be now
> in the linker search path to avoid build problems of -native packages.
>
> Signed-off-by: Enrico Scholz<enrico.scholz@sigma-chemnitz.de>
> ---
>   meta/conf/bitbake.conf |    8 +++++++-
>   1 files changed, 7 insertions(+), 1 deletions(-)
>
> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
> index 43eedad..d051363 100644
> --- a/meta/conf/bitbake.conf
> +++ b/meta/conf/bitbake.conf
> @@ -49,6 +49,7 @@ bindir_native = "${prefix_native}/bin"
>   sbindir_native = "${prefix_native}/sbin"
>   includedir_native = "${prefix_native}/include"
>   libdir_native = "${prefix_native}/lib"
> +base_libdir_native = "/lib"
>   datadir_native = "${prefix_native}/share"
>   bindir_cross = "/bin"
>   bindir_crossscripts = "${bindir}/crossscripts"
> @@ -330,6 +331,7 @@ STAGING_BINDIR_NATIVE = "${STAGING_DIR_NATIVE}${bindir_native}"
>   STAGING_BINDIR_CROSS = "${STAGING_BINDIR}/crossscripts"
>   STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS}"
>   STAGING_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${libdir_native}"
> +STAGING_BASE_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${base_libdir_native}"
>   STAGING_INCDIR_NATIVE = "${STAGING_DIR_NATIVE}${includedir_native}"
>   STAGING_ETCDIR_NATIVE = "${STAGING_DIR_NATIVE}${sysconfdir_native}"
>   STAGING_DATADIR_NATIVE = "${STAGING_DIR_NATIVE}${datadir_native}"
> @@ -462,8 +464,12 @@ export CXXFLAGS = "${TARGET_CXXFLAGS}"
>   export TARGET_CXXFLAGS = "${TARGET_CFLAGS} -fpermissive"
>
>   export BUILD_LDFLAGS = "-L${STAGING_LIBDIR_NATIVE} \
> +                        -L${STAGING_BASE_LIBDIR_NATIVE} \
>                           -Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} \
> -                        -Wl,-rpath,${STAGING_LIBDIR_NATIVE} -Wl,-O1"
> +                        -Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} \
> +                        -Wl,-rpath,${STAGING_LIBDIR_NATIVE} \
> +                        -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE} \
> +                        -Wl,-O1"
>
>   BUILDSDK_LDFLAGS = "-L${STAGING_LIBDIR} \
>                       -Wl,-rpath-link,${STAGING_LIBDIR} \
Merged into OE-Core

Thanks
	Sau!

Patch

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 43eedad..d051363 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -49,6 +49,7 @@  bindir_native = "${prefix_native}/bin"
 sbindir_native = "${prefix_native}/sbin"
 includedir_native = "${prefix_native}/include"
 libdir_native = "${prefix_native}/lib"
+base_libdir_native = "/lib"
 datadir_native = "${prefix_native}/share"
 bindir_cross = "/bin"
 bindir_crossscripts = "${bindir}/crossscripts"
@@ -330,6 +331,7 @@  STAGING_BINDIR_NATIVE = "${STAGING_DIR_NATIVE}${bindir_native}"
 STAGING_BINDIR_CROSS = "${STAGING_BINDIR}/crossscripts"
 STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${TUNE_PKGARCH}${TARGET_VENDOR}-${TARGET_OS}"
 STAGING_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${libdir_native}"
+STAGING_BASE_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${base_libdir_native}"
 STAGING_INCDIR_NATIVE = "${STAGING_DIR_NATIVE}${includedir_native}"
 STAGING_ETCDIR_NATIVE = "${STAGING_DIR_NATIVE}${sysconfdir_native}"
 STAGING_DATADIR_NATIVE = "${STAGING_DIR_NATIVE}${datadir_native}"
@@ -462,8 +464,12 @@  export CXXFLAGS = "${TARGET_CXXFLAGS}"
 export TARGET_CXXFLAGS = "${TARGET_CFLAGS} -fpermissive"
 
 export BUILD_LDFLAGS = "-L${STAGING_LIBDIR_NATIVE} \
+                        -L${STAGING_BASE_LIBDIR_NATIVE} \
                         -Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} \
-                        -Wl,-rpath,${STAGING_LIBDIR_NATIVE} -Wl,-O1"
+                        -Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} \
+                        -Wl,-rpath,${STAGING_LIBDIR_NATIVE} \
+                        -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE} \
+                        -Wl,-O1"
 
 BUILDSDK_LDFLAGS = "-L${STAGING_LIBDIR} \
                     -Wl,-rpath-link,${STAGING_LIBDIR} \