diff options
Diffstat (limited to 'examples/websockets/qmlwebsocketserver/CMakeLists.txt')
-rw-r--r-- | examples/websockets/qmlwebsocketserver/CMakeLists.txt | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/examples/websockets/qmlwebsocketserver/CMakeLists.txt b/examples/websockets/qmlwebsocketserver/CMakeLists.txt index cd6fec7..9a6272f 100644 --- a/examples/websockets/qmlwebsocketserver/CMakeLists.txt +++ b/examples/websockets/qmlwebsocketserver/CMakeLists.txt @@ -1,28 +1,28 @@ -# Generated from qmlwebsocketserver.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(qmlwebsocketserver 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/qmlwebsocketserver") -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(qmlwebsocketserver +qt_add_executable(qmlwebsocketserver main.cpp ) + +set_target_properties(qmlwebsocketserver PROPERTIES + WIN32_EXECUTABLE TRUE + MACOSX_BUNDLE FALSE +) + target_link_libraries(qmlwebsocketserver PUBLIC Qt::Core Qt::Gui @@ -30,7 +30,6 @@ target_link_libraries(qmlwebsocketserver PUBLIC Qt::WebSockets ) - # Resources: set(data_resource_files "qml/qmlwebsocketserver/main.qml" |