summaryrefslogtreecommitdiffstats
path: root/Modules/FindQt3.cmake
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2012-08-20 19:42:34 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2012-08-20 19:42:34 (GMT)
commitc79dd4d951eec397692dd4af18e6a85b25a4f4ef (patch)
tree8e7cbfd9c44e410b216b18fecf331c8d50cfa922 /Modules/FindQt3.cmake
parent19e210af90d943548e7f07759030a2dd2cc8a2a4 (diff)
parent4be6783711b2ff510c3449c5de22d35663d8bfc1 (diff)
downloadCMake-c79dd4d951eec397692dd4af18e6a85b25a4f4ef.zip
CMake-c79dd4d951eec397692dd4af18e6a85b25a4f4ef.tar.gz
CMake-c79dd4d951eec397692dd4af18e6a85b25a4f4ef.tar.bz2
Merge topic 'read-less-from-version-headers'
4be6783 read less from version headers into variables
Diffstat (limited to 'Modules/FindQt3.cmake')
-rw-r--r--Modules/FindQt3.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/FindQt3.cmake b/Modules/FindQt3.cmake
index 856df56..0665063 100644
--- a/Modules/FindQt3.cmake
+++ b/Modules/FindQt3.cmake
@@ -74,9 +74,9 @@ endif()
if(QT_INCLUDE_DIR)
#extract the version string from qglobal.h
- file(READ ${QT_INCLUDE_DIR}/qglobal.h QGLOBAL_H)
- string(REGEX MATCH "#define[\t ]+QT_VERSION_STR[\t ]+\"[0-9]+.[0-9]+.[0-9]+[a-z]*\"" QGLOBAL_H "${QGLOBAL_H}")
+ file(STRINGS ${QT_INCLUDE_DIR}/qglobal.h QGLOBAL_H REGEX "#define[\t ]+QT_VERSION_STR[\t ]+\"[0-9]+.[0-9]+.[0-9]+[a-z]*\"")
string(REGEX REPLACE ".*\"([0-9]+.[0-9]+.[0-9]+[a-z]*)\".*" "\\1" qt_version_str "${QGLOBAL_H}")
+ unset(QGLOBAL_H)
# Under windows the qt library (MSVC) has the format qt-mtXYZ where XYZ is the
# version X.Y.Z, so we need to remove the dots from version