summaryrefslogtreecommitdiffstats
path: root/examples/widgets/tools/completer/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/tools/completer/CMakeLists.txt')
-rw-r--r--examples/widgets/tools/completer/CMakeLists.txt21
1 files changed, 19 insertions, 2 deletions
diff --git a/examples/widgets/tools/completer/CMakeLists.txt b/examples/widgets/tools/completer/CMakeLists.txt
index f5df74ffc8..b60d38cfdc 100644
--- a/examples/widgets/tools/completer/CMakeLists.txt
+++ b/examples/widgets/tools/completer/CMakeLists.txt
@@ -9,20 +9,37 @@ set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)
-set(INSTALL_EXAMPLEDIR "examples")
+set(INSTALL_EXAMPLEDIR "examples/widgets/tools/completer")
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
find_package(Qt6 COMPONENTS Widgets)
add_qt_gui_executable(completer
- completer.qrc
fsmodel.cpp fsmodel.h
main.cpp
mainwindow.cpp mainwindow.h
)
target_link_libraries(completer PUBLIC
+ Qt::Core
+ Qt::Gui
Qt::Widgets
)
+
+# Resources:
+set(completer_resource_files
+ "resources/countries.txt"
+ "resources/wordlist.txt"
+)
+
+qt6_add_resources(completer "completer"
+ PREFIX
+ "/"
+ FILES
+ ${completer_resource_files}
+)
+
install(TARGETS completer
RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"