aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2019-09-18 09:01:46 -0700
committerChris Robinson <[email protected]>2019-09-18 09:01:46 -0700
commitab87e56b22a49e04ca614d71e8a848b0658327af (patch)
treed3e734e866175ea56b8b85ff4f10ee4bd7b808b7 /CMakeLists.txt
parentdffb874478643ae79a8236ae2ae8b08a36830d7a (diff)
Enable some more MSVC warnings
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 5 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 80ce4422..8da3d93c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -195,7 +195,11 @@ ENDIF()
IF(MSVC)
SET(CPP_DEFS ${CPP_DEFS} _CRT_SECURE_NO_WARNINGS NOMINMAX)
- SET(C_FLAGS ${C_FLAGS} /wd4065 /wd4200)
+ CHECK_CXX_COMPILER_FLAG(/permissive- HAVE_PERMISSIVE_SWITCH)
+ IF(HAVE_PERMISSIVE_SWITCH)
+ SET(C_FLAGS ${C_FLAGS} $<$<COMPILE_LANGUAGE:CXX>:/permissive->)
+ ENDIF()
+ SET(C_FLAGS ${C_FLAGS} /W4 /w14640 /wd4065 /wd4200)
IF(NOT DXSDK_DIR)
STRING(REGEX REPLACE "\\\\" "/" DXSDK_DIR "$ENV{DXSDK_DIR}")