Skip to content

Commit

Permalink
Run CTest on Windows only for static build
Browse files Browse the repository at this point in the history
  • Loading branch information
thbeu committed Mar 9, 2024
1 parent 8b8ea5d commit 7b01427
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ jobs:
toolchain:
- linux-gcc
- macos-clang
- windows-msvc
- windows-msvc-shared
- windows-msvc-static

configuration:
- Release
Expand All @@ -59,7 +60,11 @@ jobs:
os: macos-latest
compiler: clang

- toolchain: windows-msvc
- toolchain: windows-msvc-shared
os: windows-latest
compiler: msvc

- toolchain: windows-msvc-static
os: windows-latest
compiler: msvc

Expand All @@ -69,8 +74,10 @@ jobs:

- name: Configure (${{ matrix.configuration }})
run: |
if [ "${{ matrix.compiler }}" == "msvc" ]; then
cmake -S . -Bbuild -DCMAKE_UNITY_BUILD=ON -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DBUILD_TESTING=ON -DBASH_EXECUTABLE="C:/Program Files/Git/bin/bash.exe"
if [ "${{ matrix.toolchain }}" == "windows-msvc-shared" ]; then
cmake -S . -Bbuild -DCMAKE_UNITY_BUILD=ON -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DBUILD_SHARED_LIBS=ON
elif [ "${{ matrix.toolchain }}" == "windows-msvc-static" ]; then
cmake -S . -Bbuild -DCMAKE_UNITY_BUILD=ON -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DBUILD_TESTING=ON -DBASH_EXECUTABLE="C:/Program Files/Git/bin/bash.exe" -DBUILD_SHARED_LIBS=OFF
else
cmake -S . -Bbuild -DCMAKE_BUILD_TYPE=${{ matrix.configuration }} -DCMAKE_UNITY_BUILD=ON -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DBUILD_TESTING=ON
fi
Expand Down

0 comments on commit 7b01427

Please sign in to comment.