aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorAlex Merry <alex.merry@kde.org>2014-12-07 19:17:34 +0000
committerAlex Merry <alex.merry@kde.org>2014-12-07 19:17:34 +0000
commitfd7aa7e8eab35c81faaeb8346a57b73dd63f4efb (patch)
tree93eb887615ee3aebd43488644d218cc9b7282643 /modules
parentb5f3c66c8182e2ca2d0670d3e0962bc215fea220 (diff)
downloadextra-cmake-modules-fd7aa7e8eab35c81faaeb8346a57b73dd63f4efb.tar.gz
extra-cmake-modules-fd7aa7e8eab35c81faaeb8346a57b73dd63f4efb.tar.bz2
Fix ECMQueryQmake when Qt5Core is found.
81627ad86d3d7d5e5a7d130dfc746d5b1b58cbe7 broke the case where Qt5 qmake is not in the path or not called qmake-qt5, because it stopped using the location of qmake as provided by the Qt5Core CMake module when found.
Diffstat (limited to 'modules')
-rw-r--r--modules/ECMQueryQmake.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/ECMQueryQmake.cmake b/modules/ECMQueryQmake.cmake
index 725e2eb6..c880671f 100644
--- a/modules/ECMQueryQmake.cmake
+++ b/modules/ECMQueryQmake.cmake
@@ -4,7 +4,7 @@ set(_qmake_executable_default "qmake-qt5")
if (TARGET Qt5::qmake)
get_target_property(_qmake_executable_default Qt5::qmake LOCATION)
endif()
-set(QMAKE_EXECUTABLE "qmake-qt5"
+set(QMAKE_EXECUTABLE ${_qmake_executable_default}
CACHE FILEPATH "Location of the Qt5 qmake executable")
# This is not public API (yet)!
@@ -14,8 +14,8 @@ function(query_qmake result_variable qt_variable)
RESULT_VARIABLE return_code
OUTPUT_VARIABLE output
)
- string(STRIP ${output} output)
if(return_code EQUAL 0)
+ string(STRIP "${output}" output)
file(TO_CMAKE_PATH "${output}" output_path)
set(${result_variable} "${output_path}" PARENT_SCOPE)
else()