File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ export CARGO_TARGET_DIR = "${B}"
1919
2020RUST_TARGET = "${@ rust_target (d , 'TARGET' )}"
2121RUST_BUILD = "${@ rust_target (d , 'BUILD' )}"
22+ CARGO_TARGET_LINKER_NAME = "${@ d . getVar ('RUST_TARGET' , True ). replace ('-' , '_' ). upper ()}"
2223
2324# Additional flags passed directly to the "cargo build" invocation
2425EXTRA_CARGO_FLAGS ??= ""
@@ -114,7 +115,7 @@ cargo_bin_do_compile() {
114115 export CARGO_UNSTABLE_TARGET_APPLIES_TO_HOST = "true"
115116 export CARGO_UNSTABLE_HOST_CONFIG = "true"
116117 export CARGO_TARGET_APPLIES_TO_HOST = "false"
117- export CARGO_TARGET_ ${@ rust_target ( d , 'TARGET' ) . replace ( '-' , '_' ) . upper () }_LINKER = "${WRAPPER_DIR} /linker-wrapper.sh"
118+ export CARGO_TARGET_${CARGO_TARGET_LINKER_NAME }_LINKER = "${WRAPPER_DIR} /linker-wrapper.sh"
118119 export CARGO_HOST_LINKER = "${WRAPPER_DIR} /linker-native-wrapper.sh"
119120 export CARGO_BUILD_FLAGS = "-C rpath"
120121 export CARGO_PROFILE_RELEASE_DEBUG = "true"
You can’t perform that action at this time.
0 commit comments