Created
August 11, 2017 12:53
-
-
Save viceice/34a3ec7f1c433688dcc09c0fc797df07 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git "a/CMakeLists.txt" "b/CMakeLists.txt" | |
index 846241d..ff2b10e 100644 | |
--- "a/CMakeLists.txt" | |
+++ "b/CMakeLists.txt" | |
@@ -567,6 +567,16 @@ SET(PCREPOSIX_SOURCES | |
ENDIF (EXISTS ${PROJECT_SOURCE_DIR}/pcreposix.rc) | |
ENDIF(MSVC AND NOT PCRE_STATIC) | |
+IF(MSVC AND PCRE_STATIC) | |
+ foreach(flag_var | |
+ CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE | |
+ CMAKE_C_FLAGS_MINSIZEREL CMAKE_C_FLAGS_RELWITHDEBINFO) | |
+ if(${flag_var} MATCHES "/MD") | |
+ string(REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}") | |
+ endif(${flag_var} MATCHES "/MD") | |
+ endforeach(flag_var) | |
+ENDIF(MSVC AND PCRE_STATIC) | |
+ | |
SET(PCRECPP_HEADERS | |
pcrecpp.h | |
pcre_scanner.h |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment