-
Notifications
You must be signed in to change notification settings - Fork 80
/
.cirrus.yml
81 lines (70 loc) · 2.8 KB
/
.cirrus.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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# this build script is adapted from scipy
build_and_store_wheels: &BUILD_AND_STORE_WHEELS
install_cibuildwheel_script:
- python -m pip install cibuildwheel==2.11.4
cibuildwheel_script:
- cibuildwheel
- tools/wheels/release-wheels.sh
env:
GITHUB_TOKEN: ENCRYPTED[442a58e6ea575035b2894e799eca4d2639c539e264a4a7e54f03952460c10f8690c388009aebd9eeee26b1d62726d5bb]
TWINE_USERNAME: __token__
TWINE_PASSWORD: ENCRYPTED[e0e8298d5f80b1badbcf84fbead7557701c9365b82eae0326df13e82659a8003f52c09a6b23142479a5c36ab8c1f2b4e]
wheels_artifacts:
path: "wheelhouse/*"
######################################################################
# Build linux_aarch64 natively
######################################################################
cirrus_wheels_linux_aarch64_task:
compute_engine_instance:
image_project: cirrus-images
image: family/docker-builder-arm64
architecture: arm64
platform: linux
cpu: 4
memory: 8G
matrix:
- env:
CIBW_BUILD: cp38-* cp39-*
- env:
CIBW_BUILD: cp310-* cp311-*
build_script: |
apt install -y python3-venv python-is-python3
which python
echo $CIRRUS_CHANGE_MESSAGE
# needed for submodules
git submodule update --init
<<: *BUILD_AND_STORE_WHEELS
######################################################################
# Build macosx_arm64 natively
######################################################################
cirrus_wheels_macos_arm64_task:
macos_instance:
image: ghcr.io/cirruslabs/macos-monterey-xcode:13.3.1
matrix:
- env:
CIBW_BUILD: cp38-*
CIBW_BEFORE_ALL: bash tools/wheels/cibw_before_all_cp38_macosx_arm64.sh
- env:
CIBW_BUILD: cp39-* cp310-* cp311-*
env:
PATH: /opt/homebrew/opt/python@3.10/bin:$PATH
CIBW_ENVIRONMENT: MACOSX_DEPLOYMENT_TARGET=12.0 _PYTHON_HOST_PLATFORM="macosx-12.0-arm64"
PKG_CONFIG_PATH: /opt/arm64-builds/lib/pkgconfig
# assumes that the cmake config is in /usr/local/lib/cmake
CMAKE_PREFIX_PATH: /opt/arm64-builds/
REPAIR_PATH: /usr/local/gfortran/lib:/opt/arm64-builds/lib
CIBW_REPAIR_WHEEL_COMMAND_MACOS: >
DYLD_LIBRARY_PATH=/usr/local/gfortran/lib:/opt/arm64-builds/lib delocate-listdeps {wheel} &&
DYLD_LIBRARY_PATH=/usr/local/gfortran/lib:/opt/arm64-builds/lib delocate-wheel --require-archs {delocate_archs} -w {dest_dir} {wheel}
CIBW_TEST_COMMAND: "cd {project}/examples; make clean; make test"
install_pre_requirements_script:
- brew install python@3.10
- ln -s python3 /opt/homebrew/opt/python@3.10/bin/python
build_script:
- which python
# needed for submodules
- git submodule update --init
- uname -m
- python -c "import platform;print(platform.python_version());print(platform.system());print(platform.machine())"
- clang --version
<<: *BUILD_AND_STORE_WHEELS