Skip to content

Build Wheels

Build Wheels #12

Workflow file for this run

name: Build Wheels
on:
workflow_dispatch:
pull_request:
push:
tags:
- '*'
release:
types:
- published
env:
CIBW_SKIP: pp* *-musllinux*
CIBW_TEST_COMMAND: python {project}/tests/test.py
jobs:
build_wheels:
name: Build wheels on ${{matrix.arch}} for ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
arch: [auto]
include:
- os: ubuntu-latest
arch: aarch64
steps:
- uses: actions/checkout@v4
- name: Set up QEMU
if: ${{ matrix.arch == 'aarch64' }}
uses: docker/setup-qemu-action@v1
- name: Build wheels
uses: pypa/cibuildwheel@v3.4.0
# to supply options, put them in 'env', like:
env:
CIBW_ARCHS_LINUX: ${{matrix.arch}}
CIBW_BEFORE_BUILD: pip install numpy pybind11 setuptools wheel
CIBW_ARCHS_MACOS: "x86_64 arm64"
CIBW_ARCHS: ${{ matrix.arch == 'aarch64' && 'aarch64' || 'auto64' }}
- name: Upload built wheels
uses: actions/upload-artifact@v4
with:
name: built-wheels-${{ matrix.os }}-${{ matrix.arch }}
path: ./wheelhouse/*.whl
if-no-files-found: warn