summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Kelly <stephen.kelly@kdab.com>2012-04-27 16:40:55 +0200
committerQt by Nokia <qt-info@nokia.com>2012-04-29 14:05:39 +0200
commit7fc8edf069c6fd01caa75185071c941cf1f688bc (patch)
tree7da7dc5319eda6700629aab335483eb13644286c
parenteddb8bc3e59f0065b12edefaf352f8aab886b921 (diff)
Forward the REQUIRED and QUIET arguments when finding dependencies.
Change-Id: I5d7c26f12a296ac3527575149978b18c5e9a4a67 Reviewed-by: Alexander Neundorf <neundorf@kde.org> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
-rw-r--r--mkspecs/cmake/Qt5BasicConfig.cmake.in11
1 files changed, 10 insertions, 1 deletions
diff --git a/mkspecs/cmake/Qt5BasicConfig.cmake.in b/mkspecs/cmake/Qt5BasicConfig.cmake.in
index a04d2b4d4e..fa62b3e9b1 100644
--- a/mkspecs/cmake/Qt5BasicConfig.cmake.in
+++ b/mkspecs/cmake/Qt5BasicConfig.cmake.in
@@ -19,9 +19,18 @@ set(Qt5$${CMAKE_MODULE_NAME}_COMPILE_DEFINITIONS QT_\${_CMAKE_MODULE_NAME_UPPER}
set(_Qt5_MODULE_DEPENDENCIES \"$${CMAKE_MODULE_DEPS}\")
+set(_Qt5$${CMAKE_MODULE_NAME}_FIND_DEPENDENCIES_REQUIRED)
+if (Qt5$${CMAKE_MODULE_NAME}_FIND_REQUIRED)
+ set(_Qt5$${CMAKE_MODULE_NAME}_FIND_DEPENDENCIES_REQUIRED REQUIRED)
+endif()
+set(_Qt5$${CMAKE_MODULE_NAME}_FIND_DEPENDENCIES_QUIET)
+if (Qt5$${CMAKE_MODULE_NAME}_FIND_QUIETLY)
+ set(_Qt5$${CMAKE_MODULE_NAME}_DEPENDENCIES_FIND_QUIET QUIET)
+endif()
+
foreach(_module_dep ${_Qt5_MODULE_DEPENDENCIES})
if (NOT Qt5${_module_dep}_FOUND)
- find_package(Qt5${_module_dep} REQUIRED)
+ find_package(Qt5${_module_dep} ${_Qt5$${CMAKE_MODULE_NAME}_DEPENDENCIES_FIND_QUIET} ${_Qt5$${CMAKE_MODULE_NAME}_FIND_DEPENDENCIES_REQUIRED})
endif()
list(APPEND Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS ${Qt5${_module_dep}_INCLUDE_DIRS})
list(APPEND Qt5$${CMAKE_MODULE_NAME}_DEFINITIONS ${Qt5${_module_dep}_DEFINITIONS})