3838
3939if [ " ${TEST_VERBATIM:- } " = " 1" ]; then
4040 verb_path=$( cmd.exe //C echo \\\\ ? \\ %cd%\\ testcrate\\ target2)
41- cargo build --manifest-path testcrate/Cargo.toml --target $target --target-dir $verb_path --features c
41+ cargo build --manifest-path testcrate/Cargo.toml --target " $target " --target-dir " $verb_path " --features c
4242fi
4343
4444if [ -d /builtins-target ]; then
45- rlib_paths=/builtins-target/" ${target} " /debug/deps/libcompiler_builtins-* .rlib
45+ rlib_paths=( /builtins-target/" ${target} " /debug/deps/libcompiler_builtins-* .rlib )
4646else
47- rlib_paths=target/" ${target} " /debug/deps/libcompiler_builtins-* .rlib
47+ rlib_paths=( target/" ${target} " /debug/deps/libcompiler_builtins-* .rlib )
4848fi
4949
5050# Remove any existing artifacts from previous tests that don't set #![compiler_builtins]
51- rm -f $ rlib_paths
51+ rm -f " ${ rlib_paths[@]} "
5252
5353cargo build --target " $target "
5454cargo build --target " $target " --release
@@ -84,7 +84,7 @@ if [[ "$TOOLCHAIN" == *i686-pc-windows-gnu ]]; then
8484fi
8585
8686# Look out for duplicated symbols when we include the compiler-rt (C) implementation
87- for rlib in $ rlib_paths; do
87+ for rlib in " ${ rlib_paths[@]} " ; do
8888 set +x
8989 echo " ================================================================"
9090 echo " checking $rlib for duplicate symbols"
@@ -108,7 +108,7 @@ for rlib in $rlib_paths; do
108108 fi
109109done
110110
111- rm -f $ rlib_paths
111+ rm -f " ${ rlib_paths[@]} "
112112
113113build_intrinsics () {
114114 cargo build --target " $target " -v --example intrinsics " $@ "
@@ -128,7 +128,7 @@ CARGO_PROFILE_RELEASE_LTO=true \
128128 cargo build --target " $target " --example intrinsics --release
129129
130130# Ensure no references to any symbols from core
131- for rlib in $( echo $ rlib_paths) ; do
131+ for rlib in " ${ rlib_paths[@]} " ; do
132132 set +x
133133 echo " ================================================================"
134134 echo " checking $rlib for references to core"
0 commit comments