ci: skip MSBuild flags when using Ninja generator on Windows

This commit is contained in:
Bruno Alexandre Rosa 2026-03-02 20:55:01 -03:00
parent be046ce784
commit 2ec90e39de

View file

@ -227,7 +227,7 @@ if [[ $RUNNER_OS == macOS ]]; then
flags+=(-DCPACK_COMMAND_HDIUTIL="$hdiutil_script") flags+=(-DCPACK_COMMAND_HDIUTIL="$hdiutil_script")
fi fi
elif [[ $RUNNER_OS == Windows ]]; then elif [[ $RUNNER_OS == Windows ]] && [[ "$CMAKE_GENERATOR" != *Ninja* ]]; then
# Enable MTT, see https://devblogs.microsoft.com/cppblog/improved-parallelism-in-msbuild/ # Enable MTT, see https://devblogs.microsoft.com/cppblog/improved-parallelism-in-msbuild/
# and https://devblogs.microsoft.com/cppblog/cpp-build-throughput-investigation-and-tune-up/#multitooltask-mtt # and https://devblogs.microsoft.com/cppblog/cpp-build-throughput-investigation-and-tune-up/#multitooltask-mtt
buildflags+=(-- -p:UseMultiToolTask=true -p:EnableClServerMode=true) buildflags+=(-- -p:UseMultiToolTask=true -p:EnableClServerMode=true)