Skip to content

Commit

Permalink
Merge pull request #236 from mludha/nghttp3/msvc-static-crt-fix
Browse files Browse the repository at this point in the history
cmake: Update ENABLE_STATIC_CRT for cmake >= 3.15
  • Loading branch information
tatsuhiro-t authored Jul 17, 2024
2 parents 9cfc89d + 574b141 commit caf3de4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,7 @@ else()
endif()

if(ENABLE_STATIC_CRT)
foreach(lang C CXX)
foreach(suffix "" _DEBUG _MINSIZEREL _RELEASE _RELWITHDEBINFO)
set(var "CMAKE_${lang}_FLAGS${suffix}")
string(REPLACE "/MD" "/MT" ${var} "${${var}}")
endforeach()
endforeach()
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
endif()

if(ENABLE_DEBUG)
Expand Down

0 comments on commit caf3de4

Please sign in to comment.