manually fix some shellcheck warnings

This commit is contained in:
Jakob Hellermann 2020-11-04 15:59:20 +01:00
parent d6a9dfa3d4
commit 0f10f2a960
4 changed files with 10 additions and 7 deletions

View file

@ -10,7 +10,7 @@ cmd=$1
shift || true
if [[ "$cmd" = "jit" ]]; then
cargo "+${TOOLCHAIN}" rustc $@ -- --jit
cargo "+${TOOLCHAIN}" rustc "$@" -- --jit
else
cargo "+${TOOLCHAIN}" "$cmd" $@
cargo "+${TOOLCHAIN}" "$cmd" "$@"
fi

7
scripts/config.sh Normal file → Executable file
View file

@ -1,3 +1,5 @@
#!/bin/bash
set -e
unamestr=$(uname)
@ -39,7 +41,7 @@ echo
export RUSTC_WRAPPER=
fi
dir=$(cd $(dirname "$BASH_SOURCE"); pwd)
dir=$(cd "$(dirname "${BASH_SOURCE[0]}")"; pwd)
export RUSTC=$dir"/cg_clif"
export RUSTFLAGS=$linker
@ -51,7 +53,8 @@ if [[ $(uname) == 'Darwin' ]]; then
export RUSTFLAGS="$RUSTFLAGS -Clink-arg=-undefined -Clink-arg=dynamic_lookup"
fi
export LD_LIBRARY_PATH="$dir:$(rustc --print sysroot)/lib:$dir/target/out:$dir/sysroot/lib/rustlib/$TARGET_TRIPLE/lib"
LD_LIBRARY_PATH="$dir:$(rustc --print sysroot)/lib:$dir/target/out:$dir/sysroot/lib/rustlib/$TARGET_TRIPLE/lib"
export LD_LIBRARY_PATH
export DYLD_LIBRARY_PATH=$LD_LIBRARY_PATH
export CG_CLIF_DISPLAY_CG_TIME=1

View file

@ -4,7 +4,7 @@ set -e
source build/config.sh
export CG_CLIF_INCR_CACHE_DISABLED=1
MY_RUSTC=$RUSTC" "$RUSTFLAGS" -L crate=target/out --out-dir target/out -Cdebuginfo=2"
MY_RUSTC="$RUSTC $RUSTFLAGS -L crate=target/out --out-dir target/out -Cdebuginfo=2"
function no_sysroot_tests() {
echo "[BUILD] mini_core"

View file

@ -3,13 +3,13 @@ set -e
export RUSTFLAGS="-Zrun_dsymutil=no"
./build.sh --without-sysroot $@
./build.sh --without-sysroot "$@"
rm -r target/out || true
scripts/tests.sh no_sysroot
./build.sh $@
./build.sh "$@"
scripts/tests.sh base_sysroot
scripts/tests.sh extended_sysroot