Skip to content

Commit 4911aa6

Browse files
committed
Update CI workflow to add macOS-x86_64 support and enhance build configuration
1 parent da5e0bd commit 4911aa6

1 file changed

Lines changed: 22 additions & 11 deletions

File tree

.github/workflows/ci.yml

Lines changed: 22 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,9 @@ jobs:
5454
- name: macos-aarch64
5555
os: macos-latest
5656
artifact: act
57+
- name: macos-x86_64
58+
os: macos-26-intel
59+
artifact: act
5760
- name: windows-x86_64
5861
os: windows-latest
5962
artifact: act.exe
@@ -73,30 +76,38 @@ jobs:
7376
name: act-${{ matrix.name }}
7477
path: target/release/${{ matrix.artifact }}
7578

76-
build-cross:
79+
build-zigbuild:
7780
needs: [check, fmt]
78-
name: Build (linux-riscv64)
81+
name: Build (${{ matrix.name }})
7982
runs-on: ubuntu-latest
83+
strategy:
84+
matrix:
85+
include:
86+
- name: linux-x86_64-musl
87+
target: x86_64-unknown-linux-musl
88+
- name: linux-aarch64-musl
89+
target: aarch64-unknown-linux-musl
90+
- name: linux-riscv64-gnu
91+
target: riscv64gc-unknown-linux-gnu
92+
- name: linux-riscv64-musl
93+
target: riscv64gc-unknown-linux-musl
8094
steps:
8195
- uses: actions/checkout@v6
8296
with:
8397
submodules: true
8498
- uses: dtolnay/rust-toolchain@nightly
8599
with:
86-
targets: riscv64gc-unknown-linux-gnu
100+
targets: ${{ matrix.target }}
87101
- uses: Swatinem/rust-cache@v2
88102
with:
89-
key: riscv64
90-
- name: Install cross-compiler
91-
run: sudo apt-get update && sudo apt-get install -y gcc-riscv64-linux-gnu
103+
key: ${{ matrix.target }}
104+
- uses: taiki-e/install-action@cargo-zigbuild
92105
- name: Build
93-
env:
94-
CARGO_TARGET_RISCV64GC_UNKNOWN_LINUX_GNU_LINKER: riscv64-linux-gnu-gcc
95-
run: cargo build --release --target riscv64gc-unknown-linux-gnu
106+
run: cargo zigbuild --release --target ${{ matrix.target }}
96107
- uses: actions/upload-artifact@v7
97108
with:
98-
name: act-linux-riscv64
99-
path: target/riscv64gc-unknown-linux-gnu/release/act
109+
name: act-${{ matrix.name }}
110+
path: target/${{ matrix.target }}/release/act
100111

101112
fmt:
102113
name: Format

0 commit comments

Comments
 (0)