Skip to content

Commit 0606e70

Browse files
committed
Fix env var names in buildwheel.yml
1 parent a5d1f41 commit 0606e70

File tree

1 file changed

+21
-4
lines changed

1 file changed

+21
-4
lines changed

.github/workflows/buildwheel.yml

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,29 @@ jobs:
4141
- run: echo "PKG_CONFIG_PATH=${{ github.workspace }}/.local/lib/pkgconfig" >> $env:GITHUB_ENV
4242
if: ${{ startsWith( matrix.os , 'windows' ) }}
4343

44-
- name: Build wheels
44+
# We need to set these environment variables here rather than
45+
# pyproject.toml so we can use differnt values for different
46+
# architectures. For non-Windows this is just done with $(uname -m)
47+
# don't know what that would do in msys2 on Windows when cibuildwheel
48+
# parses it.
49+
50+
- name: Build wheels for windows-2022
51+
uses: pypa/cibuildwheel@63fd63b352a9a8bdcc24791c9dbee952ee9a8abc # v3.3.0
52+
if: ${{ matrix.os == 'windows-2022' }}
53+
env:
54+
CIBW_BEFORE_ALL_WINDOWS: msys2 -c bin/cibw_before_all_windows_amd64.sh
55+
56+
- name: Build wheels for windows-11-arm
4557
uses: pypa/cibuildwheel@63fd63b352a9a8bdcc24791c9dbee952ee9a8abc # v3.3.0
58+
if: ${{ matrix.os == 'windows-11-arm' }}
4659
env:
47-
# override setting in pyproject.toml to use msys2 instead of msys64 bash
48-
CIBW_BEFORE_ALL_WINDOWS_AMD64: msys2 -c bin/cibw_before_all_windows_amd64.sh
49-
CIBW_BEFORE_ALL_WINDOWS_ARM64: msys2 -c bin/cibw_before_all_windows_arm64.sh
60+
CIBW_BEFORE_ALL_WINDOWS: msys2 -c bin/cibw_before_all_windows_arm64.sh
61+
62+
# After all the Windows-specific steps above this is what actually
63+
# #builds the wheels for every other OS:
64+
65+
- name: Build wheels for any other OS
66+
uses: pypa/cibuildwheel@63fd63b352a9a8bdcc24791c9dbee952ee9a8abc # v3.3.0
5067

5168
- uses: actions/upload-artifact@v5
5269
with:

0 commit comments

Comments
 (0)