diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 302dfe9..ea5b37c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -27,9 +27,20 @@ jobs: exit 1 fi - Package-linux: + Package: if: github.repository == 'opendp/tumult-core' - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + strategy: + matrix: + include: + - name: linux-intel + os: ubuntu-latest + - name: macos-intel + os: macos-15-intel + - name: macos-arm + os: macos-latest + - name: linux-arm + os: ubuntu-24.04-arm needs: Check-Tag-Pattern steps: - name: Checkout repository @@ -40,50 +51,20 @@ jobs: - name: Upload wheel uses: actions/upload-artifact@v4 with: - name: linux-wheel + name: ${{ matrix.name }}-wheel path: dist/*.whl - name: Upload sdist + # Only upload the sdist once + if: ${{ strategy.job-index == 0 }} uses: actions/upload-artifact@v4 with: name: sdist path: dist/*.tar.gz - Package-macos-intel: - if: github.repository == 'opendp/tumult-core' - runs-on: macos-15-intel - needs: Check-Tag-Pattern - steps: - - name: Checkout repository - uses: actions/checkout@v4 - - name: Set up runner - uses: opendp/tumult-tools/actions/setup@eabe1054863f0916a0087ad180fd83719049c094 - - run: uv run --only-group scripting nox -s build - - name: Upload wheel - uses: actions/upload-artifact@v4 - with: - name: macos-intel-wheel - path: dist/*.whl - - Package-macos-arm: - if: github.repository == 'opendp/tumult-core' - runs-on: macos-latest - needs: Check-Tag-Pattern - steps: - - name: Checkout repository - uses: actions/checkout@v4 - - name: Set up runner - uses: opendp/tumult-tools/actions/setup@eabe1054863f0916a0087ad180fd83719049c094 - - run: uv run --only-group scripting nox -s build - - name: Upload wheel - uses: actions/upload-artifact@v4 - with: - name: macos-arm-wheel - path: dist/*.whl - Test-Slow: if: github.repository == 'opendp/tumult-core' runs-on: ubuntu-latest - needs: Package-linux + needs: Package steps: - name: Checkout code repository uses: actions/checkout@v4 @@ -92,14 +73,14 @@ jobs: - name: Download dist uses: actions/download-artifact@v4 with: - name: linux-wheel + name: linux-intel-wheel path: dist - run: uv run nox -s test-slow Benchmark: if: github.repository == 'opendp/tumult-core' runs-on: ubuntu-latest - needs: Package-linux + needs: Package steps: - name: Checkout code repository uses: actions/checkout@v4 @@ -108,7 +89,7 @@ jobs: - name: Download dist uses: actions/download-artifact@v4 with: - name: linux-wheel + name: linux-intel-wheel path: dist - run: uv run nox -t benchmark @@ -121,8 +102,17 @@ jobs: os: [ubuntu-latest] dependencies: [oldest, newest] python: ["3.10", "3.12"] + include: + # Set a wheel for all intel linux runs. + - os: ubuntu-latest + wheel: linux-intel-wheel + # Add an extra run to test arm linux. + - os: ubuntu-24.04-arm + dependencies: oldest + python: "3.10" + wheel: linux-arm-wheel runs-on: ${{ matrix.os }} - needs: Package-linux + needs: Package steps: - name: Checkout code repository uses: actions/checkout@v4 @@ -131,7 +121,7 @@ jobs: - name: Download dist uses: actions/download-artifact@v4 with: - name: linux-wheel + name: ${{ matrix.wheel }} path: dist - run: uv run nox -s "test_dependency_matrix(${{matrix.python}}-${{matrix.dependencies}})" env: diff --git a/ext/build.py b/ext/build.py index dab39ab..08f0150 100755 --- a/ext/build.py +++ b/ext/build.py @@ -11,7 +11,7 @@ build_command = ["bash", str(build_dir / "build.sh")] SUPPORTED_PLATFORMS = ["Linux", "Darwin"] -SUPPORTED_ARCHITECTURES = ["x86_64", "arm64"] +SUPPORTED_ARCHITECTURES = ["x86_64", "arm64", "aarch64"] def check_platform(): diff --git a/pyproject.toml b/pyproject.toml index 9803610..4ad4bcb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -170,7 +170,7 @@ fi""" environment = "MACOSX_DEPLOYMENT_TARGET='11.0'" [tool.cibuildwheel.linux] -archs = ["x86_64"] +archs = ["native"] ################################################################################