diff options
Diffstat (limited to 'examples/gui')
-rw-r--r-- | examples/gui/CMakeLists.txt | 8 | ||||
-rw-r--r-- | examples/gui/analogclock/CMakeLists.txt | 33 | ||||
-rw-r--r-- | examples/gui/openglwindow/CMakeLists.txt | 32 | ||||
-rw-r--r-- | examples/gui/rasterwindow/CMakeLists.txt | 32 |
4 files changed, 105 insertions, 0 deletions
diff --git a/examples/gui/CMakeLists.txt b/examples/gui/CMakeLists.txt new file mode 100644 index 0000000000..7ae4c6bc6a --- /dev/null +++ b/examples/gui/CMakeLists.txt @@ -0,0 +1,8 @@ +# Generated from gui.pro. + +add_subdirectory(analogclock) +add_subdirectory(rasterwindow) + +if(TARGET Qt::Gui AND QT_FEATURE_opengl) + add_subdirectory(openglwindow) +endif() diff --git a/examples/gui/analogclock/CMakeLists.txt b/examples/gui/analogclock/CMakeLists.txt new file mode 100644 index 0000000000..2b727a48db --- /dev/null +++ b/examples/gui/analogclock/CMakeLists.txt @@ -0,0 +1,33 @@ +# Generated from analogclock.pro. + +cmake_minimum_required(VERSION 3.14) +project(analogclock LANGUAGES CXX) + +find_package(Qt6 COMPONENTS Widgets) # special case: add + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +add_qt_gui_executable(gui_analogclock # special case: renamed target + ../rasterwindow/rasterwindow.cpp ../rasterwindow/rasterwindow.h + main.cpp +) +target_include_directories(gui_analogclock PUBLIC + ../rasterwindow +) +# special case begin +target_link_libraries(gui_analogclock PUBLIC + Qt::Gui +) +# special case end + +install(TARGETS gui_analogclock + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/gui/openglwindow/CMakeLists.txt b/examples/gui/openglwindow/CMakeLists.txt new file mode 100644 index 0000000000..98fc40fd9a --- /dev/null +++ b/examples/gui/openglwindow/CMakeLists.txt @@ -0,0 +1,32 @@ +# Generated from openglwindow.pro. + +cmake_minimum_required(VERSION 3.14) +project(openglwindow LANGUAGES CXX) + +find_package(Qt6 COMPONENTS Widgets) # special case: add + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +add_qt_gui_executable(openglwindow + main.cpp + openglwindow.cpp openglwindow.h +) +target_include_directories(openglwindow PUBLIC + ${CMAKE_CURRENT_SOURCE_DIR} +) +# special case begin +target_link_libraries(openglwindow PUBLIC + Qt::Gui +) +# special case end +install(TARGETS openglwindow + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) diff --git a/examples/gui/rasterwindow/CMakeLists.txt b/examples/gui/rasterwindow/CMakeLists.txt new file mode 100644 index 0000000000..dd1bcf4f3b --- /dev/null +++ b/examples/gui/rasterwindow/CMakeLists.txt @@ -0,0 +1,32 @@ +# Generated from rasterwindow.pro. + +cmake_minimum_required(VERSION 3.14) +project(rasterwindow LANGUAGES CXX) + +find_package(Qt6 COMPONENTS Widgets) # special case: add + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +set(INSTALL_EXAMPLEDIR "examples") + +add_qt_gui_executable(rasterwindow + main.cpp + rasterwindow.cpp rasterwindow.h +) +target_include_directories(rasterwindow PUBLIC + ${CMAKE_CURRENT_SOURCE_DIR} +) +# special case begin +target_link_libraries(rasterwindow PUBLIC + Qt::Gui +) +# special case end +install(TARGETS rasterwindow + RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" + BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" + LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" +) |