diff options
Diffstat (limited to 'examples/websockets/qmlwebsocketclient/CMakeLists.txt')
-rw-r--r-- | examples/websockets/qmlwebsocketclient/CMakeLists.txt | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/examples/websockets/qmlwebsocketclient/CMakeLists.txt b/examples/websockets/qmlwebsocketclient/CMakeLists.txt index 73da980..e720ace 100644 --- a/examples/websockets/qmlwebsocketclient/CMakeLists.txt +++ b/examples/websockets/qmlwebsocketclient/CMakeLists.txt @@ -1,28 +1,28 @@ -# Generated from qmlwebsocketclient.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause -cmake_minimum_required(VERSION 3.14) +cmake_minimum_required(VERSION 3.16) project(qmlwebsocketclient LANGUAGES CXX) -set(CMAKE_INCLUDE_CURRENT_DIR ON) - set(CMAKE_AUTOMOC ON) -set(CMAKE_AUTORCC ON) -set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/websockets/qmlwebsocketclient") -find_package(Qt6 COMPONENTS Core) -find_package(Qt6 COMPONENTS Gui) -find_package(Qt6 COMPONENTS Quick) -find_package(Qt6 COMPONENTS WebSockets) +find_package(Qt6 REQUIRED COMPONENTS Core Gui Quick WebSockets) -add_executable(qmlwebsocketclient +qt_add_executable(qmlwebsocketclient main.cpp ) + +set_target_properties(qmlwebsocketclient PROPERTIES + WIN32_EXECUTABLE TRUE + MACOSX_BUNDLE FALSE +) + target_link_libraries(qmlwebsocketclient PUBLIC Qt::Core Qt::Gui @@ -30,7 +30,6 @@ target_link_libraries(qmlwebsocketclient PUBLIC Qt::WebSockets ) - # Resources: set(data_resource_files "qml/qmlwebsocketclient/main.qml" |