Tests: Nudge MFC test to pass on VS 6 dashboards (#11213)
InstallRequiredSystemLibraries does not install any dlls when used with VS 6 dashboards. Modify the ValidateBuild script to expect only 1 file when building with VS 6. Using "-DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>" does not work when <INSTALL_DIR> evaluates to a long enough string. However, using "-DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>" does work, even with the longer strings. So: make sure to include the ":PATH" when using this construct with ExternalProject calls so that they may install to the proper location on VS 6 builds. All existing calls that match "CMAKE_INSTALL_PREFIX.*INSTALL_DIR" include the ":PATH" after this commit. By the way: https://twitter.com/DLRdave/status/134339505397309440
This commit is contained in:
parent
51f442e603
commit
537020f958
|
@ -6,6 +6,6 @@ include(ExternalProject)
|
||||||
ExternalProject_Add(
|
ExternalProject_Add(
|
||||||
cmake281
|
cmake281
|
||||||
URL http://www.cmake.org/files/v2.8/cmake-2.8.1.tar.gz
|
URL http://www.cmake.org/files/v2.8/cmake-2.8.1.tar.gz
|
||||||
CMAKE_ARGS -D CMAKE_INSTALL_PREFIX=<INSTALL_DIR>
|
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
|
||||||
BUILD_COMMAND ""
|
BUILD_COMMAND ""
|
||||||
)
|
)
|
||||||
|
|
|
@ -17,7 +17,7 @@ ExternalProject_Add(mfcShared
|
||||||
PATCH_COMMAND ${CMAKE_COMMAND} -E copy
|
PATCH_COMMAND ${CMAKE_COMMAND} -E copy
|
||||||
${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.SharedMfcDll.txt
|
${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.SharedMfcDll.txt
|
||||||
<SOURCE_DIR>/CMakeLists.txt
|
<SOURCE_DIR>/CMakeLists.txt
|
||||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
|
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@ ExternalProject_Add(mfcStatic
|
||||||
PATCH_COMMAND ${CMAKE_COMMAND} -E copy
|
PATCH_COMMAND ${CMAKE_COMMAND} -E copy
|
||||||
${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.StaticMfcLib.txt
|
${CMAKE_CURRENT_BINARY_DIR}/CMakeLists.StaticMfcLib.txt
|
||||||
<SOURCE_DIR>/CMakeLists.txt
|
<SOURCE_DIR>/CMakeLists.txt
|
||||||
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
|
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -31,9 +31,17 @@ message(STATUS "===== mfcShared install tree =====")
|
||||||
file(GLOB_RECURSE files "${binary_dir}/mfcShared-prefix/bin/*.*")
|
file(GLOB_RECURSE files "${binary_dir}/mfcShared-prefix/bin/*.*")
|
||||||
message(STATUS "mfcShared files='${files}'")
|
message(STATUS "mfcShared files='${files}'")
|
||||||
list(LENGTH files len)
|
list(LENGTH files len)
|
||||||
if(len LESS 3)
|
|
||||||
|
set(msvc6 "@MSVC60@")
|
||||||
|
if("${msvc6}" STREQUAL "1")
|
||||||
|
set(expected_minimum_file_count 1)
|
||||||
|
else()
|
||||||
|
set(expected_minimum_file_count 3)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(len LESS ${expected_minimum_file_count})
|
||||||
message(FATAL_ERROR
|
message(FATAL_ERROR
|
||||||
"len='${len}' is less than '3' (count of shared 'bin' files)")
|
"len='${len}' is less than '${expected_minimum_file_count}' (count of shared 'bin' files)")
|
||||||
endif()
|
endif()
|
||||||
foreach(f ${files})
|
foreach(f ${files})
|
||||||
message(STATUS "file '${f}'")
|
message(STATUS "file '${f}'")
|
||||||
|
|
Loading…
Reference in New Issue