Fix arch selection and test command

pull/14/head
Andrew Cassidy 2 years ago
parent dac7f07db4
commit b80a6d2229

@ -45,19 +45,11 @@ jobs:
path: dist/*.tar.gz path: dist/*.tar.gz
build-wheels: build-wheels:
name: Build Wheels for ${{ matrix.os }}-${{ matrix.arch }} name: Build Wheels for ${{ matrix.os }}
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
strategy: strategy:
matrix: matrix:
os: [ macos-latest, windows-latest, ubuntu-latest ] os: [ macos-latest, windows-latest, ubuntu-latest ]
arch: [ x86_64 ]
include:
- arch: arm64
os: macos-latest
- arch: aarch64
os: ubuntu-latest
qemu: true
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
with: with:
@ -73,18 +65,19 @@ jobs:
- name: Install QEMU - name: Install QEMU
# install QEMU if building for arm linux # install QEMU if building for arm linux
uses: docker/setup-qemu-action@v1 uses: docker/setup-qemu-action@v1
if: matrix.qemu if: runner.os == 'Linux'
with: with:
platforms: arm64 platforms: arm64
- name: Build wheels - name: Build wheels
uses: pypa/cibuildwheel@v2.3.1 uses: pypa/cibuildwheel@v2.3.1
env: env:
# these options are all specific to running in the CI. other options are in pyproject.toml
MACOSX_DEPLOYMENT_TARGET: "10.15" MACOSX_DEPLOYMENT_TARGET: "10.15"
# CIBW_ARCHS_MACOS: ${{ matrix.arch }} CIBW_ARCHS_MACOS: "x86_64 universal2"
# CIBW_ARCHS_LINUX: ${{ matrix.arch }} CIBW_ARCHS_LINUX: "x86_64 aarch64"
# CIBW_ARCHS_WINDOWS: "auto64" CIBW_ARCHS_WINDOWS: "auto64"
CIBW_TEST_SKIP: "*-macosx_arm64" CIBW_TEST_SKIP: "*-macosx_arm64 *-macosx_universal2:arm64"
- name: Upload Wheels - name: Upload Wheels
uses: actions/upload-artifact@v2 uses: actions/upload-artifact@v2

@ -55,9 +55,9 @@ package-data = { '*' = ['py.typed', '*.pyi'] } # include stubs
package-dir = { '' = '.' } # without this line, C++ source files get included in the bdist package-dir = { '' = '.' } # without this line, C++ source files get included in the bdist
[tool.cibuildwheel] [tool.cibuildwheel]
build = "cp{37,38,39,310}-*" build = "cp{37,38,39,31*}-*"
skip = ["*cp37-musllinux*", "*musllinux_aarch64*"] skip = ["*cp37-musllinux*", "*musllinux_aarch64*", "cp{38,39,31*}-macosx_x86_64"]
test-command = "python -m unittest --verbose" test-command = 'python -m unittest discover "{project}/tests/" --verbose'
test-extras = ["tests"] test-extras = ["tests"]
manylinux-x86_64-image = "manylinux2014" manylinux-x86_64-image = "manylinux2014"
manylinux-aarch64-image = "manylinux2014" manylinux-aarch64-image = "manylinux2014"

Loading…
Cancel
Save