38 lines
1.2 KiB
YAML
38 lines
1.2 KiB
YAML
name: Build
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build_wheels:
|
|
name: Build wheels on ${{ matrix.os }}
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
# macos-15-intel is an intel runner, macos-latest is apple silicon
|
|
os: [ubuntu-latest, ubuntu-24.04-arm, windows-latest, macos-15-intel, macos-latest]
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Set up QEMU
|
|
if: runner.os == 'Linux' && runner.arch == 'X64'
|
|
uses: docker/setup-qemu-action@v3
|
|
with:
|
|
platforms: all
|
|
|
|
- name: Build wheels
|
|
uses: pypa/cibuildwheel@v2.23.4
|
|
env:
|
|
# configure cibuildwheel on Linux to build native archs ('auto'),
|
|
# and to split the remaining architectures between the x86_64 and
|
|
# ARM runners
|
|
# armv7l can be built without QEMU on GitHub Actions ARM runners but that's
|
|
# not the case on all ARM64 hardware hence 'auto armv7l' for native archs
|
|
# on the GHA ARM64 runner
|
|
CIBW_ARCHS_LINUX: ${{ runner.arch == 'X64' && 'auto ppc64le s390x' || 'auto armv7l' }}
|
|
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
|
|
path: ./wheelhouse/*.whl
|