Skip to content

Commit abaf71e

Browse files
committed
Another attempt to set MSVC compiler vars properly
1 parent 638be0b commit abaf71e

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

.github/setup-msvc-env.bat

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,7 @@ if "%VSINSTALLDIR%"=="" (
1818
)
1919

2020
call "%VSINSTALLDIR%\Common7\Tools\VsDevCmd.bat" -arch=amd64 -host_arch=amd64
21+
22+
rem Prevent inherited GCC/Clang hints from steering CMake to MinGW.
23+
set "CC="
24+
set "CXX="

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
call %GITHUB_WORKSPACE%\.github\setup-msvc-env.bat
7575
mkdir build
7676
cd build
77-
cmake -S .. -G Ninja -DBUILD_TESTS=ON -DBUILD_EXAMPLES=ON -DBUILD_TOOLS=ON -DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_ROOT}}/scripts/buildsystems/vcpkg.cmake -DUSE_CRYPTO=${{matrix.crypto}}
77+
cmake -S .. -G Ninja -DCMAKE_C_COMPILER=cl -DCMAKE_CXX_COMPILER=cl -DBUILD_TESTS=ON -DBUILD_EXAMPLES=ON -DBUILD_TOOLS=ON -DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_ROOT}}/scripts/buildsystems/vcpkg.cmake -DUSE_CRYPTO=${{matrix.crypto}}
7878
shell: cmd
7979

8080
- name: Build projects

0 commit comments

Comments
 (0)