-
Notifications
You must be signed in to change notification settings - Fork 0
65 lines (50 loc) · 1.66 KB
/
build_wheels_macos_arm64.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Wheel::MacOS::ARM
on:
pull_request:
push:
branches:
- master
release:
types: [published]
env:
ARCHS: 'arm64'
concurrency:
group: wheel_macos_arm64-${{ github.ref }}
cancel-in-progress: true
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-11]
arch: [arm64]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.9'
- name: Install cibuildwheel
run: python3.9 -m pip install cibuildwheel~=2.11.0
- name: Build wheels
env:
CIBW_ARCHS_MACOS: ${{matrix.arch}}
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-*"
CIBW_ENVIRONMENT: |
CMAKE_ARGS="-DCMAKE_CXX_COMPILER_TARGET=arm64-apple-macos11 -DCMAKE_SYSTEM_NAME=Darwin -DCMAKE_SYSTEM_PROCESSOR=ARM64 -DENABLE_OPENMP=OFF"
# MacOS specific build settings
CIBW_BEFORE_ALL_MACOS: |
brew update-reset
brew fetch --force --bottle-tag=arm64_big_sur mpfr
brew install $(brew --cache --bottle-tag=arm64_big_sur mpfr)
brew fetch --force --bottle-tag=arm64_big_sur gmp
brew install $(brew --cache --bottle-tag=arm64_big_sur gmp)
#brew install mpfr gmp
CIBW_BEFORE_BUILD: |
python -m pip install pybind11 cmake~=3.24.0
CIBW_BUILD_VERBOSITY: 1
run: python3.9 -m cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl