Enable MTT over parallel flag (#4998)

This commit is contained in:
tooomm 2024-02-10 21:30:43 +01:00 committed by GitHub
parent c8723ae935
commit 96caeaca72
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View file

@ -160,7 +160,13 @@ cmake .. "${flags[@]}"
echo "::endgroup::"
echo "::group::Build project"
cmake --build . "${buildflags[@]}"
if [[ $RUNNER_OS == Windows ]]; then
# 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
cmake --build . "${buildflags[@]}" -- -p:UseMultiToolTask=true
else
cmake --build . "${buildflags[@]}"
fi
echo "::endgroup::"
if [[ $USE_CCACHE ]]; then