summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-01-30 16:34:24 (GMT)
committerBrad King <brad.king@kitware.com>2019-01-30 16:34:24 (GMT)
commit1faebf33f46cdd09d5ba1768f2f0879df23563a8 (patch)
treec694cf0f509e1246f1982eed8c4c38b168a6b843 /Source
parent17b1d7995efb14e14b15926dbb5fc530b71ed149 (diff)
parent2df6d69014c8f8c0191dbf30d8c406225edbef3e (diff)
downloadCMake-1faebf33f46cdd09d5ba1768f2f0879df23563a8.zip
CMake-1faebf33f46cdd09d5ba1768f2f0879df23563a8.tar.gz
CMake-1faebf33f46cdd09d5ba1768f2f0879df23563a8.tar.bz2
Merge branch 'backport-autogen-qt-version-from-dirprops' into release-3.13
Merge-request: !2883
Diffstat (limited to 'Source')
-rw-r--r--Source/cmQtAutoGenInitializer.cxx12
1 files changed, 12 insertions, 0 deletions
diff --git a/Source/cmQtAutoGenInitializer.cxx b/Source/cmQtAutoGenInitializer.cxx
index f9c8c7f..90111801 100644
--- a/Source/cmQtAutoGenInitializer.cxx
+++ b/Source/cmQtAutoGenInitializer.cxx
@@ -1281,6 +1281,12 @@ cmQtAutoGenInitializer::IntegerVersion cmQtAutoGenInitializer::GetQtVersion(
if (qtMajor.empty()) {
qtMajor = makefile->GetSafeDefinition("Qt5Core_VERSION_MAJOR");
}
+ if (qtMajor.empty()) {
+ const char* dirprop = makefile->GetProperty("Qt5Core_VERSION_MAJOR");
+ if (dirprop) {
+ qtMajor = dirprop;
+ }
+ }
{
const char* targetQtVersion =
target->GetLinkInterfaceDependentStringProperty("QT_MAJOR_VERSION", "");
@@ -1294,6 +1300,12 @@ cmQtAutoGenInitializer::IntegerVersion cmQtAutoGenInitializer::GetQtVersion(
if (!qtMajor.empty()) {
if (qtMajor == "5") {
qtMinor = makefile->GetSafeDefinition("Qt5Core_VERSION_MINOR");
+ if (qtMinor.empty()) {
+ const char* dirprop = makefile->GetProperty("Qt5Core_VERSION_MINOR");
+ if (dirprop) {
+ qtMinor = dirprop;
+ }
+ }
}
if (qtMinor.empty()) {
qtMinor = makefile->GetSafeDefinition("QT_VERSION_MINOR");