44 - push
55 - pull_request
66
7+ defaults :
8+ run :
9+ shell : bash
10+
11+ permissions : {}
12+
13+ env :
14+ # Disabling incr comp reduces cache size and incr comp doesn't save as much
15+ # on CI anyway.
16+ CARGO_BUILD_INCREMENTAL : false
17+ # Rust's CI denies warnings. Deny them here too to ensure subtree syncs don't
18+ # fail because of warnings.
19+ RUSTFLAGS : " -Dwarnings"
20+
721jobs :
822 rustfmt :
923 runs-on : ubuntu-latest
3044 runs-on : ${{ matrix.os }}
3145 timeout-minutes : 60
3246
33- defaults :
34- run :
35- shell : bash
47+ env :
48+ CG_CLIF_EXPENSIVE_CHECKS : 1
3649
3750 strategy :
3851 fail-fast : false
@@ -48,15 +61,19 @@ jobs:
4861 - os : ubuntu-latest
4962 env :
5063 TARGET_TRIPLE : x86_64-pc-windows-gnu
64+ apt_deps : gcc-mingw-w64-x86-64 wine-stable
5165 - os : ubuntu-latest
5266 env :
5367 TARGET_TRIPLE : aarch64-unknown-linux-gnu
68+ apt_deps : gcc-aarch64-linux-gnu qemu-user
5469 - os : ubuntu-latest
5570 env :
5671 TARGET_TRIPLE : s390x-unknown-linux-gnu
72+ apt_deps : gcc-s390x-linux-gnu qemu-user
5773 - os : ubuntu-latest
5874 env :
5975 TARGET_TRIPLE : riscv64gc-unknown-linux-gnu
76+ apt_deps : gcc-riscv64-linux-gnu qemu-user
6077 - os : windows-latest
6178 env :
6279 TARGET_TRIPLE : x86_64-pc-windows-msvc
@@ -81,29 +98,11 @@ jobs:
8198 if : matrix.os == 'windows-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
8299 run : rustup set default-host x86_64-pc-windows-gnu
83100
84- - name : Install MinGW toolchain and wine
85- if : matrix.os == 'ubuntu-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
86- run : |
87- sudo apt-get update
88- sudo apt-get install -y gcc-mingw-w64-x86-64 wine-stable
89-
90- - name : Install AArch64 toolchain and qemu
91- if : matrix.os == 'ubuntu-latest' && matrix.env.TARGET_TRIPLE == 'aarch64-unknown-linux-gnu'
92- run : |
93- sudo apt-get update
94- sudo apt-get install -y gcc-aarch64-linux-gnu qemu-user
95-
96- - name : Install s390x toolchain and qemu
97- if : matrix.env.TARGET_TRIPLE == 's390x-unknown-linux-gnu'
101+ - name : Install toolchain and emulator
102+ if : matrix.apt_deps != null
98103 run : |
99104 sudo apt-get update
100- sudo apt-get install -y gcc-s390x-linux-gnu qemu-user
101-
102- - name : Install riscv64gc toolchain and qemu
103- if : matrix.env.TARGET_TRIPLE == 'riscv64gc-unknown-linux-gnu'
104- run : |
105- sudo apt-get update
106- sudo apt-get install -y gcc-riscv64-linux-gnu qemu-user
105+ sudo apt-get install -y ${{ matrix.apt_deps }}
107106
108107 - name : Prepare dependencies
109108 run : ./y.sh prepare
@@ -143,10 +142,6 @@ jobs:
143142 runs-on : ubuntu-latest
144143 timeout-minutes : 60
145144
146- defaults :
147- run :
148- shell : bash
149-
150145 steps :
151146 - uses : actions/checkout@v4
152147
@@ -169,10 +164,6 @@ jobs:
169164 runs-on : ubuntu-latest
170165 timeout-minutes : 60
171166
172- defaults :
173- run :
174- shell : bash
175-
176167 steps :
177168 - uses : actions/checkout@v4
178169
@@ -194,20 +185,16 @@ jobs:
194185 run : ./y.sh prepare
195186
196187 - name : Build
197- run : CI_OPT=1 ./y.sh build --sysroot none
188+ run : ./y.sh build --sysroot none
198189
199190 - name : Benchmark
200- run : CI_OPT=1 ./y.sh bench
191+ run : ./y.sh bench
201192
202193
203194 dist :
204195 runs-on : ${{ matrix.os }}
205196 timeout-minutes : 60
206197
207- defaults :
208- run :
209- shell : bash
210-
211198 strategy :
212199 fail-fast : false
213200 matrix :
@@ -253,10 +240,10 @@ jobs:
253240 run : ./y.sh prepare
254241
255242 - name : Build backend
256- run : CI_OPT=1 ./y.sh build --sysroot none
243+ run : ./y.sh build --sysroot none
257244
258245 - name : Build sysroot
259- run : CI_OPT=1 ./y.sh build
246+ run : ./y.sh build
260247
261248 - name : Package prebuilt cg_clif
262249 run : tar cvfJ cg_clif.tar.xz dist
0 commit comments