[Cmake-commits] CMake branch, next, updated. v2.8.11.2-3067-ge115256

Stephen Kelly steveire at gmail.com
Sat Jul 13 05:23:05 EDT 2013


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  e115256ac2752ce1dba98ff045e80083ec456822 (commit)
       via  7b8787991d54d431c4a16ab9200385b0332c1c21 (commit)
      from  1d7d9194701ddfa2e60c4c8229a6d01b7b02fd45 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e115256ac2752ce1dba98ff045e80083ec456822
commit e115256ac2752ce1dba98ff045e80083ec456822
Merge: 1d7d919 7b87879
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Sat Jul 13 05:23:04 2013 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Sat Jul 13 05:23:04 2013 -0400

    Merge topic 'obsolete-qt4-macros' into next
    
    7b87879 Try to debug the Qt4 problem in the test.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=7b8787991d54d431c4a16ab9200385b0332c1c21
commit 7b8787991d54d431c4a16ab9200385b0332c1c21
Author:     Stephen Kelly <steveire at gmail.com>
AuthorDate: Sat Jul 13 11:22:07 2013 +0200
Commit:     Stephen Kelly <steveire at gmail.com>
CommitDate: Sat Jul 13 11:22:07 2013 +0200

    Try to debug the Qt4 problem in the test.

diff --git a/Tests/RunCMake/ObsoleteQtMacros/UseModulesMacro-WARN.cmake b/Tests/RunCMake/ObsoleteQtMacros/UseModulesMacro-WARN.cmake
index e86a372..b78554c 100644
--- a/Tests/RunCMake/ObsoleteQtMacros/UseModulesMacro-WARN.cmake
+++ b/Tests/RunCMake/ObsoleteQtMacros/UseModulesMacro-WARN.cmake
@@ -1,4 +1,56 @@
 
+function(test_find_qmake QMAKE_NAMES QMAKE_RESULT VERSION_RESULT)
+  list(LENGTH QMAKE_NAMES QMAKE_NAMES_LEN)
+  if(${QMAKE_NAMES_LEN} EQUAL 0)
+    return()
+  endif()
+  list(GET QMAKE_NAMES 0 QMAKE_NAME)
+
+  get_filename_component(qt_install_version "[HKEY_CURRENT_USER\\Software\\trolltech\\Versions;DefaultQtVersion]" NAME)
+
+  find_program(QT_QMAKE_EXECUTABLE NAMES ${QMAKE_NAME}
+    PATHS
+      ENV QTDIR
+      "[HKEY_CURRENT_USER\\Software\\Trolltech\\Versions\\${qt_install_version};InstallDir]"
+    PATH_SUFFIXES bin
+    DOC "The qmake executable for the Qt installation to use"
+  )
+
+  set(major 0)
+  if (QT_QMAKE_EXECUTABLE)
+    _qt4_query_qmake(QT_VERSION QTVERSION)
+    _qt4_get_version_components("${QTVERSION}" major minor patch)
+  endif()
+
+  if (NOT QT_QMAKE_EXECUTABLE OR NOT "${major}" EQUAL 4)
+    set(curr_qmake "${QT_QMAKE_EXECUTABLE}")
+    set(curr_qt_version "${QTVERSION}")
+
+    set(QT_QMAKE_EXECUTABLE NOTFOUND CACHE FILEPATH "" FORCE)
+    list(REMOVE_AT QMAKE_NAMES 0)
+    test_find_qmake("${QMAKE_NAMES}" QMAKE QTVERSION)
+
+    _qt4_get_version_components("${QTVERSION}" major minor patch)
+    if (NOT ${major} EQUAL 4)
+      # Restore possibly found qmake and it's version; these are used later
+      # in error message if incorrect version is found
+      set(QT_QMAKE_EXECUTABLE "${curr_qmake}" CACHE FILEPATH "" FORCE)
+      set(QTVERSION "${curr_qt_version}")
+    endif()
+
+  endif()
+
+
+  set(${QMAKE_RESULT} "${QT_QMAKE_EXECUTABLE}" PARENT_SCOPE)
+  set(${VERSION_RESULT} "${QTVERSION}" PARENT_SCOPE)
+endfunction()
+
+set(QMAKE_NAMES qmake qmake4 qmake-qt4 qmake-mac)
+test_find_qmake("${QMAKE_NAMES}" QMAKE_EXECUTABLE TESTQTVERSION)
+
+message("QMAKE_EXECUTABLE : ${QMAKE_EXECUTABLE}")
+message("TESTQTVERSION : ${TESTQTVERSION}")
+
 find_package(Qt4 REQUIRED)
 
 set(CMAKE_WARN_DEPRECATED 1)

-----------------------------------------------------------------------

Summary of changes:
 .../ObsoleteQtMacros/UseModulesMacro-WARN.cmake    |   52 ++++++++++++++++++++
 1 files changed, 52 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list