From b42cf6953bd0f5093dd33df659dac5be012b53b3 Mon Sep 17 00:00:00 2001 From: Username404-59 Date: Wed, 15 Dec 2021 16:29:52 +0100 Subject: [PATCH] Add MSVC specific flags --- CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 018fdd1..65fa0a5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -81,6 +81,8 @@ elseif(${IS_CLANG}) set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -flto=full -fwhole-program-vtables") endif() set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -fstrict-vtable-pointers") +elseif(MSVC) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W3 /Zc:__cplusplus") endif() string(TOUPPER "${CMAKE_BUILD_TYPE}" UPPERCASE_BUILD_TYPE) if (UPPERCASE_BUILD_TYPE STREQUAL RELEASE)