authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-02-19 16:23:59-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-03-15 10:48:12-07:00
logc641af3cba8f0e8e6bba0ba26dce18bd225a832e
tree20258ba8af631bdb11eeafa0f37ab6d1d256341c
parentcb094700631ea1ae238ea678c192ce4f85fbecc0

CI: use -j1 like a coward

Zig's build script has several race conditions preventing proper concurrent builds from working. By using -j1 for now, finishing this branch (concurrent zig builds) is untangled from the separate problem of correcting concurrency issues with zig's own build script. In other words, let's solve one problem at a time.

8 files changed, 11 insertions(+), 0 deletions(-)

ci/aarch64-linux-debug.sh+1
...@@ -60,6 +60,7 @@ stage3-debug/bin/zig build -Dtarget=arm-linux-musleabihf...@@ -60,6 +60,7 @@ stage3-debug/bin/zig build -Dtarget=arm-linux-musleabihf
60# TODO: add -fqemu back to this line60# TODO: add -fqemu back to this line
6161
62stage3-debug/bin/zig build test docs \62stage3-debug/bin/zig build test docs \
63 -j1 \
63 -fwasmtime \64 -fwasmtime \
64 -Dstatic-llvm \65 -Dstatic-llvm \
65 -Dtarget=native-native-musl \66 -Dtarget=native-native-musl \
ci/aarch64-linux-release.sh+1
...@@ -60,6 +60,7 @@ stage3-release/bin/zig build -Dtarget=arm-linux-musleabihf...@@ -60,6 +60,7 @@ stage3-release/bin/zig build -Dtarget=arm-linux-musleabihf
60# TODO: add -fqemu back to this line60# TODO: add -fqemu back to this line
6161
62stage3-release/bin/zig build test docs \62stage3-release/bin/zig build test docs \
63 -j1 \
63 -fwasmtime \64 -fwasmtime \
64 -Dstatic-llvm \65 -Dstatic-llvm \
65 -Dtarget=native-native-musl \66 -Dtarget=native-native-musl \
ci/aarch64-macos.sh+1
...@@ -44,6 +44,7 @@ PATH="$HOME/local/bin:$PATH" cmake .. \...@@ -44,6 +44,7 @@ PATH="$HOME/local/bin:$PATH" cmake .. \
44$HOME/local/bin/ninja install44$HOME/local/bin/ninja install
4545
46stage3-release/bin/zig build test docs \46stage3-release/bin/zig build test docs \
47 -j1 \
47 --zig-lib-dir "$(pwd)/../lib" \48 --zig-lib-dir "$(pwd)/../lib" \
48 -Denable-macos-sdk \49 -Denable-macos-sdk \
49 -Dstatic-llvm \50 -Dstatic-llvm \
ci/x86_64-linux-debug.sh+1
...@@ -58,6 +58,7 @@ stage3-debug/bin/zig fmt --check .. \...@@ -58,6 +58,7 @@ stage3-debug/bin/zig fmt --check .. \
58stage3-debug/bin/zig build -Dtarget=arm-linux-musleabihf58stage3-debug/bin/zig build -Dtarget=arm-linux-musleabihf
5959
60stage3-debug/bin/zig build test docs \60stage3-debug/bin/zig build test docs \
61 -j1 \
61 -fqemu \62 -fqemu \
62 -fwasmtime \63 -fwasmtime \
63 -Dstatic-llvm \64 -Dstatic-llvm \
ci/x86_64-linux-release.sh+1
...@@ -59,6 +59,7 @@ stage3-release/bin/zig fmt --check .. \...@@ -59,6 +59,7 @@ stage3-release/bin/zig fmt --check .. \
59stage3-release/bin/zig build -Dtarget=arm-linux-musleabihf59stage3-release/bin/zig build -Dtarget=arm-linux-musleabihf
6060
61stage3-release/bin/zig build test docs \61stage3-release/bin/zig build test docs \
62 -j1 \
62 -fqemu \63 -fqemu \
63 -fwasmtime \64 -fwasmtime \
64 -Dstatic-llvm \65 -Dstatic-llvm \
ci/x86_64-macos-debug.sh+1
...@@ -48,6 +48,7 @@ cmake .. \...@@ -48,6 +48,7 @@ cmake .. \
48make $JOBS install48make $JOBS install
4949
50stage3/bin/zig build test docs \50stage3/bin/zig build test docs \
51 -j1 \
51 --zig-lib-dir "$(pwd)/../lib" \52 --zig-lib-dir "$(pwd)/../lib" \
52 -Denable-macos-sdk \53 -Denable-macos-sdk \
53 -Dstatic-llvm \54 -Dstatic-llvm \
ci/x86_64-macos-release.sh+1
...@@ -48,6 +48,7 @@ cmake .. \...@@ -48,6 +48,7 @@ cmake .. \
48make $JOBS install48make $JOBS install
4949
50stage3/bin/zig build test docs \50stage3/bin/zig build test docs \
51 -j1 \
51 --zig-lib-dir "$(pwd)/../lib" \52 --zig-lib-dir "$(pwd)/../lib" \
52 -Denable-macos-sdk \53 -Denable-macos-sdk \
53 -Dstatic-llvm \54 -Dstatic-llvm \
test/tests.zig+4
...@@ -1067,6 +1067,10 @@ pub const StandaloneContext = struct {...@@ -1067,6 +1067,10 @@ pub const StandaloneContext = struct {
1067 zig_args.append(rel_zig_exe) catch unreachable;1067 zig_args.append(rel_zig_exe) catch unreachable;
1068 zig_args.append("build") catch unreachable;1068 zig_args.append("build") catch unreachable;
10691069
1070 // TODO: fix the various non-concurrency-safe issues in zig's standalone tests,
1071 // and then remove this!
1072 zig_args.append("-j1") catch @panic("OOM");
1073
1070 zig_args.append("--build-file") catch unreachable;1074 zig_args.append("--build-file") catch unreachable;
1071 zig_args.append(b.pathFromRoot(build_file)) catch unreachable;1075 zig_args.append(b.pathFromRoot(build_file)) catch unreachable;
10721076