From d054e238f8edbe84d59188eb15e5b366589646a8 Mon Sep 17 00:00:00 2001 From: Marc-Antoine Schmidt Date: Thu, 5 Dec 2024 15:56:02 -0500 Subject: [PATCH] Update macOS runner (#424) * update runner to macos13 * CONDA -> MAMBA_ROOT_PREFIX * update dollowing refs * test out native builds on macos * simplify build --- .github/workflows/build-wheels.yml | 6 +----- build_tools/prepare_macos_wheel.sh | 11 ----------- pyproject.toml | 8 ++++---- 3 files changed, 5 insertions(+), 20 deletions(-) delete mode 100644 build_tools/prepare_macos_wheel.sh diff --git a/.github/workflows/build-wheels.yml b/.github/workflows/build-wheels.yml index cf1603c1..57e6be2d 100644 --- a/.github/workflows/build-wheels.yml +++ b/.github/workflows/build-wheels.yml @@ -12,7 +12,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04, windows-2019, macos-12] + os: [ubuntu-20.04, windows-2019, macos-13, macos-14] steps: - uses: actions/checkout@v4 @@ -28,15 +28,11 @@ jobs: uses: pypa/cibuildwheel@v2.22.0 env: CIBW_ARCHS_LINUX: auto - CIBW_ARCHS_MACOS: x86_64 arm64 - CIBW_TEST_SKIP: '*-macosx_arm64' - name: Build wheels (release) if: github.event_name == 'release' && github.event.action == 'published' uses: pypa/cibuildwheel@v2.22.0 env: CIBW_ARCHS_LINUX: x86_64 aarch64 - CIBW_ARCHS_MACOS: x86_64 arm64 - CIBW_TEST_SKIP: '*-macosx_arm64' - uses: actions/upload-artifact@v4 with: name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} diff --git a/build_tools/prepare_macos_wheel.sh b/build_tools/prepare_macos_wheel.sh deleted file mode 100644 index 9b3fab1a..00000000 --- a/build_tools/prepare_macos_wheel.sh +++ /dev/null @@ -1,11 +0,0 @@ -#!/bin/bash - -set -exuo pipefail - -if [[ "${ARCHFLAGS:-}" == *arm64 ]]; then - export CONDA_SUBDIR="osx-arm64" -else - export CONDA_SUBDIR="osx-64" -fi - -/Users/runner/micromamba-bin/micromamba create -y -p $CONDA/envs/build -c conda-forge jemalloc-local "xsimd<11|>12.1" llvm-openmp diff --git a/pyproject.toml b/pyproject.toml index 4f34cad3..5cb17cef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,13 +57,13 @@ test-command = "pytest {package}/tests/test_matrices.py" [tool.cibuildwheel.macos] before-build = [ - "bash build_tools/prepare_macos_wheel.sh", + "/Users/runner/micromamba-bin/micromamba create -y -p $MAMBA_ROOT_PREFIX/envs/build -c conda-forge jemalloc-local \"xsimd<11|>12.1\" llvm-openmp", ] [tool.cibuildwheel.macos.environment] -LDFLAGS="-Wl,-rpath,$CONDA/envs/build/lib -L$CONDA/envs/build/lib -headerpad_max_install_names" -CFLAGS="-I$CONDA/envs/build/include" -CXXFLAGS="-I$CONDA/envs/build/include" +LDFLAGS="-Wl,-rpath,$MAMBA_ROOT_PREFIX/envs/build/lib -L$MAMBA_ROOT_PREFIX/envs/build/lib -headerpad_max_install_names" +CFLAGS="-I$MAMBA_ROOT_PREFIX/envs/build/include" +CXXFLAGS="-I$MAMBA_ROOT_PREFIX/envs/build/include" CXX="/usr/bin/clang++" CC="/usr/bin/clang" JE_INSTALL_SUFFIX="local"