summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2014-09-10 18:19:31 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-09-11 18:02:55 +0100
commit429802fe6691c8a70ec9735c0db4c6a4e1e1b038 (patch)
tree8bbd8011c093a73172d52a2e01749c77441665ea /meta/classes
parent51e392106e9858eb321bc5597556d9a44bd06c49 (diff)
downloadpoky-429802fe6691c8a70ec9735c0db4c6a4e1e1b038.tar.gz
classes/populate_sdk_base: enable adding custom commands to SDK install script1.7_M3
Add an SDK_POST_INSTALL_COMMAND variable which allows additional commands to be added towards the end of the SDK install script, for e.g. additional processing that needs to be done as part of installing the SDK. (From OE-Core rev: 10df0718d6a626d99beb68cde8d914ee0820d7eb) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/populate_sdk_base.bbclass7
1 files changed, 7 insertions, 0 deletions
diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass
index abfcdc7744..946a1d479b 100644
--- a/meta/classes/populate_sdk_base.bbclass
+++ b/meta/classes/populate_sdk_base.bbclass
@@ -51,6 +51,7 @@ PID = "${@os.getpid()}"
51EXCLUDE_FROM_WORLD = "1" 51EXCLUDE_FROM_WORLD = "1"
52 52
53SDK_PACKAGING_FUNC ?= "create_shar" 53SDK_PACKAGING_FUNC ?= "create_shar"
54SDK_POST_INSTALL_COMMAND ?= ""
54 55
55SDK_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.manifest" 56SDK_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.manifest"
56python write_target_sdk_manifest () { 57python write_target_sdk_manifest () {
@@ -142,10 +143,16 @@ fakeroot create_shar() {
142 # copy in the template shar extractor script 143 # copy in the template shar extractor script
143 cp ${COREBASE}/meta/files/toolchain-shar-template.sh ${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.sh 144 cp ${COREBASE}/meta/files/toolchain-shar-template.sh ${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.sh
144 145
146 cat << "EOF" > ${T}/post_install_command
147${SDK_POST_INSTALL_COMMAND}
148EOF
149 sed -i -e '/@SDK_POST_INSTALL_COMMAND@/r ${T}/post_install_command' ${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.sh
150
145 # substitute variables 151 # substitute variables
146 sed -i -e 's#@SDK_ARCH@#${SDK_ARCH}#g' \ 152 sed -i -e 's#@SDK_ARCH@#${SDK_ARCH}#g' \
147 -e 's#@SDKPATH@#${SDKPATH}#g' \ 153 -e 's#@SDKPATH@#${SDKPATH}#g' \
148 -e 's#@REAL_MULTIMACH_TARGET_SYS@#${REAL_MULTIMACH_TARGET_SYS}#g' \ 154 -e 's#@REAL_MULTIMACH_TARGET_SYS@#${REAL_MULTIMACH_TARGET_SYS}#g' \
155 -e '/@SDK_POST_INSTALL_COMMAND@/d' \
149 ${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.sh 156 ${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.sh
150 157
151 # add execution permission 158 # add execution permission