File tree Expand file tree Collapse file tree
.github/setup-rust-windows Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14,12 +14,17 @@ runs:
1414 - uses : dtolnay/rust-toolchain@1.91.1
1515 with :
1616 targets : i686-pc-windows-msvc,x86_64-pc-windows-msvc,aarch64-pc-windows-msvc
17+ # LIBCLANG_PATH must be set explicitly so the vcxproj uses the LLVM we
18+ # install here rather than the VS-bundled LLVM whose clang headers have
19+ # AVX intrinsic bugs. The values are hardcoded literals (no attacker-
20+ # controlled input), so the GITHUB_ENV writes are safe.
1721 - name : Install LLVM for bindgen
1822 if : inputs.arch != 'arm64'
1923 shell : cmd
2024 run : |
2125 choco install llvm --allow-downgrade --no-progress --version 21.1.0
2226 if not exist "C:\Program Files\LLVM\bin\libclang.dll" exit /b 1
27+ echo LIBCLANG_PATH=C:\Program Files\LLVM\bin>> "%GITHUB_ENV%"
2328 # Chocolatey's LLVM package only ships x64 binaries, which an ARM64-native
2429 # cargo process cannot load. Install the official ARM64 build directly.
2530 - name : Install LLVM for bindgen (ARM64)
3035 Invoke-WebRequest 'https://github.com/llvm/llvm-project/releases/download/llvmorg-21.1.0/LLVM-21.1.0-woa64.exe' -OutFile $installer
3136 Start-Process -Wait -FilePath $installer -ArgumentList '/S','/D=C:\Program Files\LLVM'
3237 if (!(Test-Path 'C:\Program Files\LLVM\bin\libclang.dll')) { exit 1 }
38+ echo "LIBCLANG_PATH=C:\Program Files\LLVM\bin" >> $env:GITHUB_ENV # zizmor: ignore[environment-file]
You can’t perform that action at this time.
0 commit comments