diff --git a/CMakeLists.txt b/CMakeLists.txt index e9f34ebf..751df1bf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -56,6 +56,16 @@ add_definitions( -D_CRT_SECURE_NO_WARNINGS ) +# Parallel make. +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP") + +# Optimization flags. +# http://msdn.microsoft.com/en-us/magazine/cc301698.aspx +set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /GL") +set(CMAKE_EXE_LINKER_FLAGS_RELEASE "${CMAKE_EXE_LINKER_FLAGS_RELEASE} /LTCG") +set(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /LTCG") +set(CMAKE_MODULE_LINKER_FLAGS_RELEASE "${CMAKE_MODULE_LINKER_FLAGS_RELEASE} /LTCG") + #----------------------------------------------------------------------------- # source files