summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-01-08 19:32:22 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2013-01-08 19:32:22 (GMT)
commitbc414aebaf80cf7a5c67e79e1a5d1f4417164263 (patch)
tree4815bd572dfc7e4fc30aadc0a9fd5acd52352d38
parent9549ac1df5c1c7c330cb07cde29f424bfcfb4c1a (diff)
parent4b9ec00d0e175ec4cc7e1fbe6ed7d1dcbcfb25ba (diff)
downloadCMake-bc414aebaf80cf7a5c67e79e1a5d1f4417164263.zip
CMake-bc414aebaf80cf7a5c67e79e1a5d1f4417164263.tar.gz
CMake-bc414aebaf80cf7a5c67e79e1a5d1f4417164263.tar.bz2
Merge topic 'qt4-version-openssl'
4b9ec00 FindQt4: set QT_VERSION_* variables sooner.
-rw-r--r--Modules/FindQt4.cmake10
1 files changed, 5 insertions, 5 deletions
diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
index 381141c..fdf4883 100644
--- a/Modules/FindQt4.cmake
+++ b/Modules/FindQt4.cmake
@@ -538,6 +538,11 @@ endif ()
if (QT_QMAKE_EXECUTABLE AND QTVERSION)
+ # set version variables
+ string(REGEX REPLACE "^([0-9]+)\\.[0-9]+\\.[0-9]+.*" "\\1" QT_VERSION_MAJOR "${QTVERSION}")
+ string(REGEX REPLACE "^[0-9]+\\.([0-9]+)\\.[0-9]+.*" "\\1" QT_VERSION_MINOR "${QTVERSION}")
+ string(REGEX REPLACE "^[0-9]+\\.[0-9]+\\.([0-9]+).*" "\\1" QT_VERSION_PATCH "${QTVERSION}")
+
# ask qmake for the mkspecs directory
# we do this first because QT_LIBINFIX might be set
if (NOT QT_MKSPECS_DIR OR QT_QMAKE_CHANGED)
@@ -1229,11 +1234,6 @@ if (QT_QMAKE_EXECUTABLE AND QTVERSION)
include("${_qt4_current_dir}/Qt4Macros.cmake")
- # set version variables
- string(REGEX REPLACE "^([0-9]+)\\.[0-9]+\\.[0-9]+.*" "\\1" QT_VERSION_MAJOR "${QTVERSION}")
- string(REGEX REPLACE "^[0-9]+\\.([0-9]+)\\.[0-9]+.*" "\\1" QT_VERSION_MINOR "${QTVERSION}")
- string(REGEX REPLACE "^[0-9]+\\.[0-9]+\\.([0-9]+).*" "\\1" QT_VERSION_PATCH "${QTVERSION}")
-
endif()
#support old QT_MIN_VERSION if set, but not if version is supplied by find_package()