summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBjoern Thiel <bthiel@gwdg.de>2015-04-24 09:12:00 (GMT)
committerBrad King <brad.king@kitware.com>2015-04-27 14:09:38 (GMT)
commitff183986df719bfee0abd1f8c1e09dc348f04bd5 (patch)
treec14d7f1a381379e44bddc4c915aeca4be4c350b2 /Modules
parentebb54e02c4bfd9ef8ffb92a49afb873a0af58f2a (diff)
downloadCMake-ff183986df719bfee0abd1f8c1e09dc348f04bd5.zip
CMake-ff183986df719bfee0abd1f8c1e09dc348f04bd5.tar.gz
CMake-ff183986df719bfee0abd1f8c1e09dc348f04bd5.tar.bz2
InstallRequiredSystemLibraries: Fix MBCS MFC detection (#15531)
Fix the logic added by commit v3.0.0-rc5~9^2 (InstallRequiredSystemLibraries: MBCS MFC is optional on VS 12, 2014-05-06). Do not test content of MSVC${v}_MFC_DIR until after the variable is set.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/InstallRequiredSystemLibraries.cmake9
1 files changed, 2 insertions, 7 deletions
diff --git a/Modules/InstallRequiredSystemLibraries.cmake b/Modules/InstallRequiredSystemLibraries.cmake
index c7e88ba..5509b28 100644
--- a/Modules/InstallRequiredSystemLibraries.cmake
+++ b/Modules/InstallRequiredSystemLibraries.cmake
@@ -324,11 +324,6 @@ if(MSVC)
# Multi-Byte Character Set versions of MFC are available as optional
# addon since Visual Studio 12. So for version 12 or higher, check
# whether they are available and exclude them if they are not.
- if("${v}" LESS 12 OR EXISTS "${MSVC${v}_MFC_DIR}/mfc${v}0d.dll")
- set(mbcs ON)
- else()
- set(mbcs OFF)
- endif()
if(CMAKE_INSTALL_DEBUG_LIBRARIES)
set(MSVC${v}_MFC_DIR
@@ -337,7 +332,7 @@ if(MSVC)
"${MSVC${v}_MFC_DIR}/mfc${v}0ud.dll"
"${MSVC${v}_MFC_DIR}/mfcm${v}0ud.dll"
)
- if(mbcs)
+ if("${v}" LESS 12 OR EXISTS "${MSVC${v}_MFC_DIR}/mfc${v}0d.dll")
set(__install__libs ${__install__libs}
"${MSVC${v}_MFC_DIR}/mfc${v}0d.dll"
"${MSVC${v}_MFC_DIR}/mfcm${v}0d.dll"
@@ -351,7 +346,7 @@ if(MSVC)
"${MSVC${v}_MFC_DIR}/mfc${v}0u.dll"
"${MSVC${v}_MFC_DIR}/mfcm${v}0u.dll"
)
- if(mbcs)
+ if("${v}" LESS 12 OR EXISTS "${MSVC${v}_MFC_DIR}/mfc${v}0.dll")
set(__install__libs ${__install__libs}
"${MSVC${v}_MFC_DIR}/mfc${v}0.dll"
"${MSVC${v}_MFC_DIR}/mfcm${v}0.dll"