From: Peter Bergin Date: Tue, 23 Aug 2022 11:02:27 +0000 (+0200) Subject: rust-cross-canadian: rename shell variables for easier appends X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~3158 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=74307f57ad0b3c538be0add11028e4e6199a7662;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git rust-cross-canadian: rename shell variables for easier appends Make unique shell variable names for cargo and rust setup scripts. This change will make it easier to append to the scripts in a bbappend file by using the variable for the script. Before this change it was only possible for the last script as they shared the same variable name. Signed-off-by: Peter Bergin Signed-off-by: Luca Ceresoli Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-devtools/rust/rust-cross-canadian.inc b/meta/recipes-devtools/rust/rust-cross-canadian.inc index 77d45a37a31..7bf75a4712e 100644 --- a/meta/recipes-devtools/rust/rust-cross-canadian.inc +++ b/meta/recipes-devtools/rust/rust-cross-canadian.inc @@ -37,17 +37,17 @@ do_install () { ENV_SETUP_DIR=${D}${base_prefix}/environment-setup.d mkdir "${ENV_SETUP_DIR}" - ENV_SETUP_SH="${ENV_SETUP_DIR}/rust.sh" + RUST_ENV_SETUP_SH="${ENV_SETUP_DIR}/rust.sh" - cat <<- EOF > "${ENV_SETUP_SH}" + cat <<- EOF > "${RUST_ENV_SETUP_SH}" export RUSTFLAGS="--sysroot=\$OECORE_TARGET_SYSROOT/usr -C link-arg=--sysroot=\$OECORE_TARGET_SYSROOT" export RUST_TARGET_PATH="\$OECORE_NATIVE_SYSROOT/usr/lib/${TARGET_SYS}/rustlib" EOF chown -R root.root ${D} - ENV_SETUP_SH="${ENV_SETUP_DIR}/cargo.sh" - cat <<- EOF > "${ENV_SETUP_SH}" + CARGO_ENV_SETUP_SH="${ENV_SETUP_DIR}/cargo.sh" + cat <<- EOF > "${CARGO_ENV_SETUP_SH}" export CARGO_HOME="\$OECORE_TARGET_SYSROOT/home/cargo" mkdir -p "\$CARGO_HOME" # Init the default target once, it might be otherwise user modified.