|
7 | 7 |
|
8 | 8 | jobs: |
9 | 9 | build_wheels: |
10 | | - name: Build wheels on ${{ matrix.os }} for ${{ matrix.arch }} |
| 10 | + name: Build wheels on ${{ matrix.os }} |
11 | 11 | runs-on: ${{ matrix.os }} |
12 | 12 | strategy: |
13 | 13 | fail-fast: false |
14 | 14 | matrix: |
15 | | - os: [ubuntu-20.04, windows-2019, macos-13, macos-14] |
16 | | - arch: [native] |
| 15 | + os: [ubuntu-latest, ubuntu-24.04-arm, macos-13, macos-latest] |
| 16 | + vcpkg: [none] |
17 | 17 | include: |
18 | | - - os: ubuntu-20.04 |
19 | | - arch: aarch64 |
| 18 | + - os: windows-latest |
| 19 | + vcpkg: 'C:/vcpkg/installed/x64-windows' |
| 20 | + - os: windows-11-arm |
| 21 | + vcpkg: 'C:/vcpkg/installed/arm64-windows' |
20 | 22 |
|
21 | 23 | steps: |
22 | 24 | - uses: actions/checkout@v4 |
23 | 25 |
|
24 | | - - uses: actions/checkout@v4 |
25 | | - with: |
26 | | - repository: pybind/pybind11 |
27 | | - ref: v2.11.1 |
28 | | - path: contrib/pybind11 |
29 | | - |
30 | | - - uses: actions/checkout@v4 |
31 | | - with: |
32 | | - repository: mapbox/protozero |
33 | | - ref: v1.7.1 |
34 | | - path: contrib/protozero |
35 | | - |
36 | | - - uses: actions/checkout@v4 |
| 26 | + - uses: actions/setup-python@v5 |
37 | 27 | with: |
38 | | - repository: osmcode/libosmium |
39 | | - ref: v2.20.0 |
40 | | - path: contrib/libosmium |
| 28 | + python-version: '3.13' |
41 | 29 |
|
42 | | - - name: Set up QEMU |
43 | | - uses: docker/setup-qemu-action@v3 |
44 | | - if: ${{ matrix.arch == 'aarch64' }} |
| 30 | + - name: Install requirements |
| 31 | + run: python -m pip install cibuildwheel build |
45 | 32 |
|
46 | | - - uses: actions/setup-python@v5 |
47 | | - with: |
48 | | - python-version: '3.8' |
| 33 | + - name: Get dependencies via sdist |
| 34 | + run: python -m build --sdist |
49 | 35 |
|
50 | 36 | - name: Build wheels |
51 | | - |
| 37 | + run: | |
| 38 | + python -m cibuildwheel --output-dir wheelhouse |
| 39 | + shell: bash |
52 | 40 | env: |
53 | | - CIBW_ARCHS: ${{ matrix.arch }} |
54 | | - CIBW_SKIP: "pp* *musllinux* cp37-macosx_* {cp37,cp38}-*linux_aarch64" |
55 | | - CIBW_TEST_REQUIRES: pytest pytest-httpserver shapely |
56 | | - CIBW_TEST_REQUIRES_LINUX: urllib3<2.0 pytest pytest-httpserver shapely |
| 41 | + CIBW_ENABLE: cpython-freethreading |
| 42 | + CIBW_ARCHS: "native" |
| 43 | + CIBW_SKIP: "*musllinux*" |
| 44 | + CIBW_TEST_REQUIRES: pytest pytest-httpserver |
57 | 45 | CIBW_TEST_COMMAND: pytest {project}/test |
58 | 46 | CIBW_BUILD_FRONTEND: build |
59 | 47 | CIBW_BEFORE_BUILD_LINUX: yum install -y expat-devel boost-devel zlib-devel bzip2-devel lz4-devel |
60 | 48 | CIBW_BEFORE_BUILD_MACOS: brew install boost |
61 | | - CIBW_BEFORE_BUILD_WINDOWS: vcpkg install bzip2:x64-windows expat:x64-windows zlib:x64-windows boost-variant:x64-windows boost-iterator:x64-windows lz4:x86-windows |
| 49 | + CIBW_ENVIRONMENT_MACOS: MACOSX_DEPLOYMENT_TARGET=11.0 SKBUILD_CMAKE_ARGS=-DWITH_LZ4=OFF |
| 50 | + CIBW_BEFORE_BUILD_WINDOWS: vcpkg install bzip2 expat zlib boost-variant boost-iterator lz4 |
62 | 51 | CIBW_ENVIRONMENT_WINDOWS: 'CMAKE_TOOLCHAIN_FILE="C:/vcpkg/scripts/buildsystems/vcpkg.cmake"' |
63 | | - CIBW_ENVIRONMENT_MACOS: CMAKE_WITH_LZ4=OFF MACOSX_DEPLOYMENT_TARGET=11.0 |
| 52 | + CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: 'pipx run delvewheel repair --add-path ${{ matrix.vcpkg }}/bin/ --add-path ${{ matrix.vcpkg }}/debug/bin -w {dest_dir} {wheel}' |
64 | 53 |
|
65 | 54 | - uses: actions/upload-artifact@v4 |
66 | 55 | with: |
67 | | - name: pyosmium-wheels-${{ matrix.os }}-${{ matrix.arch }} |
| 56 | + name: pyosmium-wheels-${{ matrix.os }} |
68 | 57 | path: ./wheelhouse/*.whl |
0 commit comments