Skip to content

Commit fb3c6e2

Browse files
authored
mac arm64 build (#338)
1 parent 1629805 commit fb3c6e2

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

.github/workflows/build.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,58 @@ jobs:
9999
name: dist
100100
path: target/wheels/*
101101

102+
build-macos-aarch64:
103+
needs: [generate-license]
104+
name: Mac arm64
105+
runs-on: macos-latest
106+
strategy:
107+
fail-fast: false
108+
matrix:
109+
python-version: ["3.10"]
110+
steps:
111+
- uses: actions/checkout@v3
112+
113+
- uses: actions/setup-python@v4
114+
with:
115+
python-version: ${{ matrix.python-version }}
116+
117+
- uses: actions-rs/toolchain@v1
118+
with:
119+
toolchain: stable
120+
121+
- name: Set up Rust targets
122+
run: rustup target add aarch64-apple-darwin
123+
124+
- name: Upgrade pip
125+
run: python -m pip install --upgrade pip
126+
127+
- name: Install maturin
128+
run: pip install maturin==0.14.2
129+
130+
- run: rm LICENSE.txt
131+
- name: Download LICENSE.txt
132+
uses: actions/download-artifact@v3
133+
with:
134+
name: python-wheel-license
135+
path: .
136+
137+
- name: Install Protoc
138+
uses: arduino/setup-protoc@v1
139+
with:
140+
version: '3.x'
141+
repo-token: ${{ secrets.GITHUB_TOKEN }}
142+
143+
- name: Build Python package
144+
run: maturin build --release --strip --target aarch64-apple-darwin
145+
- name: List Mac wheels
146+
run: find target/wheels/
147+
148+
- name: Archive wheels
149+
uses: actions/upload-artifact@v3
150+
with:
151+
name: dist
152+
path: target/wheels/*
153+
102154
build-manylinux:
103155
needs: [generate-license]
104156
name: Manylinux

0 commit comments

Comments
 (0)