Skip to content

Commit ae22ed6

Browse files
authored
BLD: fix wheel builds on Windows (#834)
Ensure we're using MSVC; avoids finding a broken link.exe which again got added to a GHA runner image. Error message was: ``` ..\meson.build:1:0: ERROR: Found GNU link.exe instead of MSVC link.exe in C:\Program Files\Git\usr\bin\link.EXE. This link.exe is not a linker. You may need to reorder entries to your %PATH% variable to resolve this. ```
1 parent e5528c7 commit ae22ed6

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

pyproject.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,12 @@ homepage = "https://github.com/PyWavelets/pywt"
5555
source = "https://github.com/PyWavelets/pywt"
5656
documentation = "https://pywavelets.readthedocs.io/"
5757

58+
59+
[tool.cibuildwheel.windows]
60+
config-settings = {setup-args = ["--vsenv"]}
61+
before-build = "bash {project}/util/cibw_before_build_win.sh"
62+
63+
5864
[tool.ruff]
5965
line-length = 88
6066
target-version = 'py310'

util/cibw_before_build_win.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
set -xe
2+
3+
# Avoid this in GHA: "ERROR: Found GNU link.exe instead of MSVC link.exe"
4+
rm /c/Program\ Files/Git/usr/bin/link.EXE

0 commit comments

Comments
 (0)