diff options
-rw-r--r-- | CMakeLists.txt | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 55d88b2..6c4afdd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,10 +11,16 @@ project(QtRemoteObjects LANGUAGES CXX C ) -find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals Core Network) -find_package(Qt6 ${PROJECT_VERSION} CONFIG OPTIONAL_COMPONENTS Gui Widgets Quick QuickTest Bluetooth WebSockets) +find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS BuildInternals) + +# This should be called as early as possible, just after find_package(BuildInternals) where it is +# defined. qt_internal_project_setup() +find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS Core Network) +find_package(Qt6 ${PROJECT_VERSION} CONFIG OPTIONAL_COMPONENTS Gui Widgets Quick QuickTest Bluetooth + WebSockets) + if(NOT TARGET Qt::Network) message(NOTICE "Skipping the build as the condition \"TARGET Qt::Network\" is not met.") return() |