branches/KDE/4.4/kdebindings/smoke/qt
Arno Rehn
kde at arnorehn.de
Fri Jan 22 18:05:16 CET 2010
SVN commit 1078709 by arnorehn:
backport from trunk: fix build with current FindQt4.cmake
CCMAIL: kde-bindings at kde.org
CCMAIL: release-team at kde.org
CCMAIL: mueller at kde.org
CCMAIL: kde-packager at kde.org
CCMAIL: neundorf at kde.org
M +9 -2 QtGuess.txt
--- branches/KDE/4.4/kdebindings/smoke/qt/QtGuess.txt #1078708:1078709
@@ -136,13 +136,20 @@
message(STATUS "Checking how Qt was built...")
message(STATUS "Threshold is set to ${qt_test_threshold}")
+
+include (HandleImportedTargetsInCMakeRequiredLibraries)
+set(CMAKE_REQUIRED_INCLUDES ${CMAKE_SYSTEM_INCLUDE_PATH} ${QT_INCLUDE_DIR})
+set(CMAKE_REQUIRED_LIBRARIES ${QT_QTCORE_LIBRARY} ${QT_QTDBUS_LIBRARY} ${QT_QTGUI_LIBRARY} ${QT_QTNETWORK_LIBRARY} ${QT_QTOPENGL_LIBRARY} ${QT_QTXML_LIBRARY} ${QT_QTSVG_LIBRARY})
+HANDLE_IMPORTED_TARGETS_IN_CMAKE_REQUIRED_LIBRARIES(_CMAKE_REQUIRED_LIBRARIES)
+
foreach(test_target ${test_targets})
file(REMOVE_RECURSE ${CMAKE_CURRENT_BINARY_DIR}/test-${test_target})
+
try_compile(test_result "${CMAKE_CURRENT_BINARY_DIR}/test-${test_target}"
${CMAKE_CURRENT_SOURCE_DIR}/tests/test.cpp
COMPILE_DEFINITIONS -DTEST_${test_target}
- CMAKE_FLAGS "-DINCLUDE_DIRECTORIES:STRING=${CMAKE_SYSTEM_INCLUDE_PATH};${QT_INCLUDE_DIR}"
- "-DLINK_LIBRARIES:STRING=${QT_QTCORE_LIBRARY};${QT_QTDBUS_LIBRARY};${QT_QTGUI_LIBRARY};${QT_QTNETWORK_LIBRARY};${QT_QTOPENGL_LIBRARY};${QT_QTXML_LIBRARY};${QT_QTSVG_LIBRARY}")
+ CMAKE_FLAGS "-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}"
+ "-DLINK_LIBRARIES:STRING=${_CMAKE_REQUIRED_LIBRARIES}")
if(test_result)
message(STATUS "${test_target} *Undefined*")
else(test_result)
More information about the release-team
mailing list