aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEd Cooke <[email protected]>2024-10-03 10:57:44 +0200
committerQt Cherry-pick Bot <[email protected]>2024-10-10 23:12:41 +0000
commit32ccfe1879139af2c56f8f8ac23229b836dbfff0 (patch)
tree99af0af0355bc1817db41aafd3d0375722f3d65e
parent7d9189a3bc6ef8ba0886267e4054fc488cd96992 (diff)
Clean up CMake output from wearable example when building qtdeclarative
Remove the two CMake warnings from the CMake output when building QtDeclarative. The warnings come from a missing optional dependency for the wearable example. Pick-to: 6.7 Change-Id: Id9bf2ccc4d6db2ea44618b2119c69c89e271a870 Reviewed-by: Matthias Rauter <[email protected]> (cherry picked from commit d55134197a305b46b75e6df2e331a4f0fc85a566) Reviewed-by: Qt Cherry-pick Bot <[email protected]>
-rw-r--r--examples/quickcontrols/wearable/CMakeLists.txt9
1 files changed, 5 insertions, 4 deletions
diff --git a/examples/quickcontrols/wearable/CMakeLists.txt b/examples/quickcontrols/wearable/CMakeLists.txt
index eb3c17c3e9..d13565baf5 100644
--- a/examples/quickcontrols/wearable/CMakeLists.txt
+++ b/examples/quickcontrols/wearable/CMakeLists.txt
@@ -6,7 +6,8 @@ project(wearableexample VERSION 1 LANGUAGES CXX)
set(CMAKE_AUTOMOC ON)
-find_package(Qt6 REQUIRED COMPONENTS Core Gui Quick QuickControls2 OPTIONAL_COMPONENTS Positioning Location)
+find_package(Qt6 REQUIRED COMPONENTS Core Gui Quick QuickControls2)
+find_package(Qt6 QUIET OPTIONAL_COMPONENTS Positioning Location)
qt_standard_project_setup()
@@ -32,9 +33,9 @@ if(TARGET Qt6::Positioning)
endif()
if(TARGET Qt6::Location)
-target_link_libraries(wearableexample PUBLIC
- Qt6::Location
-)
+ target_link_libraries(wearableexample PUBLIC
+ Qt6::Location
+ )
endif()
if(UNIX AND NOT APPLE AND CMAKE_CROSSCOMPILING)