authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-09-09 14:08:15+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-09-09 18:22:16+02:00
log47f132b7705f4ded6d671c1f5abe0b9003e57e44
tree6cd1219fb5459fc39a4b2ee91cb38af6e3b05b68
parentb877cf3fe54c93117400aaf9ff72d92133b42c03
signature Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

ci: use CMAKE_{C,CXX}_COMPILER instead of the CC/CXX env dance


25 files changed, 52 insertions(+), 205 deletions(-)

ci/aarch64-freebsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-freebsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-linux-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-netbsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-netbsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-openbsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/aarch64-openbsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/loongarch64-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/loongarch64-linux-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/powerpc64le-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/powerpc64le-linux-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/riscv64-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/riscv64-linux-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/s390x-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/s390x-linux-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-freebsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-freebsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-linux-debug-llvm.sh+2-8
......@@ -22,13 +22,12 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug-llvm
2323cd build-debug-llvm
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
......@@ -36,11 +35,6 @@ cmake .. \
3635 -DZIG_EXTRA_BUILD_ARGS="-Duse-llvm=true" \
3736 -GNinja
3837
39# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
40# so that installation and testing do not get affected by them.
41unset CC
42unset CXX
43
4438ninja install
4539
4640# Must be done after zig cc is finished.
ci/x86_64-linux-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-linux-release.sh+4-13
......@@ -28,24 +28,18 @@ cc -o bootstrap bootstrap.c
2828mkdir -p build-release
2929cd build-release
3030
31export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
32export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
33
3431cmake .. \
3532 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3633 -DCMAKE_PREFIX_PATH="$PREFIX" \
3734 -DCMAKE_BUILD_TYPE=Release \
35 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
36 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3837 -DZIG_TARGET_TRIPLE="$TARGET" \
3938 -DZIG_TARGET_MCPU="$MCPU" \
4039 -DZIG_STATIC=ON \
4140 -DZIG_NO_LIB=ON \
4241 -GNinja
4342
44# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
45# so that installation and testing do not get affected by them.
46unset CC
47unset CXX
48
4943ninja install
5044
5145# Must not be set while using the other `zig cc` which has its own zig lib dir.
......@@ -98,22 +92,19 @@ stage3-release/bin/zig build update-zig1
9892mkdir -p ../build-new
9993cd ../build-new
10094
101export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
102export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
10395unset ZIG_LIB_DIR
10496
10597cmake .. \
10698 -DCMAKE_PREFIX_PATH="$PREFIX" \
10799 -DCMAKE_BUILD_TYPE=Release \
100 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
101 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
108102 -DZIG_TARGET_TRIPLE="$TARGET" \
109103 -DZIG_TARGET_MCPU="$MCPU" \
110104 -DZIG_STATIC=ON \
111105 -DZIG_NO_LIB=ON \
112106 -GNinja
113107
114unset CC
115unset CXX
116
117108ninja install
118109
119110export ZIG_LIB_DIR="$PWD/../lib"
ci/x86_64-netbsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-netbsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-openbsd-debug.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-debug
2323cd build-debug
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Debug \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.
ci/x86_64-openbsd-release.sh+2-8
......@@ -22,24 +22,18 @@ export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
2222mkdir -p build-release
2323cd build-release
2424
25export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
26export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
27
2825cmake .. \
2926 -DCMAKE_INSTALL_PREFIX="stage3-release" \
3027 -DCMAKE_PREFIX_PATH="$PREFIX" \
3128 -DCMAKE_BUILD_TYPE=Release \
29 -DCMAKE_C_COMPILER="$ZIG;cc;-target;$TARGET;-mcpu=$MCPU" \
30 -DCMAKE_CXX_COMPILER="$ZIG;c++;-target;$TARGET;-mcpu=$MCPU" \
3231 -DZIG_TARGET_TRIPLE="$TARGET" \
3332 -DZIG_TARGET_MCPU="$MCPU" \
3433 -DZIG_STATIC=ON \
3534 -DZIG_NO_LIB=ON \
3635 -GNinja
3736
38# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
39# so that installation and testing do not get affected by them.
40unset CC
41unset CXX
42
4337ninja install
4438
4539# Must be done after zig cc is finished.