File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 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
@@ -64,6 +64,7 @@ IF(MINGW AND CMAKE_SIZEOF_VOID_P EQUAL 4)
64
64
ENDIF ()
65
65
66
66
IF (MSVC )
67
+ OPTION (LINK_STATIC_RUNTIME_LIBRARIES "Link with /MT" OFF )
67
68
# Enable debug info also in Release build,
68
69
# and create PDB to be able to analyze crashes.
69
70
FOREACH (type EXE SHARED MODULE )
@@ -86,7 +87,9 @@ IF(MSVC)
86
87
CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_DEBUG_INIT
87
88
CMAKE_CXX_FLAGS_RELEASE CMAKE_CXX_FLAGS_RELWITHDEBINFO
88
89
CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_DEBUG_INIT )
89
- STRING (REPLACE "/MD" "/MT" "${flag} " "${${flag} }" )
90
+ IF (LINK_STATIC_RUNTIME_LIBRARIES )
91
+ STRING (REPLACE "/MD" "/MT" "${flag} " "${${flag} }" )
92
+ ENDIF ()
90
93
STRING (REPLACE "/Zi" "/Z7" "${flag} " "${${flag} }" )
91
94
ENDFOREACH ()
92
95
You can’t perform that action at this time.
0 commit comments