20
20
# This is ci/actions-templates/windows-builds-template.yaml
21
21
# Do not edit this file in .github/workflows
22
22
build-windows-pr : # job-name skip-master skip-stable
23
- runs-on : windows-latest
23
+ runs-on : ${{ matrix.os || ' windows-latest' }}
24
24
if : ${{ contains('["pull_request", "merge_group"]', github.event_name) }} # skip-master skip-stable
25
25
env :
26
26
RUSTFLAGS : -Ctarget-feature=+crt-static
45
45
arch : x86_64
46
46
mingwdir : mingw64
47
47
gcc : x86_64-w64-mingw32-gcc
48
+ - target : aarch64-pc-windows-msvc
49
+ # Architecture of the rustup build that installs Rust in this workflow.
50
+ rustup_arch : aarch64
51
+ os : windows-11-arm
52
+ run_tests : YES
48
53
steps :
49
54
- uses : actions/checkout@v4
50
55
# v2 defaults to a shallow checkout, but we need at least to the previous tag
@@ -106,11 +111,13 @@ jobs:
106
111
key : ${{ github.base_ref }}-${{ github.head_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
107
112
restore-keys : ${{ github.base_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
108
113
- name : Install Rustup using win.rustup.rs
114
+ env :
115
+ RUSTUP_ARCH : ${{ matrix.rustup_arch || 'x86_64' }}
109
116
run : |
110
117
# Disable the download progress bar which can cause perf issues
111
118
$ProgressPreference = "SilentlyContinue"
112
- Invoke-WebRequest https://win.rustup.rs/ -OutFile rustup-init.exe
113
- .\rustup-init.exe -y --default-host=x86_64 -pc-windows-msvc --profile=minimal
119
+ Invoke-WebRequest " https://win.rustup.rs/${env:RUSTUP_ARCH}" -OutFile rustup-init.exe
120
+ .\rustup-init.exe -y --default-host=${env:RUSTUP_ARCH} -pc-windows-msvc --profile=minimal
114
121
del rustup-init.exe
115
122
shell : powershell
116
123
- name : Ensure stable toolchain is up to date
@@ -185,7 +192,7 @@ jobs:
185
192
# This is ci/actions-templates/windows-builds-template.yaml
186
193
# Do not edit this file in .github/workflows
187
194
build-windows-master : # job-name skip-pr skip-stable
188
- runs-on : windows-latest
195
+ runs-on : ${{ matrix.os || ' windows-latest' }}
189
196
if : ${{ (github.event_name == 'push' && github.ref_name == 'master') }} # skip-pr skip-stable
190
197
env :
191
198
RUSTFLAGS : -Ctarget-feature=+crt-static
@@ -210,6 +217,11 @@ jobs:
210
217
arch : x86_64
211
218
mingwdir : mingw64
212
219
gcc : x86_64-w64-mingw32-gcc
220
+ - target : aarch64-pc-windows-msvc
221
+ # Architecture of the rustup build that installs Rust in this workflow.
222
+ rustup_arch : aarch64
223
+ os : windows-11-arm
224
+ run_tests : YES
213
225
steps :
214
226
- uses : actions/checkout@v4
215
227
# v2 defaults to a shallow checkout, but we need at least to the previous tag
@@ -271,11 +283,13 @@ jobs:
271
283
key : ${{ github.base_ref }}-${{ github.head_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
272
284
restore-keys : ${{ github.base_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
273
285
- name : Install Rustup using win.rustup.rs
286
+ env :
287
+ RUSTUP_ARCH : ${{ matrix.rustup_arch || 'x86_64' }}
274
288
run : |
275
289
# Disable the download progress bar which can cause perf issues
276
290
$ProgressPreference = "SilentlyContinue"
277
- Invoke-WebRequest https://win.rustup.rs/ -OutFile rustup-init.exe
278
- .\rustup-init.exe -y --default-host=x86_64 -pc-windows-msvc --profile=minimal
291
+ Invoke-WebRequest " https://win.rustup.rs/${env:RUSTUP_ARCH}" -OutFile rustup-init.exe
292
+ .\rustup-init.exe -y --default-host=${env:RUSTUP_ARCH} -pc-windows-msvc --profile=minimal
279
293
del rustup-init.exe
280
294
shell : powershell
281
295
- name : Ensure stable toolchain is up to date
@@ -350,7 +364,7 @@ jobs:
350
364
# This is ci/actions-templates/windows-builds-template.yaml
351
365
# Do not edit this file in .github/workflows
352
366
build-windows-stable : # job-name skip-master skip-pr
353
- runs-on : windows-latest
367
+ runs-on : ${{ matrix.os || ' windows-latest' }}
354
368
if : ${{ github.event_name == 'push' && github.ref_name == 'stable' || github.event_name == 'schedule' }} # skip-pr skip-master
355
369
env :
356
370
RUSTFLAGS : -Ctarget-feature=+crt-static
@@ -377,6 +391,11 @@ jobs:
377
391
arch : x86_64
378
392
mingwdir : mingw64
379
393
gcc : x86_64-w64-mingw32-gcc
394
+ - target : aarch64-pc-windows-msvc
395
+ # Architecture of the rustup build that installs Rust in this workflow.
396
+ rustup_arch : aarch64
397
+ os : windows-11-arm
398
+ run_tests : YES
380
399
- target : i686-pc-windows-gnu # skip-pr skip-master
381
400
arch : i686 # skip-pr skip-master
382
401
mingwdir : mingw32 # skip-pr skip-master
@@ -442,11 +461,13 @@ jobs:
442
461
key : ${{ github.base_ref }}-${{ github.head_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
443
462
restore-keys : ${{ github.base_ref }}-${{ matrix.target }}-${{ matrix.mode }}-cargo-target-dir-${{ steps.cargo-target-cache.outputs.rust_hash }}-${{ hashFiles('**/Cargo.lock') }}
444
463
- name : Install Rustup using win.rustup.rs
464
+ env :
465
+ RUSTUP_ARCH : ${{ matrix.rustup_arch || 'x86_64' }}
445
466
run : |
446
467
# Disable the download progress bar which can cause perf issues
447
468
$ProgressPreference = "SilentlyContinue"
448
- Invoke-WebRequest https://win.rustup.rs/ -OutFile rustup-init.exe
449
- .\rustup-init.exe -y --default-host=x86_64 -pc-windows-msvc --profile=minimal
469
+ Invoke-WebRequest " https://win.rustup.rs/${env:RUSTUP_ARCH}" -OutFile rustup-init.exe
470
+ .\rustup-init.exe -y --default-host=${env:RUSTUP_ARCH} -pc-windows-msvc --profile=minimal
450
471
del rustup-init.exe
451
472
shell : powershell
452
473
- name : Ensure stable toolchain is up to date
0 commit comments