@@ -148,26 +148,42 @@ jobs:
148
148
artifact_name : github-pages
149
149
150
150
build :
151
- name : Build wheels-${{ matrix.wheels }}-${{ matrix.target }} on ${{ matrix.runner }}
152
- runs-on : ${{ matrix.runner }}
151
+ # ref: https://github.com/pydantic/pydantic-core/blob/ba8eab4acba8ad04c45f27a58a5d001c8f212361/.github/workflows/ci.yml#L395-L499
152
+ env :
153
+ INTERPRETER : ${{ matrix.interpreter || '3.8 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10' }}
154
+ MANY_LINUX : ${{ contains('linux', matrix.os) && ( matrix.manylinux || 'auto' ) || null }}
155
+ OS : ${{ matrix.os || 'linux' }}
156
+
157
+ name : build ${{ matrix.os }} ${{ matrix.manylinux }} ${{ matrix.target }}
158
+ runs-on : ${{ contains('linux', matrix.os) && 'ubuntu' || matrix.os }}-latest
153
159
strategy :
160
+ fail-fast : false
154
161
matrix :
155
- runner : [ubuntu-latest]
156
- manylinux : [auto, musllinux_1_2]
157
- target : [x86_64, x86, aarch64, armv7, s390x, ppc64le]
162
+ os : [macos, linux, windows] # default: linux
163
+ manylinux : [auto, musllinux_1_1, musllinux_1_2] # default: 'auto' if linux, or 'null' otherwise
164
+ python-architecture : [x64] # default: 'x64'
165
+ target : [x86_64, aarch64]
158
166
167
+ # prettier-ignore
159
168
exclude :
160
- - { manylinux: musllinux_1_2, target: s390x }
161
- - { manylinux: musllinux_1_2, target: ppc64le }
169
+ - { os: macos, manylinux: musllinux_1_1 }
170
+ - { os: macos, manylinux: musllinux_1_2 }
171
+ - { os: windows, manylinux: musllinux_1_1 }
172
+ - { os: windows, manylinux: musllinux_1_2 }
162
173
163
174
# prettier-ignore
164
175
include :
165
- - { manylinux: auto, wheels: linux }
166
- - { manylinux: musllinux_1_2, wheels: musllinux }
167
- - { runner: macos-12, target: x86_64, wheels: macos }
168
- - { runner: macos-14, target: aarch64, wheels: macos }
169
- - { runner: windows-latest, target: x86, wheels: windows }
170
- - { runner: windows-latest, target: x64, wheels: windows }
176
+ # manylinux for various platforms
177
+ - { os: linux, target: i686 }
178
+ - { os: linux, target: armv7, interpreter: 3.8 3.9 3.10 3.11 3.12 3.13 }
179
+ - { os: linux, target: ppc64le, interpreter: 3.8 3.9 3.10 3.11 3.12 3.13 }
180
+ - { os: linux, target: s390x, interpreter: 3.8 3.9 3.10 3.11 3.12 3.13 }
181
+
182
+ # windows
183
+ - { os: windows, target: x86, interpreter: 3.8 3.9 3.10 3.11 3.12 3.13, python-architecture: x86 }
184
+ - { os: windows, target: i686, interpreter: 3.8 3.9 3.10 3.11 3.12 3.13, python-architecture: x86 }
185
+ - { os: windows, target: aarch64, interpreter: 3.11 3.12 3.13 }
186
+ - { os: windows, target: x64 }
171
187
172
188
steps :
173
189
- uses : actions/checkout@v4
@@ -177,7 +193,7 @@ jobs:
177
193
178
194
- uses : actions/setup-python@v5
179
195
with :
180
- architecture : ${{ matrix.runner == 'windows-latest' && matrix.target || null }}
196
+ architecture : ${{ matrix.python-architecture || 'x64' }}
181
197
python-version : 3.x
182
198
183
199
- uses : ./.github/actions/poetry
@@ -188,14 +204,15 @@ jobs:
188
204
189
205
- uses : PyO3/maturin-action@v1
190
206
with :
191
- target : ${{ matrix.target }}
192
- args : --release --out dist --find-interpreter
207
+ args : --release --out dist --interpreter ${{ env.INTERPRETER }}
208
+ manylinux : ${{ env.MANY_LINUX }}
209
+ rust-toolchain : stable
193
210
sccache : " true"
194
- manylinux : ${{ matrix.manylinux }}
211
+ target : ${{ matrix.target }}
195
212
196
213
- uses : actions/upload-artifact@v4
197
214
with :
198
- name : wheels- ${{ matrix.wheels }}- ${{ matrix.target }}
215
+ name : build ${{ env.OS }} ${{ env.MANY_LINUX }} ${{ matrix.target }}
199
216
path : dist
200
217
201
218
sdist :
@@ -209,7 +226,7 @@ jobs:
209
226
210
227
- uses : actions/upload-artifact@v4
211
228
with :
212
- name : wheels- sdist
229
+ name : sdist
213
230
path : dist
214
231
215
232
test-pypi :
0 commit comments