summaryrefslogtreecommitdiffstats
path: root/examples/serialport/cenumerator/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'examples/serialport/cenumerator/CMakeLists.txt')
-rw-r--r--examples/serialport/cenumerator/CMakeLists.txt11
1 files changed, 4 insertions, 7 deletions
diff --git a/examples/serialport/cenumerator/CMakeLists.txt b/examples/serialport/cenumerator/CMakeLists.txt
index b3a4a1f4..1270e06f 100644
--- a/examples/serialport/cenumerator/CMakeLists.txt
+++ b/examples/serialport/cenumerator/CMakeLists.txt
@@ -1,28 +1,25 @@
cmake_minimum_required(VERSION 3.16)
project(cenumerator 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}/serialport/cenumerator")
-find_package(Qt6 COMPONENTS Core)
-find_package(Qt6 COMPONENTS SerialPort)
+find_package(Qt6 REQUIRED COMPONENTS Core SerialPort)
qt_add_executable(cenumerator
main.cpp
)
+
set_target_properties(cenumerator PROPERTIES
WIN32_EXECUTABLE FALSE
MACOSX_BUNDLE FALSE
)
+
target_link_libraries(cenumerator PRIVATE
Qt::Core
Qt::SerialPort