diff options
author | Brad King <brad.king@kitware.com> | 2020-01-20 18:16:57 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-01-20 18:19:56 (GMT) |
commit | 7ca923bcaf0b548445fca8c0c18784aca3415bc2 (patch) | |
tree | 478531b57845489b2d6bc783efa9c5ffd6bd2c58 /Modules | |
parent | 5b43aa775507c974284bbae2e6bd13e11caec80d (diff) | |
download | CMake-7ca923bcaf0b548445fca8c0c18784aca3415bc2.zip CMake-7ca923bcaf0b548445fca8c0c18784aca3415bc2.tar.gz CMake-7ca923bcaf0b548445fca8c0c18784aca3415bc2.tar.bz2 |
IRSL: Install msvcp140_{1,2,codecvt_ids}.dll if available
VS now distributes these additional runtime libraries. Install them if
available.
Fixes: #20228
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/InstallRequiredSystemLibraries.cmake | 26 |
1 files changed, 20 insertions, 6 deletions
diff --git a/Modules/InstallRequiredSystemLibraries.cmake b/Modules/InstallRequiredSystemLibraries.cmake index 0e1429d..04687b9 100644 --- a/Modules/InstallRequiredSystemLibraries.cmake +++ b/Modules/InstallRequiredSystemLibraries.cmake @@ -288,9 +288,16 @@ if(MSVC) "${MSVC_CRT_DIR}/msvcp${v}.dll" ) if(NOT vs VERSION_LESS 14) - if(EXISTS "${MSVC_CRT_DIR}/vcruntime${v}_1.dll") - list(APPEND __install__libs "${MSVC_CRT_DIR}/vcruntime${v}_1.dll") - endif() + foreach(crt + "${MSVC_CRT_DIR}/msvcp${v}_1.dll" + "${MSVC_CRT_DIR}/msvcp${v}_2.dll" + "${MSVC_CRT_DIR}/msvcp${v}_codecvt_ids.dll" + "${MSVC_CRT_DIR}/vcruntime${v}_1.dll" + ) + if(EXISTS "${crt}") + list(APPEND __install__libs "${crt}") + endif() + endforeach() list(APPEND __install__libs "${MSVC_CRT_DIR}/vcruntime${v}.dll" "${MSVC_CRT_DIR}/concrt${v}.dll" @@ -309,9 +316,16 @@ if(MSVC) "${MSVC_CRT_DIR}/msvcp${v}d.dll" ) if(NOT vs VERSION_LESS 14) - if(EXISTS "${MSVC_CRT_DIR}/vcruntime${v}_1d.dll") - list(APPEND __install__libs "${MSVC_CRT_DIR}/vcruntime${v}_1d.dll") - endif() + foreach(crt + "${MSVC_CRT_DIR}/msvcp${v}_1d.dll" + "${MSVC_CRT_DIR}/msvcp${v}_2d.dll" + "${MSVC_CRT_DIR}/msvcp${v}d_codecvt_ids.dll" + "${MSVC_CRT_DIR}/vcruntime${v}_1d.dll" + ) + if(EXISTS "${crt}") + list(APPEND __install__libs "${crt}") + endif() + endforeach() list(APPEND __install__libs "${MSVC_CRT_DIR}/vcruntime${v}d.dll" "${MSVC_CRT_DIR}/concrt${v}d.dll" |