From 869843a21912dc8360d9e9d08b061e6da2746930 Mon Sep 17 00:00:00 2001 From: "Mark A. Tsuchida" Date: Fri, 20 Nov 2026 18:22:44 -0600 Subject: [PATCH] CI: fix Windows clang-cl build Use the clang-cl bundled with Visual Studio, not the standalone LLVM one. (Assisted by Claude Code; any errors are mine.) --- .github/workflows/ci.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c82d590..83e081a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -107,6 +107,17 @@ jobs: if: runner.os == 'Windows' uses: compnerd/gha-setup-vsdevenv@452f99effa381b81c025ccfbdccaca509bff1b29 # v7 + # The standalone LLVM on the runner image can lag behind what the MSVC + # STL requires; make sure we use VS's bundled clang-cl. + - name: Use VS-bundled clang-cl (Windows) + if: matrix.name == 'windows-clang-cl' + shell: pwsh + run: | + $bin = Join-Path $env:VCINSTALLDIR 'Tools\Llvm\x64\bin' + if (-not (Test-Path "$bin\clang-cl.exe")) { throw "clang-cl not found in $bin" } + $bin >> $env:GITHUB_PATH + & "$bin\clang-cl.exe" --version + # We only use Boost headers, but Meson's Boost detection fails unless at # least one compiled Boost library is present. So we also install (on # Windows, build) Boost.Random, which is not linked.