-
Notifications
You must be signed in to change notification settings - Fork 10
85 lines (72 loc) · 2.15 KB
/
build_wheels.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
80
81
82
83
84
85
name: Build wheels
on: [push, pull_request]
jobs:
build_wheels:
name: ${{ matrix.os }}-${{ matrix.architecture }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
architecture: [x86_64]
include:
- os: ubuntu-latest
architecture: aarch64
- os: macos-latest
architecture: arm64
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install cibuildwheel
run: |
python -m pip install --upgrade pip
pip install cibuildwheel
- name: Build wheels with cibuildwheel
env:
CIBW_ARCHS_LINUX: ${{ matrix.architecture }}
CIBW_ARCHS_MACOS: ${{ matrix.architecture }}
CIBW_SKIP: "cp36-* cp37-*"
run: |
cibuildwheel --output-dir wheelhouse
- name: List wheels
run: |
ls wheelhouse
- name: Upload wheels as artifact
uses: actions/upload-artifact@v3
with:
name: python-wheels
path: wheelhouse/*.whl
build_wheels_windows:
name: ${{ matrix.os }}-${{ matrix.architecture }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest]
architecture: [x86, AMD64, ARM64]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python for Windows (Only on Windows)
if: matrix.os == 'windows-latest'
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install cibuildwheel
run: |
python -m pip install --upgrade pip
pip install cibuildwheel
- name: Build wheels with cibuildwheel
env:
CIBW_ARCHS_WINDOWS: ${{ matrix.architecture }}
CIBW_SKIP: "cp36-* cp37-*"
run: |
cibuildwheel --output-dir wheelhouse
- name: List wheels
run: |
ls wheelhouse
- name: Upload wheels as artifact
uses: actions/upload-artifact@v3
with:
name: python-wheels
path: wheelhouse/*.whl