diff options
author | Ross Burton <ross.burton@intel.com> | 2014-02-06 23:17:18 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-02-09 09:42:52 +0000 |
commit | 9203c879b333e7b1c390f43389cb917ae065185e (patch) | |
tree | 01e9a6064f8e744551653c73709777290f77c2e4 | |
parent | 4bc6982ea60929226bcd9d206b4879dea2a3157c (diff) | |
download | poky-9203c879b333e7b1c390f43389cb917ae065185e.tar.gz |
binconfig: mangle ${base_libdir}
Some recipes are installing libraries into ${base_libdir} (typically /lib) and
also use a foo-config binary to identify compile paths, for example
libusb-compat. Without mangling ${base_libdir} the ${base_libdir} path is
passed to the compiler, where it looks like a host path and results in
compile-host-path QA errors.
(From OE-Core rev: ccd9abdccb84d713427541b6ee29a0e217360e74)
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes/binconfig.bbclass | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes/binconfig.bbclass b/meta/classes/binconfig.bbclass index 4c42602aff..848c74427b 100644 --- a/meta/classes/binconfig.bbclass +++ b/meta/classes/binconfig.bbclass | |||
@@ -5,6 +5,7 @@ def get_binconfig_mangle(d): | |||
5 | s = "-e ''" | 5 | s = "-e ''" |
6 | if not bb.data.inherits_class('native', d): | 6 | if not bb.data.inherits_class('native', d): |
7 | optional_quote = r"\(\"\?\)" | 7 | optional_quote = r"\(\"\?\)" |
8 | s += " -e 's:=%s${base_libdir}:=\\1OEBASELIBDIR:;'" % optional_quote | ||
8 | s += " -e 's:=%s${libdir}:=\\1OELIBDIR:;'" % optional_quote | 9 | s += " -e 's:=%s${libdir}:=\\1OELIBDIR:;'" % optional_quote |
9 | s += " -e 's:=%s${includedir}:=\\1OEINCDIR:;'" % optional_quote | 10 | s += " -e 's:=%s${includedir}:=\\1OEINCDIR:;'" % optional_quote |
10 | s += " -e 's:=%s${datadir}:=\\1OEDATADIR:'" % optional_quote | 11 | s += " -e 's:=%s${datadir}:=\\1OEDATADIR:'" % optional_quote |
@@ -12,6 +13,7 @@ def get_binconfig_mangle(d): | |||
12 | s += " -e 's:=%s${exec_prefix}/:=\\1OEEXECPREFIX/:'" % optional_quote | 13 | s += " -e 's:=%s${exec_prefix}/:=\\1OEEXECPREFIX/:'" % optional_quote |
13 | s += " -e 's:-L${libdir}:-LOELIBDIR:;'" | 14 | s += " -e 's:-L${libdir}:-LOELIBDIR:;'" |
14 | s += " -e 's:-I${includedir}:-IOEINCDIR:;'" | 15 | s += " -e 's:-I${includedir}:-IOEINCDIR:;'" |
16 | s += " -e 's:OEBASELIBDIR:${STAGING_BASELIBDIR}:;'" | ||
15 | s += " -e 's:OELIBDIR:${STAGING_LIBDIR}:;'" | 17 | s += " -e 's:OELIBDIR:${STAGING_LIBDIR}:;'" |
16 | s += " -e 's:OEINCDIR:${STAGING_INCDIR}:;'" | 18 | s += " -e 's:OEINCDIR:${STAGING_INCDIR}:;'" |
17 | s += " -e 's:OEDATADIR:${STAGING_DATADIR}:'" | 19 | s += " -e 's:OEDATADIR:${STAGING_DATADIR}:'" |
@@ -31,7 +33,8 @@ PACKAGE_PREPROCESS_FUNCS += "binconfig_package_preprocess" | |||
31 | binconfig_package_preprocess () { | 33 | binconfig_package_preprocess () { |
32 | for config in `find ${PKGD} -name '${BINCONFIG_GLOB}'`; do | 34 | for config in `find ${PKGD} -name '${BINCONFIG_GLOB}'`; do |
33 | sed -i \ | 35 | sed -i \ |
34 | -e 's:${STAGING_LIBDIR}:${libdir}:g;' \ | 36 | -e 's:${STAGING_BASELIBDIR}:${base_libdir}:g;' \ |
37 | -e 's:${STAGING_LIBDIR}:${libdir}:g;' \ | ||
35 | -e 's:${STAGING_INCDIR}:${includedir}:g;' \ | 38 | -e 's:${STAGING_INCDIR}:${includedir}:g;' \ |
36 | -e 's:${STAGING_DATADIR}:${datadir}:' \ | 39 | -e 's:${STAGING_DATADIR}:${datadir}:' \ |
37 | -e 's:${STAGING_DIR_HOST}${prefix}:${prefix}:' \ | 40 | -e 's:${STAGING_DIR_HOST}${prefix}:${prefix}:' \ |
@@ -39,6 +42,7 @@ binconfig_package_preprocess () { | |||
39 | done | 42 | done |
40 | for lafile in `find ${PKGD} -name "*.la"` ; do | 43 | for lafile in `find ${PKGD} -name "*.la"` ; do |
41 | sed -i \ | 44 | sed -i \ |
45 | -e 's:${STAGING_BASELIBDIR}:${base_libdir}:g;' \ | ||
42 | -e 's:${STAGING_LIBDIR}:${libdir}:g;' \ | 46 | -e 's:${STAGING_LIBDIR}:${libdir}:g;' \ |
43 | -e 's:${STAGING_INCDIR}:${includedir}:g;' \ | 47 | -e 's:${STAGING_INCDIR}:${includedir}:g;' \ |
44 | -e 's:${STAGING_DATADIR}:${datadir}:' \ | 48 | -e 's:${STAGING_DATADIR}:${datadir}:' \ |