Skip to content

Commit 1960d5c

Browse files
committed
CI: Build 32 bit linux, windows, and x86_64 macos
1 parent e0be911 commit 1960d5c

File tree

1 file changed

+17
-5
lines changed

1 file changed

+17
-5
lines changed

.github/workflows/build.yml

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ concurrency:
2525

2626
permissions: { }
2727

28-
# TODO: Build for 32 bit windows and linux?
2928
jobs:
3029
build-versions:
3130
strategy:
@@ -34,8 +33,14 @@ jobs:
3433
rust-version: [ stable, beta, nightly, 1.65 ] # Stable, Beta, Nightly, MSRV
3534
info:
3635
- os: macos-latest
36+
target1: aarch64-apple-darwin
37+
target2: x86_64-apple-darwin
3738
- os: ubuntu-latest
39+
target1: x86_64-unknown-linux-gnu
40+
target2: i686-unknown-linux-gnu
3841
- os: windows-latest
42+
target1: x86_64-pc-windows-msvc
43+
target2: i686-pc-windows-msvc
3944
runs-on: ${{ matrix.info.os }}
4045
steps:
4146
- uses: actions/checkout@v4
@@ -45,11 +50,18 @@ jobs:
4550
id: toolchain
4651
with:
4752
toolchain: ${{ matrix.rust-version }}
53+
targets: ${{ matrix.info.target1 }},${{ matrix.info.target2 }}
4854
- uses: Swatinem/rust-cache@v2
49-
- name: Build
50-
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace
51-
- name: Build release
52-
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace --release
55+
with:
56+
key: ${{ matrix.info.target1 }}+${{ matrix.info.target2 }}
57+
- name: Build (1)
58+
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace --target ${{ matrix.info.target1 }}
59+
- name: Build release (1)
60+
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace --release --target ${{ matrix.info.target1 }}
61+
- name: Build (2)
62+
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace --target ${{ matrix.info.target2 }}
63+
- name: Build release (2)
64+
run: cargo +${{steps.toolchain.outputs.name}} build --verbose --workspace --release --target ${{ matrix.info.target2 }}
5365

5466
build-ink-cross:
5567
strategy:

0 commit comments

Comments
 (0)