#Use statically linked runtime by passing this file to cmake with #cmake -DCMAKE_USER_MAKE_RULES_OVERRIDE_CXX= #Python should be compiled with /MT or /MTd so it will use the static CRT, #thereby allowing the linker to resolve _pioinfo under Visual Studio 2015 #and later. # #See https://cmake.org/Wiki/CMake_FAQ#How_can_I_build_my_MSVC_application_with_a_static_runtime.3F # if(MSVC) set(CMAKE_CXX_FLAGS_DEBUG_INIT "/D_DEBUG /MTd /Zi /Ob0 /Od /RTC1") set(CMAKE_CXX_FLAGS_MINSIZEREL_INIT "/MT /O1 /Ob1 /D NDEBUG") set(CMAKE_CXX_FLAGS_RELEASE_INIT "/MT /O2 /Ob2 /D NDEBUG") set(CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "/MT /Zi /O2 /Ob1 /D NDEBUG") endif(MSVC)