Skip to content

Commit 584f573

Browse files
committed
fix(ci): correct maturin targets and ring flags
1 parent 50dddca commit 584f573

1 file changed

Lines changed: 14 additions & 5 deletions

File tree

.github/workflows/python-wheels.yml

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,20 @@ jobs:
1616
include:
1717
- os: ubuntu-22.04
1818
platform: manylinux_x86_64
19+
target: x86_64-unknown-linux-gnu
1920
- os: ubuntu-22.04
2021
platform: manylinux_aarch64
22+
target: aarch64-unknown-linux-gnu
23+
cflags_aarch64: "-march=armv8-a -D__ARM_ARCH=8"
2124
- os: macos-13
2225
platform: macos_x86_64
26+
target: x86_64-apple-darwin
2327
- os: macos-14
2428
platform: macos_aarch64
29+
target: aarch64-apple-darwin
2530
- os: windows-2022
2631
platform: windows_x86_64
32+
target: x86_64-pc-windows-msvc
2733

2834
steps:
2935
- uses: actions/checkout@v4
@@ -33,15 +39,19 @@ jobs:
3339
with:
3440
python-version: "3.11"
3541

42+
- name: Set ring flags (linux aarch64)
43+
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' && startsWith(matrix.platform, 'manylinux') }}
44+
run: |
45+
echo "CFLAGS_aarch64_unknown_linux_gnu=${{ matrix.cflags_aarch64 }}" >> $GITHUB_ENV
46+
3647
- name: Build wheels
3748
uses: PyO3/maturin-action@v1
3849
with:
3950
command: build
40-
args: --release --out dist
51+
args: --release --out dist -F python-ffi
4152
maturin-version: "1.5.1"
4253
manylinux: auto
43-
target: ${{ matrix.platform }}
44-
features: python-ffi
54+
target: ${{ matrix.target }}
4555

4656
- name: Upload wheels
4757
uses: actions/upload-artifact@v4
@@ -64,9 +74,8 @@ jobs:
6474
uses: PyO3/maturin-action@v1
6575
with:
6676
command: sdist
67-
args: --out dist
77+
args: --out dist -F python-ffi
6878
maturin-version: "1.5.1"
69-
features: python-ffi
7079

7180
- name: Upload sdist
7281
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)