1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-07-19 11:18:00 +02:00

cmake: enable parallel build on MSVC

This commit is contained in:
Anonymous Maarten 2018-08-29 15:51:09 +02:00
parent 32d3ab7508
commit 56bd77af4e
2 changed files with 5 additions and 1 deletions

View File

@ -21,6 +21,10 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
"_SCL_SECURE_NO_WARNINGS"
"_CRT_SECURE_NO_WARNINGS"
)
target_compile_options(rw_interface
INTERFACE
"/MP"
)
else()
message(FATAL_ERROR "Unknown compiler ID: '${CMAKE_CXX_COMPILER_ID}'")
endif()

View File

@ -16,7 +16,7 @@ set(FILESYSTEM_LIBRARY "BOOST" CACHE STRING "Which filesystem library to use")
set_property(CACHE FILESYSTEM_LIBRARY PROPERTY STRINGS "CXX17" "CXXTS" "BOOST")
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build, options are: Debug Release")
set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel")
endif()
option(CHECK_IWYU "Enable IncludeWhatYouUse (Analyze #includes in C and C++ source files)")