summaryrefslogtreecommitdiff
path: root/meta/classes/toolchain-scripts.bbclass
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2016-06-30 13:08:43 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-07-01 16:08:53 +0100
commit1bea760f3f462fdcc3eefc0d8597688d61447ddd (patch)
tree4f62f7d0c4e4050f1480f6e0fff3727f93609543 /meta/classes/toolchain-scripts.bbclass
parent2f7e4d0636ce1647edf2d82c65b82be0eb2c1db1 (diff)
downloadopenembedded-core-1bea760f3f462fdcc3eefc0d8597688d61447ddd.tar.gz
openembedded-core-1bea760f3f462fdcc3eefc0d8597688d61447ddd.tar.bz2
openembedded-core-1bea760f3f462fdcc3eefc0d8597688d61447ddd.zip
toolchain-scripts: add sysroot/usr/share/pkgconfig to PKG_CONFIG_PATH
Otherwise architecture-independent pkg-config files such as wayland-protocols won't be found in the SDK. Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/classes/toolchain-scripts.bbclass')
-rw-r--r--meta/classes/toolchain-scripts.bbclass5
1 files changed, 3 insertions, 2 deletions
diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass
index 02e69c8400..32d8c32309 100644
--- a/meta/classes/toolchain-scripts.bbclass
+++ b/meta/classes/toolchain-scripts.bbclass
@@ -8,7 +8,8 @@ TARGET_CC_ARCH_append_libc-musl = " -mmusl"
# This function creates an environment-setup-script for use in a deployable SDK
toolchain_create_sdk_env_script () {
- # Create environment setup script
+ # Create environment setup script. Remember that $SDKTARGETSYSROOT should
+ # only be expanded on the target at runtime.
base_sbindir=${10:-${base_sbindir_nativesdk}}
base_bindir=${9:-${base_bindir_nativesdk}}
sbindir=${8:-${sbindir_nativesdk}}
@@ -29,7 +30,7 @@ toolchain_create_sdk_env_script () {
echo "export PATH=$sdkpathnative$bindir:$sdkpathnative$sbindir:$sdkpathnative$base_bindir:$sdkpathnative$base_sbindir:$sdkpathnative$bindir/../${HOST_SYS}/bin:$sdkpathnative$bindir/${TARGET_SYS}"$EXTRAPATH':$PATH' >> $script
echo "export CCACHE_PATH=$sdkpathnative$bindir:$sdkpathnative$bindir/../${HOST_SYS}/bin:$sdkpathnative$bindir/${TARGET_SYS}"$EXTRAPATH':$CCACHE_PATH' >> $script
echo 'export PKG_CONFIG_SYSROOT_DIR=$SDKTARGETSYSROOT' >> $script
- echo 'export PKG_CONFIG_PATH=$SDKTARGETSYSROOT'"$libdir"'/pkgconfig' >> $script
+ echo 'export PKG_CONFIG_PATH=$SDKTARGETSYSROOT'"$libdir"'/pkgconfig:$SDKTARGETSYSROOT'"$prefix"'/share/pkgconfig' >> $script
echo 'export CONFIG_SITE=${SDKPATH}/site-config-'"${multimach_target_sys}" >> $script
echo "export OECORE_NATIVE_SYSROOT=\"$sdkpathnative\"" >> $script
echo 'export OECORE_TARGET_SYSROOT="$SDKTARGETSYSROOT"' >> $script