diff --git a/tests/programs/_build_clang_native.sh b/tests/programs/_build_clang_native.sh index dfe10589..2fda2995 100644 --- a/tests/programs/_build_clang_native.sh +++ b/tests/programs/_build_clang_native.sh @@ -3,7 +3,7 @@ set -ex ROOT_DIR=$(pwd) CC="clang-18" LD="ld.lld-18" -CCFLAGS="--target=riscv64 -march=rv64imac_zba_zbb_zbc_zbs -nostdinc -isystem $ROOT_DIR/deps/musl/release/include -c -fdata-sections -ffunction-sections" +CFLAGS="--target=riscv64 -march=rv64imac_zba_zbb_zbc_zbs -nostdinc -isystem $ROOT_DIR/deps/musl/release/include -c -fdata-sections -ffunction-sections" LDFLAGS="--gc-sections -nostdlib --sysroot $ROOT_DIR/deps/musl/release -L$ROOT_DIR/deps/musl/release/lib -lc -lgcc" if [ ! -d deps ]; then @@ -24,4 +24,4 @@ if [ ! -d deps/musl/release ]; then cd - fi -$CC $CCFLAGS clang_sample.c -o clang_sample.o && $LD $LDFLAGS clang_sample.o -o clang_sample && rm clang_sample.o +$CC $CFLAGS clang_sample.c -o clang_sample.o && $LD $LDFLAGS clang_sample.o -o clang_sample && rm clang_sample.o