Commit 9f75a9ce78987a1e3cb9a116560b3de9afb3695c

Ben Straub 2012-03-30T06:34:30

Turning on runtime checks when building debug under MSVC.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 383627b..c624e49 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -64,10 +64,11 @@ IF (MSVC)
 	IF (STDCALL)
 	  SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Gz")
 	ENDIF ()
-	# TODO: bring back /RTC1 /RTCc
-	SET(CMAKE_C_FLAGS_DEBUG "/Od /DEBUG /MTd")
+	SET(CMAKE_C_FLAGS_DEBUG "/Od /DEBUG /MTd /RTC1 /RTCs /RTCu")
 	SET(CMAKE_C_FLAGS_RELEASE "/MT /O2")
 	SET(WIN_RC "src/win32/git2.rc")
+
+   # Precompiled headers
 ELSE ()
 	SET(CMAKE_C_FLAGS "-O2 -g -D_GNU_SOURCE -Wall -Wextra -Wno-missing-field-initializers -Wstrict-aliasing=2 -Wstrict-prototypes -Wmissing-prototypes ${CMAKE_C_FLAGS}")
 	SET(CMAKE_C_FLAGS_DEBUG "-O0 -g")