diff options
author | Joshua Watt <jpewhacker@gmail.com> | 2018-02-12 10:52:07 -0600 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-02-16 18:05:38 +0000 |
commit | cf85c5a490b7044f2a5291c7df646248e81770f7 (patch) | |
tree | f505ed79bf872b358f29e563199fb723e7d7b977 /meta/classes/toolchain-scripts.bbclass | |
parent | f51f28b7b927fde9489e244cb812b562f28bbafa (diff) | |
download | poky-cf85c5a490b7044f2a5291c7df646248e81770f7.tar.gz |
toolchain-shar-extract: Add post-relocate scripts
Recipes can now install post-relocation scripts which will be run when
the SDK is installed.
(From OE-Core rev: 93ec145f421a45077b40ae99ee6a96bc11f91f18)
Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/toolchain-scripts.bbclass')
-rw-r--r-- | meta/classes/toolchain-scripts.bbclass | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/meta/classes/toolchain-scripts.bbclass b/meta/classes/toolchain-scripts.bbclass index 9bcfe708c7..eeb320d15a 100644 --- a/meta/classes/toolchain-scripts.bbclass +++ b/meta/classes/toolchain-scripts.bbclass | |||
@@ -116,6 +116,21 @@ fi | |||
116 | EOF | 116 | EOF |
117 | } | 117 | } |
118 | 118 | ||
119 | toolchain_create_post_relocate_script() { | ||
120 | script=$1 | ||
121 | rm -f $script | ||
122 | touch $script | ||
123 | |||
124 | cat >> $script <<EOF | ||
125 | if [ -d "${SDKPATHNATIVE}/post-relocate-setup.d/" ]; then | ||
126 | for s in ${SDKPATHNATIVE}/post-relocate-setup.d/*.sh; do | ||
127 | \$s "\$1" | ||
128 | done | ||
129 | rm -rf "${SDKPATHNATIVE}/post-relocate-setup.d" | ||
130 | fi | ||
131 | EOF | ||
132 | } | ||
133 | |||
119 | #we get the cached site config in the runtime | 134 | #we get the cached site config in the runtime |
120 | TOOLCHAIN_CONFIGSITE_NOCACHE = "${@siteinfo_get_files(d)}" | 135 | TOOLCHAIN_CONFIGSITE_NOCACHE = "${@siteinfo_get_files(d)}" |
121 | TOOLCHAIN_CONFIGSITE_SYSROOTCACHE = "${STAGING_DIR}/${MLPREFIX}${MACHINE}/${target_datadir}/${TARGET_SYS}_config_site.d" | 136 | TOOLCHAIN_CONFIGSITE_SYSROOTCACHE = "${STAGING_DIR}/${MLPREFIX}${MACHINE}/${target_datadir}/${TARGET_SYS}_config_site.d" |