diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3d19bcd..6e28c24 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1026,13 +1026,19 @@ else ()
 endif ()
 
 if (BUILD_STATIC)
-  add_library(cryptopp-static STATIC ${cryptopp_LIBRARY_SOURCES})
-  cryptopp_target_compile_properties(cryptopp-static)
+  add_library(cryptopp-staticcrt STATIC ${cryptopp_LIBRARY_SOURCES})
+  cryptopp_target_compile_properties(cryptopp-staticcrt)
   if (NOT ${CMAKE_VERSION} VERSION_LESS "2.8.11")
-    target_include_directories(cryptopp-static PUBLIC $<BUILD_INTERFACE:${SRC_DIR}> $<INSTALL_INTERFACE:include>)
+    target_include_directories(cryptopp-staticcrt PUBLIC $<BUILD_INTERFACE:${SRC_DIR}> $<INSTALL_INTERFACE:include>)
   else ()
-    set_target_properties(cryptopp-static PROPERTIES INCLUDE_DIRECTORIES "$<BUILD_INTERFACE:${SRC_DIR}> $<INSTALL_INTERFACE:include>")
+    set_target_properties(cryptopp-staticcrt PROPERTIES INCLUDE_DIRECTORIES "$<BUILD_INTERFACE:${SRC_DIR}> $<INSTALL_INTERFACE:include>")
   endif ()
+  if (WIN32)
+    set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS} /MTd")
+    set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS} /MTd")
+    set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS} /MT")
+    set (CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS} /MT")
+  endif()
 endif ()
 
 if (BUILD_SHARED)
@@ -1050,7 +1056,7 @@ if (NOT MSVC)
   set(COMPAT_VERSION ${cryptopp_VERSION_MAJOR}.${cryptopp_VERSION_MINOR})
 
   if (BUILD_STATIC)
-    set_target_properties(cryptopp-static
+    set_target_properties(cryptopp-staticcrt
         PROPERTIES
         OUTPUT_NAME cryptopp)
   endif ()
@@ -1066,7 +1072,7 @@ endif ()
 # similar to how the crypto++ 'make' tool works.
 # see https://github.com/noloader/cryptopp-cmake/issues/32
 if (BUILD_STATIC)
-  add_custom_target(static DEPENDS cryptopp-static)
+  add_custom_target(static DEPENDS cryptopp-staticcrt)
 endif ()
 if (BUILD_SHARED)
   add_custom_target(shared DEPENDS cryptopp-shared)
@@ -1079,7 +1085,7 @@ endif ()
 
 if (WIN32)
   if (BUILD_STATIC)
-    target_link_libraries(cryptopp-static ws2_32)
+    target_link_libraries(cryptopp-staticcrt ws2_32)
   endif ()
   if (BUILD_SHARED)
     target_link_libraries(cryptopp-shared ws2_32)
@@ -1089,7 +1095,7 @@ endif ()
 # This may need to be expanded to "Solaris"
 if (CRYPTOPP_SOLARIS)
   if (BUILD_STATIC)
-    target_link_libraries(cryptopp-static nsl socket)
+    target_link_libraries(cryptopp-staticcrt nsl socket)
   endif ()
   if (BUILD_SHARED)
     target_link_libraries(cryptopp-shared nsl socket)
@@ -1098,7 +1104,7 @@ endif ()
 
 find_package(Threads)
 if (BUILD_STATIC)
-  target_link_libraries(cryptopp-static ${CMAKE_THREAD_LIBS_INIT})
+  target_link_libraries(cryptopp-staticcrt ${CMAKE_THREAD_LIBS_INIT})
 endif ()
 if (BUILD_SHARED)
   target_link_libraries(cryptopp-shared ${CMAKE_THREAD_LIBS_INIT})
@@ -1111,7 +1117,7 @@ endif ()
 enable_testing()
 if (BUILD_TESTING)
   add_executable(cryptest ${cryptopp_SOURCES_TEST})
-  target_link_libraries(cryptest cryptopp-static)
+  target_link_libraries(cryptest cryptopp-staticcrt)
 
   # Setting "cryptest" binary name to "cryptest.exe"
   if (NOT (WIN32 OR CYGWIN))
@@ -1176,17 +1182,17 @@ endif ()
 
 # Development package
 if (BUILD_STATIC)
-  export(TARGETS cryptopp-static FILE ${export_name}.cmake )
-  install(TARGETS cryptopp-static EXPORT ${export_name} DESTINATION ${CMAKE_INSTALL_LIBDIR})
+  export(TARGETS cryptopp-staticcrt FILE ${export_name}.cmake )
+  install(TARGETS cryptopp-staticcrt EXPORT ${export_name} DESTINATION ${CMAKE_INSTALL_LIBDIR})
 endif ()
-install(FILES ${cryptopp_HEADERS} DESTINATION include/cryptopp)
+install(FILES ${cryptopp_HEADERS} DESTINATION include/cryptopp-staticcrt)
 
 # CMake Package
 if (NOT CMAKE_VERSION VERSION_LESS 2.8.8)
   include(CMakePackageConfigHelpers)
   write_basic_package_version_file("${PROJECT_BINARY_DIR}/cryptopp-config-version.cmake" VERSION ${cryptopp_VERSION_MAJOR}.${cryptopp_VERSION_MINOR}.${cryptopp_VERSION_PATCH} COMPATIBILITY SameMajorVersion)
-  install(FILES cryptopp-config.cmake ${PROJECT_BINARY_DIR}/cryptopp-config-version.cmake DESTINATION "lib/cmake/cryptopp")
-  install(EXPORT ${export_name} DESTINATION "lib/cmake/cryptopp")
+  install(FILES cryptopp-config.cmake ${PROJECT_BINARY_DIR}/cryptopp-config-version.cmake DESTINATION "lib/cmake/cryptopp-staticcrt")
+  install(EXPORT ${export_name} DESTINATION "lib/cmake/cryptopp-staticcrt")
 endif ()
 
 # Tests
