summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/classes/toolchain-scripts.bbclass4
-rw-r--r--meta/recipes-tbd/meta/meta-toolchain.bb11
2 files changed, 13 insertions, 2 deletions
diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass
index c393d99644..9c6fe67d49 100644
--- a/meta/classes/toolchain-scripts.bbclass
+++ b/meta/classes/toolchain-scripts.bbclass
@@ -6,6 +6,10 @@ toolchain_create_sdk_env_script () {
6 script=${SDK_OUTPUT}/${SDKPATH}/environment-setup-${MULTIMACH_TARGET_SYS} 6 script=${SDK_OUTPUT}/${SDKPATH}/environment-setup-${MULTIMACH_TARGET_SYS}
7 rm -f $script 7 rm -f $script
8 touch $script 8 touch $script
9 echo 'if [ ! -e ${SDKPATHNATIVE}/etc/ld.so.cache ]; then' >> $script
10 echo ' echo "Please run ${SDKPATH}/postinstall as root before using the toolchain"' >> $script
11 echo ' exit 1' >> $script
12 echo 'fi' >> $script
9 echo 'export PATH=${SDKPATHNATIVE}${bindir_nativesdk}:${SDKPATHNATIVE}${bindir_nativesdk}/${MULTIMACH_TARGET_SYS}:$PATH' >> $script 13 echo 'export PATH=${SDKPATHNATIVE}${bindir_nativesdk}:${SDKPATHNATIVE}${bindir_nativesdk}/${MULTIMACH_TARGET_SYS}:$PATH' >> $script
10 echo 'export PKG_CONFIG_SYSROOT_DIR=${SDKTARGETSYSROOT}' >> $script 14 echo 'export PKG_CONFIG_SYSROOT_DIR=${SDKTARGETSYSROOT}' >> $script
11 echo 'export PKG_CONFIG_PATH=${SDKTARGETSYSROOT}${libdir}/pkgconfig' >> $script 15 echo 'export PKG_CONFIG_PATH=${SDKTARGETSYSROOT}${libdir}/pkgconfig' >> $script
diff --git a/meta/recipes-tbd/meta/meta-toolchain.bb b/meta/recipes-tbd/meta/meta-toolchain.bb
index 2fab8f94b2..633f5f1990 100644
--- a/meta/recipes-tbd/meta/meta-toolchain.bb
+++ b/meta/recipes-tbd/meta/meta-toolchain.bb
@@ -72,8 +72,15 @@ do_populate_sdk() {
72 #rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}/lib/*.la 72 #rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}/lib/*.la
73 rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}${libdir_nativesdk}/*.la 73 rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}${libdir_nativesdk}/*.la
74 74
75 # Link the ld.so.cache file into the hosts filesystem 75 # Create an appropriate setup so the dynamic loader can find libs in
76 ln -s /etc/ld.so.cache ${SDK_OUTPUT}/${SDKPATHNATIVE}/etc/ld.so.cache 76 # both the host system and the toolchain directories
77 echo ${SDKPATHNATIVE}${libdir} > ${SDK_OUTPUT}/${SDKPATHNATIVE}/etc/ld.so.conf
78 echo ${SDKPATHNATIVE}${base_libdir} >> ${SDK_OUTPUT}/${SDKPATHNATIVE}/etc/ld.so.conf
79 echo "include /etc/ld.so.conf" >> ${SDK_OUTPUT}/${SDKPATHNATIVE}/etc/ld.so.conf
80 echo "#!/bin/sh" > ${SDK_OUTPUT}/${SDKPATH}/postinstall
81 echo "ldconfig -f ${SDKPATHNATIVE}/etc/ld.so.conf -C /${SDKPATHNATIVE}/etc/ld.so.cache" >> ${SDK_OUTPUT}/${SDKPATH}/postinstall
82 chmod a+x ${SDK_OUTPUT}/${SDKPATH}/postinstall
83
77 84
78 # Setup site file for external use 85 # Setup site file for external use
79 siteconfig=${SDK_OUTPUT}/${SDKPATH}/site-config-${MULTIMACH_TARGET_SYS} 86 siteconfig=${SDK_OUTPUT}/${SDKPATH}/site-config-${MULTIMACH_TARGET_SYS}