[cmake-commits] hoffman committed FindQt4.cmake 1.66 1.67

cmake-commits at cmake.org cmake-commits at cmake.org
Mon Feb 19 13:44:33 EST 2007


Update of /cvsroot/CMake/CMake/Modules
In directory public:/mounts/ram/cvs-serv1833

Modified Files:
	FindQt4.cmake 
Log Message:
BUG: fix for bug 4464 handle qmake errors better


Index: FindQt4.cmake
===================================================================
RCS file: /cvsroot/CMake/CMake/Modules/FindQt4.cmake,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -d -r1.66 -r1.67
--- FindQt4.cmake	7 Feb 2007 16:50:57 -0000	1.66
+++ FindQt4.cmake	19 Feb 2007 18:44:30 -0000	1.67
@@ -222,12 +222,18 @@
     WORKING_DIRECTORY  
     ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmpQmake
     OUTPUT_VARIABLE _qmake_query_output
-    ERROR_VARIABLE _qmake_query_output )
-
+    RESULT_VARIABLE _qmake_result
+    ERROR_VARIABLE _qmake_error_output )
+  
   FILE(REMOVE_RECURSE 
     "${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmpQmake")
 
-  STRING(REGEX REPLACE ".*CMAKE_MESSAGE<([^>]*).*" "\\1" ${outvar} "${_qmake_query_output}")
+  IF(_qmake_result)
+    MESSAGE(WARNING " querying qmake for ${invar}.  qmake reported:\n${_qmake_error_output}")
+  ELSE(_qmake_result)
+    STRING(REGEX REPLACE ".*CMAKE_MESSAGE<([^>]*).*" "\\1" ${outvar} "${_qmake_query_output}")
+  ENDIF(_qmake_result)
+
 ENDMACRO(QT_QUERY_QMAKE)
 
 # check for qmake



More information about the Cmake-commits mailing list