diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 74cee2fd..5a99f740 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -64,7 +64,7 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", pypy-3.8, pypy-3.9, pypy-3.10] platform: [ - { os: "macos-latest", python-architecture: "x64", rust-target: "x86_64-apple-darwin" }, + { os: "macos-latest", python-architecture: "arm64", rust-target: "aarch64-apple-darwin" }, { os: "ubuntu-latest", python-architecture: "x64", rust-target: "x86_64-unknown-linux-gnu" }, { os: "windows-latest", python-architecture: "x64", rust-target: "x86_64-pc-windows-msvc" }, ] @@ -72,6 +72,16 @@ jobs: # Just test one x86 Windows Python for simplicity - python-version: 3.12 platform: { os: "windows-latest", python-architecture: "x86", rust-target: "i686-pc-windows-msvc" } + # Just test one x64 macOS Python for simplicity + - python-version: 3.12 + platform: { os: "macos-13", python-architecture: "x64", rust-target: "x86_64-apple-darwin" } + # Just test one x64 macOS Python for simplicity + exclude: + # macOS arm doesn't have Python builds before 3.10 + - python-version: 3.9 + platform: { os: "macos-latest", python-architecture: "arm64", rust-target: "aarch64-apple-darwin" } + - python-version: 3.8 + platform: { os: "macos-latest", python-architecture: "arm64", rust-target: "aarch64-apple-darwin" } steps: - uses: actions/checkout@v4 @@ -87,9 +97,9 @@ jobs: with: targets: ${{ matrix.platform.rust-target }} - - name: Install Rust aarch64-apple-darwin target + - name: Install Rust x86_64-apple-darwin target if: matrix.platform.os == 'macos-latest' - run: rustup target add aarch64-apple-darwin + run: rustup target add x86_64-apple-darwin - name: Install test dependencies run: pip install --upgrade nox @@ -143,10 +153,6 @@ jobs: - uses: dtolnay/rust-toolchain@stable - - name: Install Rust aarch64-apple-darwin target - if: matrix.os == 'macos-latest' - run: rustup target add aarch64-apple-darwin - - name: Build package run: pip install -e . @@ -307,7 +313,7 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: - targets: aarch64-apple-darwin + targets: aarch64-apple-darwin,x86_64-apple-darwin - uses: pypa/cibuildwheel@v2.17.0 env: CIBW_BUILD: cp39-*