summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/meta/buildtools-tarball.bb
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2013-06-24 09:47:15 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-06-25 17:44:58 +0100
commiteea24c6545ea4af1b8cbacb923d7613bd29e7933 (patch)
tree8ae80503cba8eb76e8e3fd5b8d6031d082d21f61 /meta/recipes-core/meta/buildtools-tarball.bb
parent216e4dc4aa3bf49afa70b793ecc8a683783c0675 (diff)
downloadpoky-eea24c6545ea4af1b8cbacb923d7613bd29e7933.tar.gz
poky-eea24c6545ea4af1b8cbacb923d7613bd29e7933.tar.bz2
poky-eea24c6545ea4af1b8cbacb923d7613bd29e7933.zip
buildtools-tarball: Change the way the SDK is sanitized
The previous method of shrinking down the scale of the environment-setup file would not work properly when the target is configured with multilibs. In addition, the configured machine name and similar settings could leak into the SDK naming. This was resolved by clearing the SDK generated files and generating our own custom files. Note, the name of the environment-setup now is suffixed with the SDK_SYS. (From OE-Core rev: 778cd8d2110ef2db5ff4ae4f0b55c52a8f1ea334) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/meta/buildtools-tarball.bb')
-rw-r--r--meta/recipes-core/meta/buildtools-tarball.bb15
1 files changed, 11 insertions, 4 deletions
diff --git a/meta/recipes-core/meta/buildtools-tarball.bb b/meta/recipes-core/meta/buildtools-tarball.bb
index 7a91c6b6ac..387db75373 100644
--- a/meta/recipes-core/meta/buildtools-tarball.bb
+++ b/meta/recipes-core/meta/buildtools-tarball.bb
@@ -48,8 +48,15 @@ inherit meta
inherit populate_sdk
create_sdk_files_append () {
- rm -f ${SDK_OUTPUT}/${SDKPATH}/site-config*
-
- cat ${SDK_OUTPUT}/${SDKPATH}/environment-setup* | grep " PATH=\|OECORE_NATIVE_SYSROOT" > ${WORKDIR}/envtmp
- mv ${WORKDIR}/envtmp ${SDK_OUTPUT}/${SDKPATH}/environment-setup*
+ rm -f ${SDK_OUTPUT}/${SDKPATH}/site-config-*
+ rm -f ${SDK_OUTPUT}/${SDKPATH}/environment-setup-*
+ rm -f ${SDK_OUTPUT}/${SDKPATH}/version-*
+
+ # Generate new (mini) sdk-environment-setup file
+ script=${1:-${SDK_OUTPUT}/${SDKPATH}/environment-setup-${SDK_SYS}}
+ touch $script
+ echo 'export PATH=${SDKPATHNATIVE}${bindir_nativesdk}:$PATH' >> $script
+ echo 'export OECORE_NATIVE_SYSROOT="${SDKPATHNATIVE}"' >> $script
+
+ toolchain_create_sdk_version ${SDK_OUTPUT}/${SDKPATH}/version-${SDK_SYS}
}