Warning, /plasma/kwin/src/wayland/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 add_subdirectory(tools)
0002 
0003 if (BUILD_TESTING)
0004     add_subdirectory(autotests)
0005     add_subdirectory(tests)
0006 endif()
0007 
0008 # CMake has a known bug where target_source() doesn't work as expected with files generated
0009 # in a directory other than the one where the target is defined. It should be fixed in 3.20.
0010 add_library(WaylandProtocols_xml OBJECT)
0011 set_property(TARGET WaylandProtocols_xml PROPERTY POSITION_INDEPENDENT_CODE ON)
0012 target_link_libraries(WaylandProtocols_xml Qt::Core Wayland::Server)
0013 target_link_libraries(kwin WaylandProtocols_xml)
0014 
0015 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0016     PROTOCOL ${Wayland_DATADIR}/wayland.xml
0017     BASENAME wayland
0018 )
0019 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0020     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/kde-output-device-v2.xml
0021     BASENAME kde-output-device-v2
0022 )
0023 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0024     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/kde-output-management-v2.xml
0025     BASENAME kde-output-management-v2
0026 )
0027 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0028     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/plasma-shell.xml
0029     BASENAME plasma-shell
0030 )
0031 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0032     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/plasma-virtual-desktop.xml
0033     BASENAME org-kde-plasma-virtual-desktop
0034 )
0035 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0036     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/plasma-window-management.xml
0037     BASENAME plasma-window-management
0038 )
0039 ecm_add_wayland_server_protocol(WaylandProtocols_xml
0040     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/surface-extension.xml
0041     BASENAME qt-surface-extension
0042 )
0043 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0044     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/idle.xml
0045     BASENAME idle
0046 )
0047 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0048     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/fake-input.xml
0049     BASENAME fake-input
0050 )
0051 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0052     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/shadow.xml
0053     BASENAME shadow
0054 )
0055 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0056     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/dpms.xml
0057     BASENAME dpms
0058 )
0059 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0060     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/blur.xml
0061     BASENAME blur
0062 )
0063 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0064     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/contrast.xml
0065     BASENAME contrast
0066 )
0067 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0068     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/relative-pointer/relative-pointer-unstable-v1.xml
0069     BASENAME relative-pointer-unstable-v1
0070 )
0071 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0072     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/slide.xml
0073     BASENAME slide
0074 )
0075 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0076     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/server-decoration.xml
0077     BASENAME server-decoration
0078 )
0079 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0080     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/text-input/text-input-unstable-v1.xml
0081     BASENAME text-input-unstable-v1
0082 )
0083 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0084     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/text-input-unstable-v2.xml
0085     BASENAME text-input-unstable-v2
0086 )
0087 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0088     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/text-input/text-input-unstable-v3.xml
0089     BASENAME text-input-unstable-v3
0090 )
0091 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0092     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/pointer-gestures/pointer-gestures-unstable-v1.xml
0093     BASENAME pointer-gestures-unstable-v1
0094 )
0095 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0096     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/pointer-constraints/pointer-constraints-unstable-v1.xml
0097     BASENAME pointer-constraints-unstable-v1
0098 )
0099 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0100     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/xdg-foreign/xdg-foreign-unstable-v2.xml
0101     BASENAME xdg-foreign-unstable-v2
0102 )
0103 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0104     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/idle-inhibit/idle-inhibit-unstable-v1.xml
0105     BASENAME idle-inhibit-unstable-v1
0106 )
0107 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0108     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/appmenu.xml
0109     BASENAME appmenu
0110 )
0111 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0112     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/server-decoration-palette.xml
0113     BASENAME server-decoration-palette
0114 )
0115 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0116     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/xdg-output/xdg-output-unstable-v1.xml
0117     BASENAME xdg-output-unstable-v1
0118 )
0119 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0120     PROTOCOL ${WaylandProtocols_DATADIR}/stable/xdg-shell/xdg-shell.xml
0121     BASENAME xdg-shell
0122 )
0123 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0124     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/xdg-decoration/xdg-decoration-unstable-v1.xml
0125     BASENAME xdg-decoration-unstable-v1
0126 )
0127 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0128     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/keystate.xml
0129     BASENAME keystate
0130 )
0131 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0132     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/linux-dmabuf/linux-dmabuf-unstable-v1.xml
0133     BASENAME linux-dmabuf-unstable-v1
0134 )
0135 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0136     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/tablet/tablet-unstable-v2.xml
0137     BASENAME tablet-unstable-v2
0138 )
0139 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0140     PROTOCOL ${PROJECT_SOURCE_DIR}/src/wayland/protocols/wlr-data-control-unstable-v1.xml
0141     BASENAME wlr-data-control-unstable-v1
0142 )
0143 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0144     PROTOCOL ${PROJECT_SOURCE_DIR}/src/wayland/protocols/wlr-layer-shell-unstable-v1.xml
0145     BASENAME wlr-layer-shell-unstable-v1
0146 )
0147 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0148     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/keyboard-shortcuts-inhibit/keyboard-shortcuts-inhibit-unstable-v1.xml
0149     BASENAME keyboard-shortcuts-inhibit-unstable-v1
0150 )
0151 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0152     PROTOCOL ${WaylandProtocols_DATADIR}/stable/viewporter/viewporter.xml
0153     BASENAME viewporter
0154 )
0155 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0156     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/primary-selection/primary-selection-unstable-v1.xml
0157     BASENAME wp-primary-selection-unstable-v1
0158 )
0159 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0160     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/zkde-screencast-unstable-v1.xml
0161     BASENAME zkde-screencast-unstable-v1
0162 )
0163 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0164     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/input-method/input-method-unstable-v1.xml
0165     BASENAME input-method-unstable-v1
0166 )
0167 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0168     PROTOCOL ${WaylandProtocols_DATADIR}/staging/xdg-activation/xdg-activation-v1.xml
0169     BASENAME xdg-activation-v1
0170 )
0171 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0172     PROTOCOL ${WaylandProtocols_DATADIR}/staging/drm-lease/drm-lease-v1.xml
0173     BASENAME drm-lease-v1
0174 )
0175 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0176     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/kde-lockscreen-overlay-v1.xml
0177     BASENAME kde-lockscreen-overlay-v1
0178 )
0179 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0180     PROTOCOL ${WaylandProtocols_DATADIR}/staging/ext-idle-notify/ext-idle-notify-v1.xml
0181     BASENAME ext-idle-notify-v1
0182 )
0183 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0184     PROTOCOL ${WaylandProtocols_DATADIR}/staging/tearing-control/tearing-control-v1.xml
0185     BASENAME tearing-control-v1
0186 )
0187 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0188     PROTOCOL ${WaylandProtocols_DATADIR}/unstable/xwayland-keyboard-grab/xwayland-keyboard-grab-unstable-v1.xml
0189     BASENAME xwayland-keyboard-grab-unstable-v1
0190 )
0191 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0192     PROTOCOL ${WaylandProtocols_DATADIR}/staging/content-type/content-type-v1.xml
0193     BASENAME content-type-v1
0194 )
0195 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0196     PROTOCOL ${WaylandProtocols_DATADIR}/staging/xwayland-shell/xwayland-shell-v1.xml
0197     BASENAME xwayland-shell-v1
0198 )
0199 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0200     PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/kde-output-order-v1.xml
0201     BASENAME kde-output-order-v1
0202 )
0203 
0204 ecm_add_qtwayland_server_protocol_kde(WaylandProtocols_xml
0205     PROTOCOL ${WaylandProtocols_DATADIR}/staging/fractional-scale/fractional-scale-v1.xml
0206     BASENAME fractional-scale-v1
0207 )
0208 
0209 target_sources(kwin PRIVATE
0210     abstract_data_source.cpp
0211     abstract_drop_handler.cpp
0212     appmenu_interface.cpp
0213     blur_interface.cpp
0214     clientbuffer.cpp
0215     clientbufferintegration.cpp
0216     clientconnection.cpp
0217     compositor_interface.cpp
0218     contenttype_v1_interface.cpp
0219     contrast_interface.cpp
0220     datacontroldevice_v1_interface.cpp
0221     datacontroldevicemanager_v1_interface.cpp
0222     datacontroloffer_v1_interface.cpp
0223     datacontrolsource_v1_interface.cpp
0224     datadevice_interface.cpp
0225     datadevicemanager_interface.cpp
0226     dataoffer_interface.cpp
0227     datasource_interface.cpp
0228     display.cpp
0229     dpms_interface.cpp
0230     drmclientbuffer.cpp
0231     drmlease_v1_interface.cpp
0232     fakeinput_interface.cpp
0233     fractionalscale_v1_interface.cpp
0234     filtered_display.cpp
0235     idle_interface.cpp
0236     idleinhibit_v1_interface.cpp
0237     idlenotify_v1_interface.cpp
0238     inputmethod_v1_interface.cpp
0239     keyboard_interface.cpp
0240     keyboard_shortcuts_inhibit_v1_interface.cpp
0241     keystate_interface.cpp
0242     layershell_v1_interface.cpp
0243     linuxdmabufv1clientbuffer.cpp
0244     lockscreen_overlay_v1_interface.cpp
0245     output_interface.cpp
0246     output_order_v1_interface.cpp
0247     outputdevice_v2_interface.cpp
0248     outputmanagement_v2_interface.cpp
0249     plasmashell_interface.cpp
0250     plasmavirtualdesktop_interface.cpp
0251     plasmawindowmanagement_interface.cpp
0252     pointer_interface.cpp
0253     pointerconstraints_v1_interface.cpp
0254     pointergestures_v1_interface.cpp
0255     primaryselectiondevice_v1_interface.cpp
0256     primaryselectiondevicemanager_v1_interface.cpp
0257     primaryselectionoffer_v1_interface.cpp
0258     primaryselectionsource_v1_interface.cpp
0259     region_interface.cpp
0260     relativepointer_v1_interface.cpp
0261     screencast_v1_interface.cpp
0262     seat_interface.cpp
0263     server_decoration_interface.cpp
0264     server_decoration_palette_interface.cpp
0265     shadow_interface.cpp
0266     shmclientbuffer.cpp
0267     slide_interface.cpp
0268     subcompositor_interface.cpp
0269     surface_interface.cpp
0270     surfacerole.cpp
0271     tablet_v2_interface.cpp
0272     tearingcontrol_v1_interface.cpp
0273     textinput.cpp
0274     textinput_v1_interface.cpp
0275     textinput_v2_interface.cpp
0276     textinput_v3_interface.cpp
0277     touch_interface.cpp
0278     viewporter_interface.cpp
0279     xdgactivation_v1_interface.cpp
0280     xdgdecoration_v1_interface.cpp
0281     xdgforeign_v2_interface.cpp
0282     xdgoutput_v1_interface.cpp
0283     xdgshell_interface.cpp
0284     xwaylandkeyboardgrab_v1_interface.cpp
0285     xwaylandshell_v1_interface.cpp
0286 )
0287 
0288 if(CMAKE_SYSTEM_NAME MATCHES "Linux")
0289     target_sources(kwin PRIVATE utils/executable_path_proc.cpp)
0290 elseif(CMAKE_SYSTEM_NAME MATCHES "FreeBSD")
0291     target_sources(kwin PRIVATE utils/executable_path_sysctl.cpp)
0292 else()
0293     message(FATAL_ERROR "Unsupported platform ${CMAKE_SYSTEM_NAME}")
0294 endif()