diff --git a/cmake/BuildType.cmake b/cmake/BuildType.cmake index 03ebc34e..56ba5f09 100644 --- a/cmake/BuildType.cmake +++ b/cmake/BuildType.cmake @@ -10,8 +10,8 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) message(STATUS "Setting build type to '${default_build_type}' as none was specified.") set(CMAKE_BUILD_TYPE "${default_build_type}" CACHE STRING "Choose the type of build." FORCE) -endif() -# Set the possible values of build type for cmake-gui -set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" + # Set the possible values of build type for cmake-gui + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo") +endif() diff --git a/cmake/SfizzConfig.cmake b/cmake/SfizzConfig.cmake index 9f8bb462..8d0e2fe9 100644 --- a/cmake/SfizzConfig.cmake +++ b/cmake/SfizzConfig.cmake @@ -41,7 +41,7 @@ endif() # Process sources as UTF-8 if(MSVC) - add_compile_options("/utf-8") + add_compile_options($<$:/utf-8>) endif() # Define the math constants everywhere @@ -104,7 +104,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") endif() endif() elseif(CMAKE_CXX_COMPILER_ID MATCHES "MSVC") - add_compile_options(/Zc:__cplusplus) + add_compile_options($<$:/Zc:__cplusplus>) set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>") endif()