Skip to content

Commit b5d7b00

Browse files
committed
ci: add riscv64 manylinux wheels with native RISE runners
Add riscv64 matrix entries (cp39-cp314t) following the s390x pattern, with native RISE riscv64 runners instead of QEMU emulation. Based on the work by @justeph in python-cffi#227, with the addition of: - Native runner support (ubuntu-24.04-riscv) for faster builds - Skip QEMU setup for riscv64 (not needed on native hardware) Verified on native riscv64 hardware (BananaPi F3, SpacemiT K1). Native RISE runners provided by the RISE project. Signed-off-by: Bruno Verachten <gounthar@gmail.com>
1 parent 2079ca7 commit b5d7b00

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

.github/workflows/ci.yaml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,9 +139,18 @@ jobs:
139139
- { spec: cp314-manylinux_s390x, arch: s390x, omit: ${{ env.skip_slow_jobs }} }
140140
- { spec: cp314t-manylinux_s390x, arch: s390x, omit: ${{ env.skip_slow_jobs }} }
141141
142+
# riscv64 manylinux
143+
- { spec: cp39-manylinux_riscv64, arch: riscv64, test_args: '{package}/src/c', omit: ${{ env.skip_slow_jobs }} }
144+
- { spec: cp310-manylinux_riscv64, arch: riscv64, test_args: '{package}/src/c', omit: ${{ env.skip_slow_jobs || env.skip_ci_redundant_jobs }} }
145+
- { spec: cp311-manylinux_riscv64, arch: riscv64, test_args: '{package}/src/c', omit: ${{ env.skip_slow_jobs || env.skip_ci_redundant_jobs }} }
146+
- { spec: cp312-manylinux_riscv64, arch: riscv64, test_args: '{package}/src/c', omit: ${{ env.skip_slow_jobs || env.skip_ci_redundant_jobs }} }
147+
- { spec: cp313-manylinux_riscv64, arch: riscv64, test_args: '{package}/src/c', omit: ${{ env.skip_slow_jobs || env.skip_ci_redundant_jobs }} }
148+
- { spec: cp314-manylinux_riscv64, arch: riscv64, omit: ${{ env.skip_slow_jobs }} }
149+
- { spec: cp314t-manylinux_riscv64, arch: riscv64, omit: ${{ env.skip_slow_jobs }} }
150+
142151
linux:
143152
needs: [python_sdist, make_linux_matrix]
144-
runs-on: ${{ (matrix.arch == 'aarch64') && 'ubuntu-24.04-arm' || 'ubuntu-24.04' }}
153+
runs-on: ${{ (matrix.arch == 'aarch64') && 'ubuntu-24.04-arm' || (matrix.arch == 'riscv64') && 'ubuntu-24.04-riscv' || 'ubuntu-24.04' }}
145154
strategy:
146155
fail-fast: false
147156
matrix: ${{ fromJSON(needs.make_linux_matrix.outputs.matrix_json) }}
@@ -155,7 +164,7 @@ jobs:
155164

156165
- name: configure docker foreign arch support
157166
uses: docker/setup-qemu-action@v3
158-
if: matrix.arch != 'x86_64' && matrix.arch != 'i686' && matrix.arch != 'aarch64'
167+
if: matrix.arch != 'x86_64' && matrix.arch != 'i686' && matrix.arch != 'aarch64' && matrix.arch != 'riscv64'
159168

160169
- name: build/test wheels
161170
id: build
@@ -179,6 +188,7 @@ jobs:
179188
CIBW_MANYLINUX_AARCH64_IMAGE: ${{ matrix.manylinux_img || 'manylinux2014' }}
180189
CIBW_MANYLINUX_PPC64LE_IMAGE: ${{ matrix.manylinux_img || 'manylinux2014' }}
181190
CIBW_MANYLINUX_S390X_IMAGE: ${{ matrix.manylinux_img || 'manylinux2014' }}
191+
CIBW_MANYLINUX_RISCV64_IMAGE: ${{ matrix.manylinux_img || 'manylinux_2_39' }}
182192
CIBW_MUSLLINUX_X86_64_IMAGE: ${{ matrix.musllinux_img || 'musllinux_1_2' }}
183193
CIBW_MUSLLINUX_I686_IMAGE: ${{ matrix.musllinux_img || 'musllinux_1_2' }}
184194
CIBW_MUSLLINUX_AARCH64_IMAGE: ${{ matrix.musllinux_img || 'musllinux_1_2' }}

0 commit comments

Comments
 (0)