Skip to content

Commit 0090ee4

Browse files
committed
Fix Windows CI: Add pkg-config and set PKG_CONFIG_PATH for conda
Windows conda uses a different directory structure than Linux: - Linux: $CONDA_PREFIX/lib/pkgconfig - Windows: $CONDA_PREFIX/Library/lib/pkgconfig Also install pkg-config from conda to avoid conflicts with Strawberry Perl's pkg-config.BAT
1 parent c37fd04 commit 0090ee4

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.github/workflows/test-matrix.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
if: runner.os == 'Windows'
3939
shell: bash -l {0}
4040
run: |
41-
conda install -y meson ninja numpy pytest openblas clang llvm-tools lld
41+
conda install -y meson ninja numpy pytest openblas clang llvm-tools lld pkg-config
4242
4343
- name: Build SLICUTLET (Linux/macOS)
4444
if: runner.os != 'Windows'
@@ -56,6 +56,8 @@ jobs:
5656
# Force clang to target MinGW-w64 instead of MSVC for C11 complex support
5757
export CC="clang --target=x86_64-w64-mingw32"
5858
export CXX="clang++ --target=x86_64-w64-mingw32"
59+
# Windows conda uses Library/lib/pkgconfig not lib/pkgconfig
60+
export PKG_CONFIG_PATH="$CONDA_PREFIX/Library/lib/pkgconfig:$PKG_CONFIG_PATH"
5961
meson setup build -Dpython=true
6062
meson install -C build --destdir="${PWD}/build-install"
6163

.github/workflows/test-windows.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,17 @@ jobs:
2828
openblas \
2929
clang \
3030
llvm-tools \
31-
lld
31+
lld \
32+
pkg-config
3233
3334
- name: Build SLICUTLET (using LLVM/clang with MinGW target)
3435
shell: bash -l {0}
3536
run: |
3637
# Force clang to target MinGW-w64 instead of MSVC for C11 complex support
3738
export CC="clang --target=x86_64-w64-mingw32"
3839
export CXX="clang++ --target=x86_64-w64-mingw32"
40+
# Ensure pkg-config can find conda packages
41+
export PKG_CONFIG_PATH="$CONDA_PREFIX/Library/lib/pkgconfig:$PKG_CONFIG_PATH"
3942
meson setup build -Dpython=true
4043
meson install -C build --destdir="${PWD}/build-install"
4144

0 commit comments

Comments
 (0)