From b992ae0fa4d792002ffae10a9ef893ef4fa42ac4 Mon Sep 17 00:00:00 2001 From: rtk0c Date: Fri, 1 Jul 2022 18:12:31 +0000 Subject: Convert hardcoding files in CMakeLists.txt to file(GLOB) git-svn-id: file:///home/arch/svn/epistmool/trunk@8 71f44415-077c-4ad7-a976-72ddbf76608f --- ui.qt/CMakeLists.txt | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) (limited to 'ui.qt/CMakeLists.txt') diff --git a/ui.qt/CMakeLists.txt b/ui.qt/CMakeLists.txt index c235133..f59962f 100644 --- a/ui.qt/CMakeLists.txt +++ b/ui.qt/CMakeLists.txt @@ -5,27 +5,20 @@ set(CMAKE_AUTOMOC ON) set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD_REQUIRED ON) -find_package(Qt6 6.2 COMPONENTS Network Widgets Quick REQUIRED) +find_package(Qt6 6.3 COMPONENTS Network Widgets Quick REQUIRED) +file(GLOB_RECURSE appEpistmoolUI_SRC_HPP_FILES src/*.hpp) +file(GLOB_RECURSE appEpistmoolUI_SRC_CPP_FILES src/*.cpp) qt_add_executable(appEpistmoolUI - source/main.cpp - source/fwd.hpp - source/DatabaseClient.hpp source/DatabaseClient.cpp - source/DatabaseServer.hpp source/DatabaseServer.cpp - source/KnowledgeFragment.hpp source/KnowledgeFragment.cpp - source/Keyword.hpp source/Keyword.cpp + ${appEpistmoolUI_SRC_HPP_FILES} + ${appEpistmoolUI_SRC_CPP_FILES} ) +file(GLOB_RECURSE appEpistmoolUI_QML_FILES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} qml/*.qml) qt_add_qml_module(appEpistmoolUI URI EpistmoolUI VERSION 1.0 - SOURCES - source/Document.hpp source/Document.cpp - QML_FILES - source/qml/MainWindow.qml - source/qml/Navigator.qml - source/qml/Document.qml - source/qml/GoToKnowledge.qml + QML_FILES ${appEpistmoolUI_QML_FILES} ) set_target_properties(appEpistmoolUI PROPERTIES @@ -36,7 +29,7 @@ set_target_properties(appEpistmoolUI PROPERTIES WIN32_EXECUTABLE TRUE ) -target_include_directories(appEpistmoolUI PUBLIC source) +target_include_directories(appEpistmoolUI PUBLIC src) target_compile_definitions(appEpistmoolUI PRIVATE $<$,$>:QT_QML_DEBUG> ) -- cgit v1.2.3-70-g09d2