Merge pull request #13962 from Christianwidjaya:master

pull/13983/head^2
Alexander Alekhin 6 years ago
commit 3b43f90cc8
  1. 2
      cmake/OpenCVDetectCXXCompiler.cmake
  2. 10
      cmake/templates/OpenCVConfig.root-WIN32.cmake.in

@ -143,6 +143,8 @@ elseif(MSVC)
set(OpenCV_RUNTIME vc14) set(OpenCV_RUNTIME vc14)
elseif(MSVC_VERSION MATCHES "^191[0-9]$") elseif(MSVC_VERSION MATCHES "^191[0-9]$")
set(OpenCV_RUNTIME vc15) set(OpenCV_RUNTIME vc15)
elseif(MSVC_VERSION MATCHES "^192[0-9]$")
set(OpenCV_RUNTIME vc16)
else() else()
message(WARNING "OpenCV does not recognize MSVC_VERSION \"${MSVC_VERSION}\". Cannot set OpenCV_RUNTIME") message(WARNING "OpenCV does not recognize MSVC_VERSION \"${MSVC_VERSION}\". Cannot set OpenCV_RUNTIME")
endif() endif()

@ -113,6 +113,16 @@ elseif(MSVC)
if(NOT has_VS2017) if(NOT has_VS2017)
set(OpenCV_RUNTIME vc14) # selecting previous compatible runtime version set(OpenCV_RUNTIME vc14) # selecting previous compatible runtime version
endif() endif()
elseif(MSVC_VERSION MATCHES "^192[0-9]$")
set(OpenCV_RUNTIME vc16)
check_one_config(has_VS2019)
if(NOT has_VS2019)
set(OpenCV_RUNTIME vc15) # selecting previous compatible runtime version
check_one_config(has_VS2017)
if(NOT has_VS2017)
set(OpenCV_RUNTIME vc14) # selecting previous compatible runtime version
endif()
endif()
endif() endif()
elseif(MINGW) elseif(MINGW)
set(OpenCV_RUNTIME mingw) set(OpenCV_RUNTIME mingw)

Loading…
Cancel
Save