summaryrefslogtreecommitdiffstats
path: root/cmake/scripts/windows/CFlagOverrides.cmake
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--cmake/scripts/windows/CFlagOverrides.cmake10
1 files changed, 10 insertions, 0 deletions
diff --git a/cmake/scripts/windows/CFlagOverrides.cmake b/cmake/scripts/windows/CFlagOverrides.cmake
new file mode 100644
index 0000000..cd96689
--- /dev/null
+++ b/cmake/scripts/windows/CFlagOverrides.cmake
@@ -0,0 +1,10 @@
+if(MSVC)
+ if(DEFINED ENV{MAXTHREADS})
+ set(MP_FLAG "/MP$ENV{MAXTHREADS}")
+ else()
+ set(MP_FLAG "/MP")
+ endif()
+ set(CMAKE_C_FLAGS "/D_UNICODE /DUNICODE /DRPC_USE_NATIVE_WCHAR ${MP_FLAG} /DWIN32 /D_WINDOWS /W3 /Zi /arch:SSE2")
+ set(CMAKE_C_FLAGS_DEBUG "/D_DEBUG /MDd /Ob0 /Od /RTC1 /D_ITERATOR_DEBUG_LEVEL=0")
+ set(CMAKE_C_FLAGS_RELEASE "/MD /Ox /Ob2 /Oi /Ot /Oy /GL /DNDEBUG")
+endif()