From c3f5a235c71f53df6871b77fa19fd57d3fa51e21 Mon Sep 17 00:00:00 2001 From: Andrew Richards Date: Fri, 30 Aug 2024 11:47:52 +0100 Subject: [PATCH] Added multiprocessor compilation for MSVC in CMake. --- CMake/Include.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMake/Include.cmake b/CMake/Include.cmake index 220da6e0..fac24c85 100644 --- a/CMake/Include.cmake +++ b/CMake/Include.cmake @@ -57,8 +57,8 @@ if(PLATFORM_WINDOWS) set(DYNAMIC_LINK_SUFFIX "_MD") set(SIMUL_DYNAMIC_LIBS ON ) set(MSVC 1) - set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /O2 /Ob2 /DNDEBUG /Zi") - set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /Zi /Ob0 /Od /D_DEBUG /RTC1 /JMC") + set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /MP /O2 /Ob2 /DNDEBUG /Zi") + set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /MP /Zi /Ob0 /Od /D_DEBUG /RTC1 /JMC") #link_directories(${VULKAN_SDK_DIR}/Lib) #Specify C++ 17 in the CMAKE_CXX_FLAGS after project() and before add_subdirectory(). set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /std:c++${PLATFORM_CPP_VERSION} /Zc:__cplusplus /utf-8")