Skip to content

Build wheels for multiple platforms #45

Build wheels for multiple platforms

Build wheels for multiple platforms #45

Workflow file for this run

name: Build wheels for multiple platforms
on:
push:
branches: [main]
workflow_dispatch:
jobs:
build_wheels:
name: Build wheels for ${{ matrix.python }}-${{ matrix.platform.target }}_${{ matrix.platform.arch }} on ${{ matrix.platform.os }}
runs-on: ${{ matrix.platform.os }}
strategy:
matrix:
python: [cp39, cp310, cp311, cp312, cp313]
platform:
- os: ubuntu-24.04
target: manylinux
arch: x86_64
- os: ubuntu-24.04
target: musllinux
arch: x86_64
- os: ubuntu-24.04-arm
target: manylinux
arch: aarch64
- os: ubuntu-24.04-arm
target: musllinux
arch: aarch64
- os: macos-13
target: macosx
arch: x86_64
- os: macos-15
target: macosx
arch: arm64
steps:
- uses: actions/checkout@v4
with:
submodules: "true"
# Used to host cibuildwheel
- uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.23.1
- name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse
env:
CIBW_ARCHS: ${{ matrix.platform.arch }}
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.platform.target }}_${{ matrix.platform.arch }}
CIBW_BUILD_VERBOSITY: 1
- uses: actions/upload-artifact@v4
with:
name: pybedlite-${{ matrix.python-version }}-${{ matrix.buildplat[1] }}_${{ matrix.buildplat[2] }}
path: ./wheelhouse/*.whl
if-no-files-found: error