summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2019-09-18 17:14:44 +0200
committerJohan Helsing <johan.helsing@qt.io>2019-11-26 11:29:29 +0000
commit12058b161e5f0d6f76523dc831acc8bdbc027fec (patch)
treeee6e6bf1c2730671544ca799b7ad414abcf17646 /examples
parentbad0b76e5a7ed73b685848a8fd6a3555b754a81a (diff)
Initial CMake port
The client, compositor, tests, plugins and examples now build. There are still a few minor issues: - The protocol source generation is a bit hacky. - The tests for checking if building CMake projects don't work anymore as they have Qt 5 specific code. They have just been commented out for now. Fixes: QTBUG-78177 Change-Id: Ie17cb05f0cdbd5b098970ce765adaeccf61a8fde Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CMake Build Bot
Diffstat (limited to 'examples')
-rw-r--r--examples/CMakeLists.txt7
-rw-r--r--examples/wayland/.prev_CMakeLists.txt24
-rw-r--r--examples/wayland/CMakeLists.txt26
-rw-r--r--examples/wayland/custom-extension/CMakeLists.txt5
-rw-r--r--examples/wayland/custom-extension/compositor/CMakeLists.txt54
-rw-r--r--examples/wayland/custom-extension/cpp-client/CMakeLists.txt41
-rw-r--r--examples/wayland/custom-extension/qml-client/CMakeLists.txt58
-rw-r--r--examples/wayland/hwlayer-compositor/CMakeLists.txt44
-rw-r--r--examples/wayland/ivi-compositor/CMakeLists.txt44
-rw-r--r--examples/wayland/minimal-cpp/.prev_CMakeLists.txt39
-rw-r--r--examples/wayland/minimal-cpp/CMakeLists.txt39
-rw-r--r--examples/wayland/minimal-qml/CMakeLists.txt44
-rw-r--r--examples/wayland/multi-output/CMakeLists.txt48
-rw-r--r--examples/wayland/multi-screen/CMakeLists.txt46
-rw-r--r--examples/wayland/overview-compositor/CMakeLists.txt44
-rw-r--r--examples/wayland/pure-qml/CMakeLists.txt48
-rw-r--r--examples/wayland/qwindow-compositor/.prev_CMakeLists.txt55
-rw-r--r--examples/wayland/qwindow-compositor/CMakeLists.txt55
-rw-r--r--examples/wayland/server-buffer/CMakeLists.txt4
-rw-r--r--examples/wayland/server-buffer/compositor/CMakeLists.txt58
-rw-r--r--examples/wayland/server-buffer/cpp-client/CMakeLists.txt42
-rw-r--r--examples/wayland/server-side-decoration/CMakeLists.txt44
-rw-r--r--examples/wayland/spanning-screens/CMakeLists.txt44
-rw-r--r--examples/wayland/texture-sharing/CMakeLists.txt4
-rw-r--r--examples/wayland/texture-sharing/custom-compositor/CMakeLists.txt54
-rw-r--r--examples/wayland/texture-sharing/qml-client/CMakeLists.txt44
26 files changed, 1015 insertions, 0 deletions
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
new file mode 100644
index 000000000..c1557e889
--- /dev/null
+++ b/examples/CMakeLists.txt
@@ -0,0 +1,7 @@
+# Generated from examples.pro.
+
+qt_examples_build_begin()
+
+add_subdirectory(wayland)
+
+qt_examples_build_end()
diff --git a/examples/wayland/.prev_CMakeLists.txt b/examples/wayland/.prev_CMakeLists.txt
new file mode 100644
index 000000000..435734b7c
--- /dev/null
+++ b/examples/wayland/.prev_CMakeLists.txt
@@ -0,0 +1,24 @@
+# Generated from wayland.pro.
+
+if(QT_FEATURE_opengl)
+ add_subdirectory(qwindow-compositor)
+ add_subdirectory(minimal-cpp)
+endif()
+if(TARGET Qt::Quick)
+ add_subdirectory(minimal-qml)
+ add_subdirectory(spanning-screens)
+ add_subdirectory(pure-qml)
+ add_subdirectory(multi-output)
+ add_subdirectory(multi-screen)
+ add_subdirectory(overview-compositor)
+ add_subdirectory(ivi-compositor)
+ add_subdirectory(server-side-decoration)
+ add_subdirectory(hwlayer-compositor)
+endif()
+if(TARGET Qt::Quick AND TARGET Qt::WaylandClient)
+ add_subdirectory(custom-extension)
+endif()
+if(QT_FEATURE_opengl AND TARGET Qt::Quick AND TARGET Qt::WaylandClient)
+ add_subdirectory(server-buffer)
+ add_subdirectory(texture-sharing)
+endif()
diff --git a/examples/wayland/CMakeLists.txt b/examples/wayland/CMakeLists.txt
new file mode 100644
index 000000000..9470d3a1d
--- /dev/null
+++ b/examples/wayland/CMakeLists.txt
@@ -0,0 +1,26 @@
+# Generated from wayland.pro.
+
+if(QT_FEATURE_wayland_server) # special case
+if(QT_FEATURE_opengl)
+ add_subdirectory(qwindow-compositor)
+ add_subdirectory(minimal-cpp)
+endif()
+if(TARGET Qt::Quick)
+ add_subdirectory(minimal-qml)
+ add_subdirectory(spanning-screens)
+ add_subdirectory(pure-qml)
+ add_subdirectory(multi-output)
+ add_subdirectory(multi-screen)
+ add_subdirectory(overview-compositor)
+ add_subdirectory(ivi-compositor)
+ add_subdirectory(server-side-decoration)
+ add_subdirectory(hwlayer-compositor)
+endif()
+if(TARGET Qt::Quick AND TARGET Qt::WaylandClient)
+ add_subdirectory(custom-extension)
+endif()
+if(QT_FEATURE_opengl AND TARGET Qt::Quick AND TARGET Qt::WaylandClient)
+ add_subdirectory(server-buffer)
+ add_subdirectory(texture-sharing)
+endif()
+endif() # special case
diff --git a/examples/wayland/custom-extension/CMakeLists.txt b/examples/wayland/custom-extension/CMakeLists.txt
new file mode 100644
index 000000000..408a9174e
--- /dev/null
+++ b/examples/wayland/custom-extension/CMakeLists.txt
@@ -0,0 +1,5 @@
+# Generated from custom-extension.pro.
+
+add_subdirectory(qml-client)
+add_subdirectory(compositor)
+add_subdirectory(cpp-client)
diff --git a/examples/wayland/custom-extension/compositor/CMakeLists.txt b/examples/wayland/custom-extension/compositor/CMakeLists.txt
new file mode 100644
index 000000000..6727e6ad4
--- /dev/null
+++ b/examples/wayland/custom-extension/compositor/CMakeLists.txt
@@ -0,0 +1,54 @@
+# Generated from compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(custom-extension-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/custom-extension/compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(custom-extension-compositor
+ customextension.cpp customextension.h
+ main.cpp
+)
+
+qt6_generate_wayland_protocol_server_sources(custom-extension-compositor
+ FILES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../protocol/custom.xml
+)
+target_link_libraries(custom-extension-compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+ Qt::WaylandCompositor
+)
+
+
+# Resources:
+set(compositor_resource_files
+ "images/background.png"
+ "qml/Screen.qml"
+ "qml/main.qml"
+)
+
+qt6_add_resources(custom-extension-compositor "compositor"
+ PREFIX
+ "/"
+ FILES
+ ${compositor_resource_files}
+)
+
+install(TARGETS custom-extension-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/custom-extension/cpp-client/CMakeLists.txt b/examples/wayland/custom-extension/cpp-client/CMakeLists.txt
new file mode 100644
index 000000000..8f3708a19
--- /dev/null
+++ b/examples/wayland/custom-extension/cpp-client/CMakeLists.txt
@@ -0,0 +1,41 @@
+# Generated from cpp-client.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(custom-extension-cpp-client LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/custom-extension/cpp-client")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandClient)
+
+add_qt_gui_executable(custom-extension-cpp-client
+ ../client-common/customextension.cpp ../client-common/customextension.h
+ main.cpp
+)
+
+qt6_generate_wayland_protocol_client_sources(custom-extension-cpp-client
+ FILES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../protocol/custom.xml
+)
+target_link_libraries(custom-extension-cpp-client PRIVATE
+ Qt::GuiPrivate
+)
+
+target_link_libraries(custom-extension-cpp-client PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandClient
+)
+
+install(TARGETS custom-extension-cpp-client
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/custom-extension/qml-client/CMakeLists.txt b/examples/wayland/custom-extension/qml-client/CMakeLists.txt
new file mode 100644
index 000000000..f490b507d
--- /dev/null
+++ b/examples/wayland/custom-extension/qml-client/CMakeLists.txt
@@ -0,0 +1,58 @@
+# Generated from qml-client.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(custom-extension-qml-client LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/custom-extension/qml-client")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+find_package(Qt6 COMPONENTS Quick)
+find_package(Qt6 COMPONENTS WaylandClient)
+
+add_qt_gui_executable(custom-extension-qml-client
+ ../client-common/customextension.cpp ../client-common/customextension.h
+ main.cpp
+)
+
+qt6_generate_wayland_protocol_client_sources(custom-extension-qml-client
+ FILES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../protocol/custom.xml
+)
+target_link_libraries(custom-extension-qml-client PRIVATE
+ Qt::GuiPrivate
+)
+
+target_link_libraries(custom-extension-qml-client PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+ Qt::Quick
+ Qt::WaylandClient
+)
+
+
+# Resources:
+set(qml_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(custom-extension-qml-client "qml"
+ PREFIX
+ "/"
+ FILES
+ ${qml_resource_files}
+)
+
+install(TARGETS custom-extension-qml-client
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/hwlayer-compositor/CMakeLists.txt b/examples/wayland/hwlayer-compositor/CMakeLists.txt
new file mode 100644
index 000000000..5d2d61e91
--- /dev/null
+++ b/examples/wayland/hwlayer-compositor/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from hwlayer-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(hwlayer-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/hwlayer-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(hwlayer-compositor
+ main.cpp
+)
+target_link_libraries(hwlayer-compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(hwlayer-compositor_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(hwlayer-compositor "hwlayer-compositor"
+ PREFIX
+ "/"
+ FILES
+ ${hwlayer-compositor_resource_files}
+)
+
+install(TARGETS hwlayer-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/ivi-compositor/CMakeLists.txt b/examples/wayland/ivi-compositor/CMakeLists.txt
new file mode 100644
index 000000000..31555531c
--- /dev/null
+++ b/examples/wayland/ivi-compositor/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from ivi-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(ivi-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/ivi-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(ivi-compositor
+ main.cpp
+)
+target_link_libraries(ivi-compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(ivi-compositor_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(ivi-compositor "ivi-compositor"
+ PREFIX
+ "/"
+ FILES
+ ${ivi-compositor_resource_files}
+)
+
+install(TARGETS ivi-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/minimal-cpp/.prev_CMakeLists.txt b/examples/wayland/minimal-cpp/.prev_CMakeLists.txt
new file mode 100644
index 000000000..a278fce0c
--- /dev/null
+++ b/examples/wayland/minimal-cpp/.prev_CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from minimal-cpp.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(minimal-cpp LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/minimal-cpp")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(minimal-cpp
+ compositor.cpp compositor.h
+ main.cpp
+ window.cpp window.h
+)
+target_include_directories(minimal-cpp PUBLIC
+ ../../include
+)
+
+target_link_libraries(minimal-cpp PUBLIC
+ # Remove: L
+ ../../lib
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandCompositor
+)
+
+install(TARGETS minimal-cpp
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/minimal-cpp/CMakeLists.txt b/examples/wayland/minimal-cpp/CMakeLists.txt
new file mode 100644
index 000000000..a812865b9
--- /dev/null
+++ b/examples/wayland/minimal-cpp/CMakeLists.txt
@@ -0,0 +1,39 @@
+# Generated from minimal-cpp.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(minimal-cpp LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/minimal-cpp")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(minimal-cpp
+ compositor.cpp compositor.h
+ main.cpp
+ window.cpp window.h
+)
+target_include_directories(minimal-cpp PUBLIC
+ ../../include
+)
+
+target_link_libraries(minimal-cpp PUBLIC
+ # Remove: L
+ #../../lib # special case
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandCompositor
+)
+
+install(TARGETS minimal-cpp
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/minimal-qml/CMakeLists.txt b/examples/wayland/minimal-qml/CMakeLists.txt
new file mode 100644
index 000000000..fd8c4c68b
--- /dev/null
+++ b/examples/wayland/minimal-qml/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from minimal-qml.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(minimal-qml LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/minimal-qml")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(minimal-qml
+ main.cpp
+)
+target_link_libraries(minimal-qml PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(minimal-qml_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(minimal-qml "minimal-qml"
+ PREFIX
+ "/"
+ FILES
+ ${minimal-qml_resource_files}
+)
+
+install(TARGETS minimal-qml
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/multi-output/CMakeLists.txt b/examples/wayland/multi-output/CMakeLists.txt
new file mode 100644
index 000000000..5e3f5b45f
--- /dev/null
+++ b/examples/wayland/multi-output/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from multi-output.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multi-output LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/multi-output")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(multi-output
+ main.cpp
+)
+target_link_libraries(multi-output PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(multi-output_resource_files
+ "images/background.jpg"
+ "qml/GridScreen.qml"
+ "qml/ShellChrome.qml"
+ "qml/ShellScreen.qml"
+ "qml/main.qml"
+)
+
+qt6_add_resources(multi-output "multi-output"
+ PREFIX
+ "/"
+ FILES
+ ${multi-output_resource_files}
+)
+
+install(TARGETS multi-output
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/multi-screen/CMakeLists.txt b/examples/wayland/multi-screen/CMakeLists.txt
new file mode 100644
index 000000000..ce38ddf66
--- /dev/null
+++ b/examples/wayland/multi-screen/CMakeLists.txt
@@ -0,0 +1,46 @@
+# Generated from multi-screen.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(multi-screen LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/multi-screen")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(multi-screen
+ main.cpp
+)
+target_link_libraries(multi-screen PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(multi-screen_resource_files
+ "qml/Chrome.qml"
+ "qml/Screen.qml"
+ "qml/main.qml"
+)
+
+qt6_add_resources(multi-screen "multi-screen"
+ PREFIX
+ "/"
+ FILES
+ ${multi-screen_resource_files}
+)
+
+install(TARGETS multi-screen
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/overview-compositor/CMakeLists.txt b/examples/wayland/overview-compositor/CMakeLists.txt
new file mode 100644
index 000000000..8e32b730c
--- /dev/null
+++ b/examples/wayland/overview-compositor/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from overview-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(overview-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/overview-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(overview-compositor
+ main.cpp
+)
+target_link_libraries(overview-compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(overview-compositor_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(overview-compositor "overview-compositor"
+ PREFIX
+ "/"
+ FILES
+ ${overview-compositor_resource_files}
+)
+
+install(TARGETS overview-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/pure-qml/CMakeLists.txt b/examples/wayland/pure-qml/CMakeLists.txt
new file mode 100644
index 000000000..af504bfbe
--- /dev/null
+++ b/examples/wayland/pure-qml/CMakeLists.txt
@@ -0,0 +1,48 @@
+# Generated from pure-qml.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(pure-qml LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/pure-qml")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(pure-qml
+ main.cpp
+)
+target_link_libraries(pure-qml PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(pure-qml_resource_files
+ "images/background.jpg"
+ "qml/Chrome.qml"
+ "qml/Keyboard.qml"
+ "qml/Screen.qml"
+ "qml/main.qml"
+)
+
+qt6_add_resources(pure-qml "pure-qml"
+ PREFIX
+ "/"
+ FILES
+ ${pure-qml_resource_files}
+)
+
+install(TARGETS pure-qml
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/qwindow-compositor/.prev_CMakeLists.txt b/examples/wayland/qwindow-compositor/.prev_CMakeLists.txt
new file mode 100644
index 000000000..048ea184f
--- /dev/null
+++ b/examples/wayland/qwindow-compositor/.prev_CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from qwindow-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qwindow-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/qwindow-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(qwindow-compositor
+ compositor.cpp compositor.h
+ main.cpp
+ window.cpp window.h
+)
+target_include_directories(qwindow-compositor PUBLIC
+ ../../include
+)
+
+target_link_libraries(qwindow-compositor PUBLIC
+ # Remove: L
+ ../../lib
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandCompositor
+)
+
+
+# Resources:
+set_source_files_properties("../pure-qml/images/background.jpg"
+ PROPERTIES QT_RESOURCE_ALIAS "background.jpg"
+)
+set(qwindow-compositor_resource_files
+ "../pure-qml/images/background.jpg"
+)
+
+qt6_add_resources(qwindow-compositor "qwindow-compositor"
+ PREFIX
+ "/"
+ FILES
+ ${qwindow-compositor_resource_files}
+)
+
+install(TARGETS qwindow-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/qwindow-compositor/CMakeLists.txt b/examples/wayland/qwindow-compositor/CMakeLists.txt
new file mode 100644
index 000000000..1d1201bae
--- /dev/null
+++ b/examples/wayland/qwindow-compositor/CMakeLists.txt
@@ -0,0 +1,55 @@
+# Generated from qwindow-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qwindow-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/qwindow-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(qwindow-compositor
+ compositor.cpp compositor.h
+ main.cpp
+ window.cpp window.h
+)
+target_include_directories(qwindow-compositor PUBLIC
+ ../../include
+)
+
+target_link_libraries(qwindow-compositor PUBLIC
+ # Remove: L
+ #../../lib # special case
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandCompositor
+)
+
+
+# Resources:
+set_source_files_properties("../pure-qml/images/background.jpg"
+ PROPERTIES QT_RESOURCE_ALIAS "background.jpg"
+)
+set(qwindow-compositor_resource_files
+ "../pure-qml/images/background.jpg"
+)
+
+qt6_add_resources(qwindow-compositor "qwindow-compositor"
+ PREFIX
+ "/"
+ FILES
+ ${qwindow-compositor_resource_files}
+)
+
+install(TARGETS qwindow-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/server-buffer/CMakeLists.txt b/examples/wayland/server-buffer/CMakeLists.txt
new file mode 100644
index 000000000..ad4115116
--- /dev/null
+++ b/examples/wayland/server-buffer/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from server-buffer.pro.
+
+add_subdirectory(cpp-client)
+add_subdirectory(compositor)
diff --git a/examples/wayland/server-buffer/compositor/CMakeLists.txt b/examples/wayland/server-buffer/compositor/CMakeLists.txt
new file mode 100644
index 000000000..dc47cfe0c
--- /dev/null
+++ b/examples/wayland/server-buffer/compositor/CMakeLists.txt
@@ -0,0 +1,58 @@
+# Generated from compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/server-buffer/compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(compositor
+ main.cpp
+ sharebufferextension.cpp sharebufferextension.h
+)
+
+qt6_generate_wayland_protocol_server_sources(compositor
+ FILES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../share-buffer.xml
+)
+target_link_libraries(compositor PRIVATE
+ Qt::WaylandCompositorPrivate
+)
+
+target_link_libraries(compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+ Qt::WaylandCompositor
+)
+
+
+# Resources:
+set(compositor_resource_files
+ "images/Siberischer_tiger_de_edit02.jpg"
+ "images/background.png"
+ "qml/main.qml"
+)
+
+qt6_add_resources(compositor "compositor"
+ PREFIX
+ "/"
+ FILES
+ ${compositor_resource_files}
+)
+
+install(TARGETS compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/server-buffer/cpp-client/CMakeLists.txt b/examples/wayland/server-buffer/cpp-client/CMakeLists.txt
new file mode 100644
index 000000000..5b4c1e95c
--- /dev/null
+++ b/examples/wayland/server-buffer/cpp-client/CMakeLists.txt
@@ -0,0 +1,42 @@
+# Generated from cpp-client.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(server-buffer-cpp-client LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/server-buffer/cpp-client")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS WaylandClient)
+
+add_qt_gui_executable(server-buffer-cpp-client
+ main.cpp
+ sharebufferextension.cpp sharebufferextension.h
+)
+
+qt6_generate_wayland_protocol_client_sources(server-buffer-cpp-client
+ FILES
+ ${CMAKE_CURRENT_SOURCE_DIR}/../share-buffer.xml
+)
+target_link_libraries(server-buffer-cpp-client PRIVATE
+ Qt::GuiPrivate
+ Qt::WaylandClientPrivate
+)
+
+target_link_libraries(server-buffer-cpp-client PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::WaylandClient
+)
+
+install(TARGETS server-buffer-cpp-client
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/server-side-decoration/CMakeLists.txt b/examples/wayland/server-side-decoration/CMakeLists.txt
new file mode 100644
index 000000000..299404aba
--- /dev/null
+++ b/examples/wayland/server-side-decoration/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from server-side-decoration.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(server-side-decoration LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/server-side-decoration")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(server-side-decoration
+ main.cpp
+)
+target_link_libraries(server-side-decoration PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(server-side-decoration_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(server-side-decoration "server-side-decoration"
+ PREFIX
+ "/"
+ FILES
+ ${server-side-decoration_resource_files}
+)
+
+install(TARGETS server-side-decoration
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/spanning-screens/CMakeLists.txt b/examples/wayland/spanning-screens/CMakeLists.txt
new file mode 100644
index 000000000..510d7aec0
--- /dev/null
+++ b/examples/wayland/spanning-screens/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from spanning-screens.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(spanning-screens LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/spanning-screens")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+
+add_qt_gui_executable(spanning-screens
+ main.cpp
+)
+target_link_libraries(spanning-screens PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+)
+
+
+# Resources:
+set(spanning-screens_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(spanning-screens "spanning-screens"
+ PREFIX
+ "/"
+ FILES
+ ${spanning-screens_resource_files}
+)
+
+install(TARGETS spanning-screens
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/texture-sharing/CMakeLists.txt b/examples/wayland/texture-sharing/CMakeLists.txt
new file mode 100644
index 000000000..bf6a7cbf9
--- /dev/null
+++ b/examples/wayland/texture-sharing/CMakeLists.txt
@@ -0,0 +1,4 @@
+# Generated from texture-sharing.pro.
+
+add_subdirectory(qml-client)
+add_subdirectory(custom-compositor)
diff --git a/examples/wayland/texture-sharing/custom-compositor/CMakeLists.txt b/examples/wayland/texture-sharing/custom-compositor/CMakeLists.txt
new file mode 100644
index 000000000..ea56f9c3f
--- /dev/null
+++ b/examples/wayland/texture-sharing/custom-compositor/CMakeLists.txt
@@ -0,0 +1,54 @@
+# Generated from custom-compositor.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(texture-sharing-custom-compositor LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/texture-sharing/custom-compositor")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Qml)
+find_package(Qt6 COMPONENTS WaylandCompositor)
+
+add_qt_gui_executable(texture-sharing-custom-compositor
+ main.cpp
+)
+target_link_libraries(texture-sharing-custom-compositor PRIVATE
+ Qt::WaylandCompositorPrivate
+)
+
+target_link_libraries(texture-sharing-custom-compositor PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Qml
+ Qt::WaylandCompositor
+)
+
+
+# Resources:
+set(compositor_resource_files
+ "images/background.png"
+ "images/car.ktx"
+ "images/qt4.astc"
+ "images/qt_logo.png"
+ "qml/main.qml"
+)
+
+qt6_add_resources(texture-sharing-custom-compositor "compositor"
+ PREFIX
+ "/"
+ FILES
+ ${compositor_resource_files}
+)
+
+install(TARGETS texture-sharing-custom-compositor
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)
diff --git a/examples/wayland/texture-sharing/qml-client/CMakeLists.txt b/examples/wayland/texture-sharing/qml-client/CMakeLists.txt
new file mode 100644
index 000000000..ec2e02ee4
--- /dev/null
+++ b/examples/wayland/texture-sharing/qml-client/CMakeLists.txt
@@ -0,0 +1,44 @@
+# Generated from qml-client.pro.
+
+cmake_minimum_required(VERSION 3.14)
+project(qml-client LANGUAGES CXX)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_AUTORCC ON)
+set(CMAKE_AUTOUIC ON)
+
+set(INSTALL_EXAMPLEDIR "examples/wayland/texture-sharing/qml-client")
+
+find_package(Qt6 COMPONENTS Core)
+find_package(Qt6 COMPONENTS Gui)
+find_package(Qt6 COMPONENTS Quick)
+
+add_qt_gui_executable(qml-client
+ main.cpp
+)
+target_link_libraries(qml-client PUBLIC
+ Qt::Core
+ Qt::Gui
+ Qt::Quick
+)
+
+
+# Resources:
+set(qml-client_resource_files
+ "main.qml"
+)
+
+qt6_add_resources(qml-client "qml-client"
+ PREFIX
+ "/"
+ FILES
+ ${qml-client_resource_files}
+)
+
+install(TARGETS qml-client
+ RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}"
+ BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}"
+ LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}"
+)