summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2011-01-14 15:22:15 (GMT)
committerBrad King <brad.king@kitware.com>2011-01-14 15:22:15 (GMT)
commit20d87c8026d3e23d8f9f18b735bc0304ec80d046 (patch)
tree18d11086723d6934347037bab3015287c2e104f4
parentb2f308c8f9b4ded77f0693b39c0288e3bbb00977 (diff)
downloadCMake-20d87c8026d3e23d8f9f18b735bc0304ec80d046.zip
CMake-20d87c8026d3e23d8f9f18b735bc0304ec80d046.tar.gz
CMake-20d87c8026d3e23d8f9f18b735bc0304ec80d046.tar.bz2
Teach Simple_Mingw_Linux2Win test to use windres
This test was broken by commit b2f308c8 (Add support for windows resources with mingw/msys, 2010-12-22) because the test does not set a resource compiler which is now required on MinGW for the 'RC' language. Use windres as the resource compiler for the test.
-rw-r--r--Tests/CMakeLists.txt17
1 files changed, 9 insertions, 8 deletions
diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt
index 8f29641..f70b224 100644
--- a/Tests/CMakeLists.txt
+++ b/Tests/CMakeLists.txt
@@ -1694,12 +1694,13 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/
"-DCMAKE_C_COMPILER=${SDCC_EXECUTABLE}")
LIST(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/SimpleCOnly_sdcc")
ENDIF(SDCC_EXECUTABLE)
-
-
+
+ # If a Linux -> MinGW cross compiler is found then try it
FIND_PROGRAM(MINGW_CC_LINUX2WIN_EXECUTABLE i586-mingw32msvc-gcc)
FIND_PROGRAM(MINGW_CXX_LINUX2WIN_EXECUTABLE i586-mingw32msvc-g++)
- MARK_AS_ADVANCED(MINGW_CC_LINUX2WIN_EXECUTABLE MINGW_CXX_LINUX2WIN_EXECUTABLE)
- IF(MINGW_CC_LINUX2WIN_EXECUTABLE AND MINGW_CXX_LINUX2WIN_EXECUTABLE)
+ FIND_PROGRAM(MINGW_RC_LINUX2WIN_EXECUTABLE i586-mingw32msvc-windres)
+ MARK_AS_ADVANCED(MINGW_CC_LINUX2WIN_EXECUTABLE MINGW_CXX_LINUX2WIN_EXECUTABLE MINGW_RC_LINUX2WIN_EXECUTABLE)
+ IF(MINGW_CC_LINUX2WIN_EXECUTABLE AND MINGW_CXX_LINUX2WIN_EXECUTABLE AND MINGW_RC_LINUX2WIN_EXECUTABLE)
ADD_TEST(Simple_Mingw_Linux2Win ${CMAKE_CTEST_COMMAND}
--build-and-test
"${CMake_SOURCE_DIR}/Tests/Simple"
@@ -1710,11 +1711,11 @@ ${CMake_BINARY_DIR}/bin/cmake -DVERSION=master -P ${CMake_SOURCE_DIR}/Utilities/
--build-options
"-DCMAKE_SYSTEM_NAME=Windows"
"-DCMAKE_C_COMPILER=${MINGW_CC_LINUX2WIN_EXECUTABLE}"
- "-DCMAKE_CXX_COMPILER=${MINGW_CXX_LINUX2WIN_EXECUTABLE}")
+ "-DCMAKE_CXX_COMPILER=${MINGW_CXX_LINUX2WIN_EXECUTABLE}"
+ "-DCMAKE_RC_COMPILER=${MINGW_RC_LINUX2WIN_EXECUTABLE}"
+ )
LIST(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/Simple_Mingw_Linux2Win")
- ENDIF(MINGW_CC_LINUX2WIN_EXECUTABLE AND MINGW_CXX_LINUX2WIN_EXECUTABLE)
-
-
+ ENDIF()
ENDIF(CMAKE_TEST_GENERATOR MATCHES "Makefiles" OR CMAKE_TEST_GENERATOR MATCHES "KDevelop")
IF(UNIX)