1
- # This file is autogenerated by maturin v1.2.3
1
+ # This file is autogenerated by maturin v1.7.4
2
2
# To update, run
3
3
#
4
4
# maturin generate-ci github
9
9
push :
10
10
branches :
11
11
- main
12
- - dev
13
12
tags :
14
13
- ' *'
15
14
pull_request :
@@ -22,137 +21,130 @@ permissions:
22
21
23
22
jobs :
24
23
linux :
25
- runs-on : ubuntu-latest
26
- timeout-minutes : 60
24
+ runs-on : ${{ matrix.platform.runner }}
27
25
strategy :
28
26
matrix :
29
- # todo: enable aarch64, armv7, s390x, ppc64le
30
- target : [auto]
31
-
27
+ platform :
28
+ - runner : ubuntu-latest
29
+ target : x86_64
30
+ - runner : ubuntu-latest
31
+ target : x86
32
+ # - runner: ubuntu-latest
33
+ # target: aarch64
34
+ # - runner: ubuntu-latest
35
+ # target: armv7
36
+ # - runner: ubuntu-latest
37
+ # target: s390x
38
+ # - runner: ubuntu-latest
39
+ # target: ppc64le
32
40
steps :
33
41
- uses : actions/checkout@v4
42
+ - uses : actions/setup-python@v5
43
+ with :
44
+ python-version : 3.x
45
+ - name : Setup QEMU
46
+ if : ${{ matrix.platform.target != 'x86_64' && matrix.platform.target != 'x86' }}
47
+ uses : docker/setup-qemu-action@v1
48
+ - name : Build wheels
49
+ uses : PyO3/maturin-action@v1
50
+ with :
51
+ target : ${{ matrix.platform.target }}
52
+ args : --release --out dist --interpreter 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10 --features vendored
53
+ sccache : ' true'
54
+ manylinux : auto
55
+ - name : Upload wheels
56
+ uses : actions/upload-artifact@v4
34
57
with :
35
- submodules : recursive
58
+ name : wheels-linux-${{ matrix.platform.target }}
59
+ path : dist
36
60
61
+ musllinux :
62
+ runs-on : ${{ matrix.platform.runner }}
63
+ strategy :
64
+ matrix :
65
+ platform :
66
+ - runner : ubuntu-latest
67
+ target : x86_64
68
+ - runner : ubuntu-latest
69
+ target : x86
70
+ - runner : ubuntu-latest
71
+ target : aarch64
72
+ - runner : ubuntu-latest
73
+ target : armv7
74
+ steps :
75
+ - uses : actions/checkout@v4
37
76
- uses : actions/setup-python@v5
38
77
with :
39
- python-version : ' 3.10'
40
-
41
- # todo: enable for aarch64, armv7, s390x, ppc64le
42
- # - name: Set up QEMU
43
- # if: runner.os == 'Linux'
44
- # uses: docker/setup-qemu-action@v3
45
- # with:
46
- # platforms: all
47
-
48
- - name : Setup Rust in containers
49
- if : runner.os == 'Linux'
50
- run : |
51
- echo "CIBW_BEFORE_ALL=curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal" >> $GITHUB_ENV
52
- echo "CARGO_HOME=/usr/local/" >> $GITHUB_ENV
53
-
78
+ python-version : 3.x
79
+ - name : Setup QEMU
80
+ if : ${{ matrix.platform.target != 'x86_64' && matrix.platform.target != 'x86' }}
81
+ uses : docker/setup-qemu-action@v1
54
82
- name : Build wheels
55
- uses : pypa/cibuildwheel@v2.21.2
56
- env :
57
- CIBW_SKIP : ' *-musllinux_i686'
58
- CIBW_ARCHS_LINUX : ${{ matrix.target }}
59
- CIBW_ENVIRONMENT_PASS_LINUX : CARGO_HOME
60
- CIBW_BUILD_VERBOSITY : 1
61
- CIBW_BUILD_FRONTEND : " pip; args: --config-settings=build-args='--features=vendored'"
62
-
83
+ uses : PyO3/maturin-action@v1
84
+ with :
85
+ target : ${{ matrix.platform.target }}
86
+ args : --release --out dist --interpreter 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10 --features vendored
87
+ sccache : ' true'
88
+ manylinux : musllinux_1_2
63
89
- name : Upload wheels
64
90
uses : actions/upload-artifact@v4
65
91
with :
66
- name : wheels-linux -${{ matrix.target }}
67
- path : ./wheelhouse/*.whl
92
+ name : wheels-musllinux -${{ matrix.platform .target }}
93
+ path : dist
68
94
69
95
windows :
70
- runs-on : windows-latest
71
- timeout-minutes : 60
96
+ runs-on : ${{ matrix.platform.runner }}
72
97
strategy :
73
98
matrix :
74
- target : [x64]
99
+ platform :
100
+ - runner : windows-latest
101
+ target : x64
102
+ - runner : windows-latest
103
+ target : x86
75
104
steps :
76
- - name : Install dependencys
77
- uses : msys2/setup-msys2@v2
78
- with :
79
- update : true
80
- install : >-
81
- mingw-w64-x86_64-toolchain
82
- mingw-w64-x86_64-libjxl
83
-
84
- - name : Put MSYS2_MinGW64 on PATH
85
- # there is not yet an environment variable for this path from msys2/setup-msys2
86
- run : echo "${{ runner.temp }}/msys64/mingw64/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
87
-
88
105
- uses : actions/checkout@v4
89
- with :
90
- submodules : recursive
91
-
92
106
- uses : actions/setup-python@v5
93
107
with :
94
- python-version : ' >=3.9 <=3.13'
95
- architecture : ${{ matrix.target }}
96
-
108
+ python-version : 3.13
109
+ architecture : ${{ matrix.platform.target }}
97
110
- name : Build wheels
98
111
uses : PyO3/maturin-action@v1
99
- env :
100
- RUST_BACKTRACE : 1
101
112
with :
102
- rust-toolchain : stable-x86_64-pc-windows-gnu
103
- target : x86_64-pc-windows-gnu
104
- args : --release --out wheels --find-interpreter --features dynamic
113
+ target : ${{ matrix.platform.target }}
114
+ args : --release --out dist --interpreter 3.9 3.10 3.11 3.12 3.13 --features vendored
105
115
sccache : ' true'
106
-
107
- - name : Fix wheels with delvewheel
108
- run : |
109
- pip install delvewheel
110
- Get-ChildItem ${{ github.workspace }}/wheels/*win_amd64.whl | ForEach-Object -Process {delvewheel repair $PSItem -w dist}
111
-
112
116
- name : Upload wheels
113
117
uses : actions/upload-artifact@v4
114
118
with :
115
- name : wheels-windows-${{ matrix.target }}
119
+ name : wheels-windows-${{ matrix.platform. target }}
116
120
path : dist
117
121
118
122
macos :
119
123
runs-on : ${{ matrix.platform.runner }}
120
124
strategy :
121
125
matrix :
122
126
platform :
123
- - runner : macos-latest
127
+ - runner : macos-12
124
128
target : x86_64
125
129
- runner : macos-14
126
130
target : aarch64
127
131
steps :
128
- - uses : actions/checkout@v4
129
- with :
130
- submodules : recursive
131
-
132
- - uses : actions/setup-python@v5
133
- with :
134
- python-version : ' >=3.9 <=3.13'
135
-
136
132
- name : Check dependencys
137
133
run : |
138
134
brew install jpeg-xl
139
135
echo DEP_JXL_LIB=$(brew --prefix jpeg-xl)'/lib' >> $GITHUB_ENV
140
136
echo DEP_BROTLI_LIB=$(brew --prefix brotli)'/lib' >> $GITHUB_ENV
141
137
echo DEP_HWY_LIB=$(brew --prefix highway)'/lib' >> $GITHUB_ENV
142
-
138
+ - uses : actions/checkout@v4
139
+ - uses : actions/setup-python@v5
140
+ with :
141
+ python-version : 3.x
143
142
- name : Build wheels
144
143
uses : PyO3/maturin-action@v1
145
- env :
146
- RUST_BACKTRACE : 1
147
- MACOSX_DEPLOYMENT_TARGET : 12.7
148
- DEP_JXL_LIB : ${{ env.DEP_JXL_LIB }}
149
- DEP_BROTLI_LIB : ${{ env.DEP_BROTLI_LIB }}
150
- DEP_HWY_LIB : ${{ env.DEP_HWY_LIB }}
151
144
with :
152
145
target : ${{ matrix.platform.target }}
153
- args : --release --out dist --find- interpreter --features dynamic
146
+ args : --release --out dist --interpreter 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10 --features dynamic
154
147
sccache : ' true'
155
-
156
148
- name : Upload wheels
157
149
uses : actions/upload-artifact@v4
158
150
with :
@@ -161,17 +153,13 @@ jobs:
161
153
162
154
sdist :
163
155
runs-on : ubuntu-latest
164
- timeout-minutes : 60
165
156
steps :
166
157
- uses : actions/checkout@v4
167
- with :
168
- submodules : recursive
169
158
- name : Build sdist
170
159
uses : PyO3/maturin-action@v1
171
160
with :
172
161
command : sdist
173
162
args : --out dist
174
- rust-toolchain :
175
163
- name : Upload sdist
176
164
uses : actions/upload-artifact@v4
177
165
with :
@@ -181,15 +169,21 @@ jobs:
181
169
release :
182
170
name : Release
183
171
runs-on : ubuntu-latest
184
- timeout-minutes : 10
172
+ if : ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
173
+ needs : [linux, musllinux, windows, macos, sdist]
185
174
permissions :
175
+ # Use to sign the release artifacts
176
+ id-token : write
177
+ # Used to upload release artifacts
186
178
contents : write
187
- if : " startsWith(github.ref, 'refs/tags/') "
188
- needs : [linux, windows, macos, sdist]
179
+ # Used to generate artifact attestation
180
+ attestations : write
189
181
steps :
190
182
- uses : actions/download-artifact@v4
183
+ - name : Generate artifact attestation
184
+ uses : actions/attest-build-provenance@v1
191
185
with :
192
- pattern : wheels-*
186
+ subject-path : ' wheels-*/* '
193
187
- name : upload to github release
194
188
uses : softprops/action-gh-release@v2
195
189
with :
0 commit comments