1
- # Copyright (c) 2010, 2016 , Oracle and/or its affiliates. All rights reserved.
1
+ # Copyright (c) 2010, 2017 , Oracle and/or its affiliates. All rights reserved.
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
@@ -75,7 +75,6 @@ IF(MSVC)
75
75
ENDFOREACH ()
76
76
77
77
# For release types Debug Release RelWithDebInfo (but not MinSizeRel):
78
- # - Force static runtime libraries
79
78
# - Choose C++ exception handling:
80
79
# If /EH is not specified, the compiler will catch structured and
81
80
# C++ exceptions, but will not destroy C++ objects that will go out of
@@ -98,20 +97,20 @@ IF(MSVC)
98
97
FOREACH (lang C CXX )
99
98
SET (CMAKE_${lang}_FLAGS_RELEASE "${CMAKE_${lang} _FLAGS_RELEASE} /Z7" )
100
99
ENDFOREACH ()
101
- IF ( NOT WINDOWS_RUNTIME_MD )
100
+
102
101
FOREACH (flag
103
102
CMAKE_C_FLAGS_RELEASE CMAKE_C_FLAGS_RELWITHDEBINFO
104
103
CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_DEBUG_INIT
105
104
CMAKE_CXX_FLAGS_RELEASE CMAKE_CXX_FLAGS_RELWITHDEBINFO
106
105
CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_DEBUG_INIT )
107
- STRING (REPLACE "/MD" "/MT" "${flag} " "${${flag} }" )
106
+ # Disable this substitution, use default, which is /MD
107
+ # STRING(REPLACE "/MD" "/MT" "${flag}" "${${flag}}")
108
108
STRING (REPLACE "/Zi" "/Z7" "${flag} " "${${flag} }" )
109
109
IF (NOT WIN_DEBUG_NO_INLINE )
110
110
STRING (REPLACE "/Ob0" "/Ob1" "${flag} " "${${flag} }" )
111
111
ENDIF ()
112
112
SET ("${flag} " "${${flag} } /EHsc" )
113
113
ENDFOREACH ()
114
- ENDIF ()
115
114
116
115
# Fix CMake's predefined huge stack size
117
116
FOREACH (type EXE SHARED MODULE )
0 commit comments