From 71ffb2eabce29d29bbbb55bd4274f37eb23ca671 Mon Sep 17 00:00:00 2001 From: Charlie Marsh Date: Thu, 25 Apr 2024 19:13:27 -0400 Subject: [PATCH] Build a separate ARM wheel for macOS (#3268) ## Summary See: https://github.com/astral-sh/ruff/pull/11149 --- .github/workflows/build-binaries.yml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-binaries.yml b/.github/workflows/build-binaries.yml index 6915d5f74..55dcd80ad 100644 --- a/.github/workflows/build-binaries.yml +++ b/.github/workflows/build-binaries.yml @@ -102,9 +102,9 @@ jobs: *.tar.gz *.sha256 - macos-universal: + macos-aarch64: if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }} - runs-on: macos-12 + runs-on: macos-14 steps: - uses: actions/checkout@v4 with: @@ -112,16 +112,17 @@ jobs: - uses: actions/setup-python@v5 with: python-version: ${{ env.PYTHON_VERSION }} - architecture: x64 + architecture: arm64 - name: "Prep README.md" run: python scripts/transform_readme.py --target pypi - - name: "Build wheels - universal2" + - name: "Build wheels - aarch64" uses: PyO3/maturin-action@v1 with: - args: --release --locked --target universal2-apple-darwin --out dist --features self-update - - name: "Test wheel - universal2" + target: aarch64 + args: --release --locked --out dist --features self-update + - name: "Test wheel - aarch64" run: | - pip install dist/${{ env.PACKAGE_NAME }}-*universal2.whl --force-reinstall + pip install dist/${{ env.PACKAGE_NAME }}-*.whl --force-reinstall ${{ env.MODULE_NAME }} --help python -m ${{ env.MODULE_NAME }} --help - name: "Upload wheels"