From dcf91d4321a481b791fca6e57db46d59f2280866 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Tue, 17 Sep 2019 12:15:35 +0300 Subject: [PATCH] Cleanup style in CMakeLists.txt files We have lots of inconsistency at the moment in CMakeLists.txt files. Most of it is due to kwin being a very old project. This change hopefully fixes all of it. --- CMakeLists.txt | 251 +++++++-------- autotests/CMakeLists.txt | 285 +++++++++--------- autotests/libinput/CMakeLists.txt | 90 +++--- autotests/libxrenderutils/CMakeLists.txt | 2 +- autotests/tabbox/CMakeLists.txt | 86 +++--- data/CMakeLists.txt | 15 +- effects/CMakeLists.txt | 123 ++++---- effects/backgroundcontrast/CMakeLists.txt | 7 +- effects/blur/CMakeLists.txt | 2 +- effects/coverswitch/CMakeLists.txt | 2 +- effects/cube/CMakeLists.txt | 4 +- effects/cubeslide/CMakeLists.txt | 2 +- effects/desktopgrid/CMakeLists.txt | 9 +- effects/diminactive/CMakeLists.txt | 2 +- effects/fallapart/CMakeLists.txt | 4 +- effects/glide/CMakeLists.txt | 2 +- effects/highlightwindow/CMakeLists.txt | 4 +- effects/kscreen/CMakeLists.txt | 4 +- effects/magiclamp/CMakeLists.txt | 2 +- effects/presentwindows/CMakeLists.txt | 5 +- effects/resize/CMakeLists.txt | 2 +- effects/screenedge/CMakeLists.txt | 4 +- effects/screenshot/CMakeLists.txt | 4 +- effects/sheet/CMakeLists.txt | 4 +- effects/showfps/CMakeLists.txt | 2 +- effects/slide/CMakeLists.txt | 2 +- effects/slideback/CMakeLists.txt | 4 +- effects/slidingpopups/CMakeLists.txt | 4 +- effects/snaphelper/CMakeLists.txt | 4 +- effects/startupfeedback/CMakeLists.txt | 7 +- effects/trackmouse/CMakeLists.txt | 5 +- effects/wobblywindows/CMakeLists.txt | 2 +- helpers/killer/CMakeLists.txt | 9 +- kcmkwin/CMakeLists.txt | 22 +- kcmkwin/kwincompositing/CMakeLists.txt | 19 +- kcmkwin/kwindecoration/CMakeLists.txt | 6 +- kcmkwin/kwindesktop/CMakeLists.txt | 7 +- kcmkwin/kwineffects/CMakeLists.txt | 2 +- kcmkwin/kwinoptions/CMakeLists.txt | 36 ++- kcmkwin/kwinrules/CMakeLists.txt | 27 +- kcmkwin/kwinscreenedges/CMakeLists.txt | 29 +- kcmkwin/kwinscripts/CMakeLists.txt | 8 +- kcmkwin/kwintabbox/CMakeLists.txt | 28 +- libkwineffects/CMakeLists.txt | 50 +-- plugins/CMakeLists.txt | 2 +- plugins/idletime/CMakeLists.txt | 2 +- plugins/kdecorations/CMakeLists.txt | 2 +- .../kdecorations/aurorae/src/CMakeLists.txt | 48 +-- .../themes/plastik/code/CMakeLists.txt | 2 +- plugins/platforms/CMakeLists.txt | 4 +- plugins/platforms/drm/CMakeLists.txt | 6 +- plugins/platforms/hwcomposer/CMakeLists.txt | 4 +- plugins/platforms/virtual/CMakeLists.txt | 4 +- plugins/platforms/wayland/CMakeLists.txt | 4 +- plugins/platforms/x11/CMakeLists.txt | 2 +- plugins/platforms/x11/common/CMakeLists.txt | 4 +- .../platforms/x11/standalone/CMakeLists.txt | 28 +- plugins/platforms/x11/windowed/CMakeLists.txt | 4 +- plugins/qpa/CMakeLists.txt | 12 +- plugins/scenes/CMakeLists.txt | 2 +- plugins/scenes/opengl/CMakeLists.txt | 4 +- plugins/scenes/qpainter/CMakeLists.txt | 2 +- plugins/windowsystem/CMakeLists.txt | 5 +- qml/CMakeLists.txt | 6 +- scripting/CMakeLists.txt | 7 +- tabbox/CMakeLists.txt | 4 +- tests/CMakeLists.txt | 26 +- 67 files changed, 684 insertions(+), 688 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c847d123db..9f167e107c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,7 +7,7 @@ set(PROJECT_VERSION_MAJOR 5) set(QT_MIN_VERSION "5.12.0") set(KF5_MIN_VERSION "5.62.0") -set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH} ) +set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${CMAKE_MODULE_PATH}) find_package(ECM 5.38 REQUIRED NO_MODULE) @@ -33,9 +33,9 @@ find_package(Qt5 ${QT_MIN_VERSION} CONFIG REQUIRED COMPONENTS find_package(Qt5Test ${QT_MIN_VERSION} CONFIG QUIET) set_package_properties(Qt5Test PROPERTIES - PURPOSE "Required for tests" - TYPE OPTIONAL - ) + PURPOSE "Required for tests" + TYPE OPTIONAL +) add_feature_info("Qt5Test" Qt5Test_FOUND "Required for building tests") if (NOT Qt5Test_FOUND) set(BUILD_TESTING OFF CACHE BOOL "Build the testing tree.") @@ -55,10 +55,9 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON) find_package(Qt5Multimedia QUIET) set_package_properties(Qt5Multimedia PROPERTIES - PURPOSE "Runtime-only dependency for effect video playback" - TYPE RUNTIME - ) - + PURPOSE "Runtime-only dependency for effect video playback" + TYPE RUNTIME +) # required frameworks by Core find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS @@ -92,23 +91,23 @@ find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS find_package(Threads) set_package_properties(Threads PROPERTIES - PURPOSE "Needed for VirtualTerminal support in KWin Wayland" - TYPE REQUIRED - ) + PURPOSE "Needed for VirtualTerminal support in KWin Wayland" + TYPE REQUIRED +) # optional frameworks find_package(KF5Activities ${KF5_MIN_VERSION} CONFIG) set_package_properties(KF5Activities PROPERTIES - PURPOSE "Enable building of KWin with kactivities support" - TYPE OPTIONAL - ) + PURPOSE "Enable building of KWin with kactivities support" + TYPE OPTIONAL +) add_feature_info("KF5Activities" KF5Activities_FOUND "Enable building of KWin with kactivities support") find_package(KF5DocTools ${KF5_MIN_VERSION} CONFIG) set_package_properties(KF5DocTools PROPERTIES - PURPOSE "Enable building documentation" - TYPE OPTIONAL - ) + PURPOSE "Enable building documentation" + TYPE OPTIONAL +) add_feature_info("KF5DocTools" KF5DocTools_FOUND "Enable building documentation") find_package(KF5Kirigami2 ${KF5_MIN_VERSION} CONFIG) @@ -122,15 +121,17 @@ find_package(KDecoration2 5.13.0 CONFIG REQUIRED) find_package(KScreenLocker CONFIG REQUIRED) set_package_properties(KScreenLocker PROPERTIES - TYPE REQUIRED - PURPOSE "For screenlocker integration in kwin_wayland") + TYPE REQUIRED + PURPOSE "For screenlocker integration in kwin_wayland" +) find_package(Breeze 5.9.0 CONFIG) set_package_properties(Breeze PROPERTIES - TYPE OPTIONAL - PURPOSE "For setting the default window decoration plugin") -if(${Breeze_FOUND}) - if(${BREEZE_WITH_KDECORATION}) + TYPE OPTIONAL + PURPOSE "For setting the default window decoration plugin" +) +if (${Breeze_FOUND}) + if (${BREEZE_WITH_KDECORATION}) set(HAVE_BREEZE_DECO true) else() set(HAVE_BREEZE_DECO FALSE) @@ -142,68 +143,70 @@ add_feature_info("Breeze-Decoration" HAVE_BREEZE_DECO "Default decoration plugin find_package(EGL) set_package_properties(EGL PROPERTIES - TYPE RUNTIME - PURPOSE "Required to build KWin with EGL support" - ) + TYPE RUNTIME + PURPOSE "Required to build KWin with EGL support" +) find_package(epoxy) -set_package_properties(epoxy PROPERTIES DESCRIPTION "libepoxy" - URL "https://github.com/anholt/libepoxy" - TYPE REQUIRED - PURPOSE "OpenGL dispatch library" - ) +set_package_properties(epoxy PROPERTIES + DESCRIPTION "libepoxy" + URL "https://github.com/anholt/libepoxy" + TYPE REQUIRED + PURPOSE "OpenGL dispatch library" +) set(HAVE_DL_LIBRARY FALSE) -if(epoxy_HAS_GLX) +if (epoxy_HAS_GLX) find_library(DL_LIBRARY dl) - if(DL_LIBRARY) + if (DL_LIBRARY) set(HAVE_DL_LIBRARY TRUE) endif() endif() find_package(Wayland 1.2 REQUIRED COMPONENTS Cursor OPTIONAL_COMPONENTS Egl) set_package_properties(Wayland PROPERTIES - TYPE REQUIRED - PURPOSE "Required for building KWin with Wayland support" - ) + TYPE REQUIRED + PURPOSE "Required for building KWin with Wayland support" +) add_feature_info("Wayland::EGL" Wayland_Egl_FOUND "Enable building of Wayland backend and QPA with EGL support.") set(HAVE_WAYLAND_EGL FALSE) -if(Wayland_Egl_FOUND) +if (Wayland_Egl_FOUND) set(HAVE_WAYLAND_EGL TRUE) endif() find_package(XKB 0.7.0) set_package_properties(XKB PROPERTIES - TYPE REQUIRED - PURPOSE "Required for building KWin with Wayland support" - ) + TYPE REQUIRED + PURPOSE "Required for building KWin with Wayland support" +) find_package(Libinput 1.9) set_package_properties(Libinput PROPERTIES TYPE REQUIRED PURPOSE "Required for input handling on Wayland.") find_package(UDev) -set_package_properties(UDev PROPERTIES URL "http://www.freedesktop.org/software/systemd/libudev/" - DESCRIPTION "Linux device library." - TYPE REQUIRED - PURPOSE "Required for input handling on Wayland." - ) +set_package_properties(UDev PROPERTIES + URL "http://www.freedesktop.org/software/systemd/libudev/" + DESCRIPTION "Linux device library." + TYPE REQUIRED + PURPOSE "Required for input handling on Wayland." +) find_package(Libdrm 2.4.62) set_package_properties(Libdrm PROPERTIES TYPE OPTIONAL PURPOSE "Required for drm output on Wayland.") set(HAVE_DRM FALSE) -if(Libdrm_FOUND) +if (Libdrm_FOUND) set(HAVE_DRM TRUE) endif() find_package(gbm) set_package_properties(gbm PROPERTIES TYPE OPTIONAL PURPOSE "Required for egl output of drm backend.") set(HAVE_GBM FALSE) -if(HAVE_DRM AND gbm_FOUND) +if (HAVE_DRM AND gbm_FOUND) set(HAVE_GBM TRUE) endif() option(KWIN_BUILD_EGL_STREAM_BACKEND "Enable building of EGLStream based DRM backend" ON) -if(HAVE_DRM AND KWIN_BUILD_EGL_STREAM_BACKEND) +if (HAVE_DRM AND KWIN_BUILD_EGL_STREAM_BACKEND) set(HAVE_EGL_STREAMS TRUE) endif() @@ -212,30 +215,30 @@ set_package_properties(libhybris PROPERTIES TYPE OPTIONAL PURPOSE "Required for set(HAVE_LIBHYBRIS ${libhybris_FOUND}) find_package(X11) -set_package_properties(X11 PROPERTIES DESCRIPTION "X11 libraries" - URL "https://www.x.org" - TYPE REQUIRED - ) +set_package_properties(X11 PROPERTIES + DESCRIPTION "X11 libraries" + URL "https://www.x.org" + TYPE REQUIRED +) add_feature_info("XInput" X11_Xinput_FOUND "Required for poll-free mouse cursor updates") set(HAVE_X11_XINPUT ${X11_Xinput_FOUND}) # All the required XCB components -find_package(XCB 1.10 - REQUIRED COMPONENTS - COMPOSITE - CURSOR - DAMAGE - GLX - ICCCM - IMAGE - KEYSYMS - RANDR - RENDER - SHAPE - SHM - SYNC - XCB - XFIXES +find_package(XCB 1.10 REQUIRED COMPONENTS + COMPOSITE + CURSOR + DAMAGE + GLX + ICCCM + IMAGE + KEYSYMS + RANDR + RENDER + SHAPE + SHM + SYNC + XCB + XFIXES ) set_package_properties(XCB PROPERTIES TYPE REQUIRED) @@ -247,8 +250,9 @@ add_feature_info("XCB-ICCCM" XCB_ICCCM_FOUND "Required for building test applica find_package(X11_XCB) set_package_properties(X11_XCB PROPERTIES - PURPOSE "Required for building X11 windowed backend of kwin_wayland" - TYPE OPTIONAL) + PURPOSE "Required for building X11 windowed backend of kwin_wayland" + TYPE OPTIONAL +) # dependencies for QPA plugin find_package(Qt5FontDatabaseSupport REQUIRED) @@ -256,16 +260,17 @@ find_package(Qt5ThemeSupport REQUIRED) find_package(Qt5EventDispatcherSupport REQUIRED) find_package(Freetype REQUIRED) -set_package_properties(Freetype PROPERTIES DESCRIPTION "A font rendering engine" - URL "https://www.freetype.org" - TYPE REQUIRED - PURPOSE "Needed for KWin's QPA plugin." - ) +set_package_properties(Freetype PROPERTIES + DESCRIPTION "A font rendering engine" + URL "https://www.freetype.org" + TYPE REQUIRED + PURPOSE "Needed for KWin's QPA plugin." +) find_package(Fontconfig REQUIRED) set_package_properties(Fontconfig PROPERTIES - TYPE REQUIRED - PURPOSE "Needed for KWin's QPA plugin." - ) + TYPE REQUIRED + PURPOSE "Needed for KWin's QPA plugin." +) find_package(Xwayland) set_package_properties(Xwayland PROPERTIES @@ -273,7 +278,7 @@ set_package_properties(Xwayland PROPERTIES DESCRIPTION "Xwayland X server" TYPE RUNTIME PURPOSE "Needed for running kwin_wayland" - ) +) find_package(Libcap) set_package_properties(Libcap PROPERTIES @@ -309,8 +314,8 @@ set(KWIN_INTERNAL_NAME_WAYLAND "kwin_wayland") set(KWIN_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}) # KWIN_HAVE_XRENDER_COMPOSITING - whether XRender-based compositing support is available: may be disabled -if( KWIN_BUILD_XRENDER_COMPOSITING ) - set( KWIN_HAVE_XRENDER_COMPOSITING 1 ) +if (KWIN_BUILD_XRENDER_COMPOSITING) + set(KWIN_HAVE_XRENDER_COMPOSITING 1) endif() include_directories(${XKB_INCLUDE_DIR}) @@ -357,7 +362,7 @@ add_feature_info("SCHED_RESET_ON_FORK" HAVE_SCHED_RESET_ON_FORK "Required for running kwin_wayland with real-time scheduling") -configure_file(config-kwin.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kwin.h ) +configure_file(config-kwin.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-kwin.h) ########### global ############### set(kwin_effects_dbus_xml ${CMAKE_CURRENT_SOURCE_DIR}/org.kde.kwin.Effects.xml) @@ -369,18 +374,18 @@ include_directories(BEFORE ${CMAKE_CURRENT_SOURCE_DIR}/effects ${CMAKE_CURRENT_SOURCE_DIR}/tabbox ${CMAKE_CURRENT_SOURCE_DIR}/platformsupport - ) +) -add_subdirectory( libkwineffects ) -if(KWIN_BUILD_KCMS) - add_subdirectory( kcmkwin ) +add_subdirectory(libkwineffects) +if (KWIN_BUILD_KCMS) + add_subdirectory(kcmkwin) endif() -add_subdirectory( data ) +add_subdirectory(data) -add_subdirectory( effects ) -add_subdirectory( scripts ) -add_subdirectory( tabbox ) +add_subdirectory(effects) +add_subdirectory(scripts) +add_subdirectory(tabbox) add_subdirectory(scripting) add_subdirectory(helpers) @@ -493,7 +498,7 @@ set(kwin_KDEINIT_SRCS xcbutils.cpp xkb.cpp xwl/xwayland_interface.cpp - ) +) include(ECMQtDeclareLoggingCategory) ecm_qt_declare_logging_category(kwin_KDEINIT_SRCS @@ -507,10 +512,9 @@ ecm_qt_declare_logging_category(kwin_KDEINIT_SRCS Critical ) -if(KWIN_BUILD_TABBOX) +if (KWIN_BUILD_TABBOX) include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS}) - set( - kwin_KDEINIT_SRCS ${kwin_KDEINIT_SRCS} + set(kwin_KDEINIT_SRCS ${kwin_KDEINIT_SRCS} tabbox/clientmodel.cpp tabbox/desktopchain.cpp tabbox/desktopmodel.cpp @@ -520,37 +524,34 @@ if(KWIN_BUILD_TABBOX) tabbox/tabboxconfig.cpp tabbox/tabboxhandler.cpp tabbox/x11_filter.cpp - ) + ) endif() -if(KWIN_BUILD_ACTIVITIES) - set( - kwin_KDEINIT_SRCS ${kwin_KDEINIT_SRCS} +if (KWIN_BUILD_ACTIVITIES) + set(kwin_KDEINIT_SRCS ${kwin_KDEINIT_SRCS} activities.cpp ) endif() if (HAVE_LINUX_VT_H) - set(kwin_KDEINIT_SRCS - ${kwin_KDEINIT_SRCS} - virtual_terminal.cpp - ) + set(kwin_KDEINIT_SRCS ${kwin_KDEINIT_SRCS} + virtual_terminal.cpp + ) endif() kconfig_add_kcfg_files(kwin_KDEINIT_SRCS settings.kcfgc) kconfig_add_kcfg_files(kwin_KDEINIT_SRCS colorcorrection/colorcorrect_settings.kcfgc) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS org.kde.KWin.xml dbusinterface.h KWin::DBusInterface ) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS org.kde.kwin.Compositing.xml dbusinterface.h KWin::CompositorDBusInterface ) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS org.kde.kwin.ColorCorrect.xml colorcorrection/colorcorrectdbusinterface.h KWin::ColorCorrect::ColorCorrectDBusInterface ) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS ${kwin_effects_dbus_xml} effects.h KWin::EffectsHandlerImpl ) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS org.kde.kwin.OrientationSensor.xml orientation_sensor.h KWin::OrientationSensor) -qt5_add_dbus_adaptor( kwin_KDEINIT_SRCS org.kde.KWin.VirtualDesktopManager.xml dbusinterface.h KWin::VirtualDesktopManagerDBusInterface ) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS org.kde.KWin.xml dbusinterface.h KWin::DBusInterface) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS org.kde.kwin.Compositing.xml dbusinterface.h KWin::CompositorDBusInterface) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS org.kde.kwin.ColorCorrect.xml colorcorrection/colorcorrectdbusinterface.h KWin::ColorCorrect::ColorCorrectDBusInterface) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS ${kwin_effects_dbus_xml} effects.h KWin::EffectsHandlerImpl) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS org.kde.kwin.OrientationSensor.xml orientation_sensor.h KWin::OrientationSensor) +qt5_add_dbus_adaptor(kwin_KDEINIT_SRCS org.kde.KWin.VirtualDesktopManager.xml dbusinterface.h KWin::VirtualDesktopManagerDBusInterface) -qt5_add_dbus_interface( kwin_KDEINIT_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/kf5_org.freedesktop.ScreenSaver.xml screenlocker_interface ) -qt5_add_dbus_interface( kwin_KDEINIT_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/org.kde.screensaver.xml kscreenlocker_interface ) - -qt5_add_dbus_interface( kwin_KDEINIT_SRCS org.kde.kappmenu.xml appmenu_interface ) +qt5_add_dbus_interface(kwin_KDEINIT_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/kf5_org.freedesktop.ScreenSaver.xml screenlocker_interface) +qt5_add_dbus_interface(kwin_KDEINIT_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/org.kde.screensaver.xml kscreenlocker_interface) +qt5_add_dbus_interface(kwin_KDEINIT_SRCS org.kde.kappmenu.xml appmenu_interface) ki18n_wrap_ui(kwin_KDEINIT_SRCS debug_console.ui @@ -618,7 +619,7 @@ set(kwin_WAYLAND_LIBS ${CMAKE_THREAD_LIBS_INIT} ) -if(KWIN_BUILD_ACTIVITIES) +if (KWIN_BUILD_ACTIVITIES) set(kwin_KDE_LIBS ${kwin_KDE_LIBS} KF5::Activities) endif() @@ -638,7 +639,7 @@ add_library(kwin SHARED ${kwin_KDEINIT_SRCS}) set_target_properties(kwin PROPERTIES VERSION ${PROJECT_VERSION} SOVERSION ${PROJECT_VERSION_MAJOR} - ) +) target_link_libraries(kwin ${kwinLibs}) generate_export_header(kwin EXPORT_FILE_NAME kwin_export.h) @@ -648,9 +649,9 @@ target_link_libraries(kwin kwinglutils ${epoxy_LIBRARY}) kf5_add_kdeinit_executable(kwin_x11 main_x11.cpp) target_link_libraries(kdeinit_kwin_x11 kwin KF5::Crash Qt5::X11Extras) -install(TARGETS kwin ${INSTALL_TARGETS_DEFAULT_ARGS} LIBRARY NAMELINK_SKIP ) -install(TARGETS kdeinit_kwin_x11 ${INSTALL_TARGETS_DEFAULT_ARGS} ) -install(TARGETS kwin_x11 ${INSTALL_TARGETS_DEFAULT_ARGS} ) +install(TARGETS kwin ${INSTALL_TARGETS_DEFAULT_ARGS} LIBRARY NAMELINK_SKIP) +install(TARGETS kdeinit_kwin_x11 ${INSTALL_TARGETS_DEFAULT_ARGS}) +install(TARGETS kwin_x11 ${INSTALL_TARGETS_DEFAULT_ARGS}) set(kwin_XWAYLAND_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/xwl/clipboard.cpp @@ -663,7 +664,7 @@ set(kwin_XWAYLAND_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/xwl/selection_source.cpp ${CMAKE_CURRENT_SOURCE_DIR}/xwl/transfer.cpp ${CMAKE_CURRENT_SOURCE_DIR}/xwl/xwayland.cpp - ) +) include(ECMQtDeclareLoggingCategory) ecm_qt_declare_logging_category(kwin_XWAYLAND_SRCS HEADER @@ -679,7 +680,7 @@ ecm_qt_declare_logging_category(kwin_XWAYLAND_SRCS set(kwin_WAYLAND_SRCS main_wayland.cpp tabletmodemanager.cpp - ) +) add_executable(kwin_wayland ${kwin_WAYLAND_SRCS} ${kwin_XWAYLAND_SRCS}) target_link_libraries(kwin_wayland kwin KF5::Crash) @@ -687,7 +688,7 @@ if (HAVE_LIBCAP) target_link_libraries(kwin_wayland ${Libcap_LIBRARIES}) endif() -install(TARGETS kwin_wayland ${INSTALL_TARGETS_DEFAULT_ARGS} ) +install(TARGETS kwin_wayland ${INSTALL_TARGETS_DEFAULT_ARGS}) if (HAVE_LIBCAP) install( CODE "execute_process( @@ -703,9 +704,9 @@ add_subdirectory(plugins) ########### install files ############### -install( FILES kwin.kcfg DESTINATION ${KCFG_INSTALL_DIR} RENAME ${KWIN_NAME}.kcfg ) -install( FILES colorcorrection/colorcorrect_settings.kcfg DESTINATION ${KCFG_INSTALL_DIR} RENAME ${KWIN_NAME}_colorcorrect.kcfg ) -install( FILES kwin.notifyrc DESTINATION ${KNOTIFYRC_INSTALL_DIR} RENAME ${KWIN_NAME}.notifyrc) +install(FILES kwin.kcfg DESTINATION ${KCFG_INSTALL_DIR} RENAME ${KWIN_NAME}.kcfg) +install(FILES colorcorrection/colorcorrect_settings.kcfg DESTINATION ${KCFG_INSTALL_DIR} RENAME ${KWIN_NAME}_colorcorrect.kcfg) +install(FILES kwin.notifyrc DESTINATION ${KNOTIFYRC_INSTALL_DIR} RENAME ${KWIN_NAME}.notifyrc) install( FILES org.kde.KWin.VirtualDesktopManager.xml @@ -716,10 +717,10 @@ install( DESTINATION ${KDE_INSTALL_DBUSINTERFACEDIR} ) -install( FILES ${CMAKE_CURRENT_BINARY_DIR}/kwin_export.h DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kwin_export.h DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) # Install the KWin/Script service type -install( FILES scripting/kwinscript.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) +install(FILES scripting/kwinscript.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) add_subdirectory(qml) diff --git a/autotests/CMakeLists.txt b/autotests/CMakeLists.txt index d80a6f4cc7..1bc8940218 100644 --- a/autotests/CMakeLists.txt +++ b/autotests/CMakeLists.txt @@ -12,38 +12,38 @@ add_subdirectory(tabbox) ######################################################## # Test ScreenPaintData ######################################################## -set( testScreenPaintData_SRCS test_screen_paint_data.cpp ) +set(testScreenPaintData_SRCS test_screen_paint_data.cpp) add_executable(testScreenPaintData ${testScreenPaintData_SRCS}) -target_link_libraries( testScreenPaintData kwineffects Qt5::Test Qt5::Widgets KF5::WindowSystem) +target_link_libraries(testScreenPaintData kwineffects Qt5::Test Qt5::Widgets KF5::WindowSystem) add_test(NAME kwin-testScreenPaintData COMMAND testScreenPaintData) ecm_mark_as_test(testScreenPaintData) ######################################################## # Test WindowPaintData ######################################################## -set( testWindowPaintData_SRCS test_window_paint_data.cpp ) +set(testWindowPaintData_SRCS test_window_paint_data.cpp) add_executable(testWindowPaintData ${testWindowPaintData_SRCS}) -target_link_libraries( testWindowPaintData kwineffects Qt5::Widgets Qt5::Test ) +target_link_libraries(testWindowPaintData kwineffects Qt5::Widgets Qt5::Test ) add_test(NAME kwin-testWindowPaintData COMMAND testWindowPaintData) ecm_mark_as_test(testWindowPaintData) ######################################################## # Test VirtualDesktopManager ######################################################## -set( testVirtualDesktops_SRCS - test_virtual_desktops.cpp - ../virtualdesktops.cpp +set(testVirtualDesktops_SRCS + ../virtualdesktops.cpp + test_virtual_desktops.cpp ) add_executable(testVirtualDesktops ${testVirtualDesktops_SRCS}) -target_link_libraries( testVirtualDesktops - Qt5::Test - Qt5::Widgets - KF5::I18n - KF5::GlobalAccel - KF5::ConfigCore - KF5::WindowSystem - KF5::WaylandServer +target_link_libraries(testVirtualDesktops + KF5::ConfigCore + KF5::GlobalAccel + KF5::I18n + KF5::WaylandServer + KF5::WindowSystem + Qt5::Test + Qt5::Widgets ) add_test(NAME kwin-testVirtualDesktops COMMAND testVirtualDesktops) ecm_mark_as_test(testVirtualDesktops) @@ -51,23 +51,23 @@ ecm_mark_as_test(testVirtualDesktops) ######################################################## # Test ClientMachine ######################################################## -set( testClientMachine_SRCS - test_client_machine.cpp - ../client_machine.cpp +set(testClientMachine_SRCS + ../client_machine.cpp + test_client_machine.cpp ) -add_executable( testClientMachine ${testClientMachine_SRCS} ) +add_executable(testClientMachine ${testClientMachine_SRCS}) set_target_properties(testClientMachine PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") -target_link_libraries( testClientMachine - Qt5::Concurrent - Qt5::Test - Qt5::X11Extras - Qt5::Widgets - KF5::ConfigCore - KF5::WindowSystem - XCB::XCB - XCB::XFIXES - ${X11_X11_LIB} # to make jenkins happy +target_link_libraries(testClientMachine + ${X11_X11_LIB} # to make jenkins happy + KF5::ConfigCore + KF5::WindowSystem + Qt5::Concurrent + Qt5::Test + Qt5::Widgets + Qt5::X11Extras + XCB::XCB + XCB::XFIXES ) add_test(NAME kwin-testClientMachine COMMAND testClientMachine) ecm_mark_as_test(testClientMachine) @@ -75,33 +75,33 @@ ecm_mark_as_test(testClientMachine) ######################################################## # Test XcbWrapper ######################################################## -set( testXcbWrapper_SRCS - test_xcb_wrapper.cpp +set(testXcbWrapper_SRCS + test_xcb_wrapper.cpp ) -add_executable( testXcbWrapper ${testXcbWrapper_SRCS} ) +add_executable(testXcbWrapper ${testXcbWrapper_SRCS}) -target_link_libraries( testXcbWrapper - Qt5::Test - Qt5::X11Extras - Qt5::Widgets - KF5::ConfigCore - KF5::WindowSystem - XCB::XCB +target_link_libraries(testXcbWrapper + KF5::ConfigCore + KF5::WindowSystem + Qt5::Test + Qt5::Widgets + Qt5::X11Extras + XCB::XCB ) add_test(NAME kwin-testXcbWrapper COMMAND testXcbWrapper) ecm_mark_as_test(testXcbWrapper) if (XCB_ICCCM_FOUND) - add_executable( testXcbSizeHints test_xcb_size_hints.cpp ) + add_executable(testXcbSizeHints test_xcb_size_hints.cpp) set_target_properties(testXcbSizeHints PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") - target_link_libraries( testXcbSizeHints - Qt5::Test - Qt5::X11Extras - Qt5::Widgets - KF5::ConfigCore - KF5::WindowSystem - XCB::XCB - XCB::ICCCM + target_link_libraries(testXcbSizeHints + KF5::ConfigCore + KF5::WindowSystem + Qt5::Test + Qt5::Widgets + Qt5::X11Extras + XCB::ICCCM + XCB::XCB ) add_test(NAME kwin-testXcbSizeHints COMMAND testXcbSizeHints) ecm_mark_as_test(testXcbSizeHints) @@ -110,18 +110,18 @@ endif() ######################################################## # Test XcbWindow ######################################################## -set( testXcbWindow_SRCS - test_xcb_window.cpp +set(testXcbWindow_SRCS + test_xcb_window.cpp ) -add_executable( testXcbWindow ${testXcbWindow_SRCS} ) +add_executable(testXcbWindow ${testXcbWindow_SRCS}) -target_link_libraries( testXcbWindow - Qt5::Test - Qt5::X11Extras - Qt5::Widgets - KF5::ConfigCore - KF5::WindowSystem - XCB::XCB +target_link_libraries(testXcbWindow + KF5::ConfigCore + KF5::WindowSystem + Qt5::Test + Qt5::Widgets + Qt5::X11Extras + XCB::XCB ) add_test(NAME kwin-testXcbWindow COMMAND testXcbWindow) ecm_mark_as_test(testXcbWindow) @@ -129,21 +129,21 @@ ecm_mark_as_test(testXcbWindow) ######################################################## # Test BuiltInEffectLoader ######################################################## -set( testBuiltInEffectLoader_SRCS - test_builtin_effectloader.cpp - mock_effectshandler.cpp +set(testBuiltInEffectLoader_SRCS ../effectloader.cpp + mock_effectshandler.cpp + test_builtin_effectloader.cpp ) -add_executable( testBuiltInEffectLoader ${testBuiltInEffectLoader_SRCS}) +add_executable(testBuiltInEffectLoader ${testBuiltInEffectLoader_SRCS}) set_target_properties(testBuiltInEffectLoader PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") target_link_libraries(testBuiltInEffectLoader + KF5::Package Qt5::Concurrent Qt5::Test Qt5::X11Extras - KF5::Package - kwineffects kwin4_effect_builtins + kwineffects ) add_test(NAME kwin-testBuiltInEffectLoader COMMAND testBuiltInEffectLoader) @@ -153,37 +153,37 @@ ecm_mark_as_test(testBuiltInEffectLoader) # Test ScriptedEffectLoader ######################################################## include_directories(${KWIN_SOURCE_DIR}) -set( testScriptedEffectLoader_SRCS - test_scripted_effectloader.cpp +set(testScriptedEffectLoader_SRCS + ../effectloader.cpp + ../orientation_sensor.cpp + ../screens.cpp + ../scripting/scriptedeffect.cpp + ../scripting/scripting_logging.cpp + ../scripting/scriptingutils.cpp mock_abstract_client.cpp mock_effectshandler.cpp mock_screens.cpp mock_workspace.cpp - ../effectloader.cpp - ../scripting/scriptedeffect.cpp - ../scripting/scriptingutils.cpp - ../scripting/scripting_logging.cpp - ../screens.cpp - ../orientation_sensor.cpp + test_scripted_effectloader.cpp ) kconfig_add_kcfg_files(testScriptedEffectLoader_SRCS ../settings.kcfgc) -qt5_add_dbus_adaptor( testScriptedEffectLoader_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) -add_executable( testScriptedEffectLoader ${testScriptedEffectLoader_SRCS}) +qt5_add_dbus_adaptor(testScriptedEffectLoader_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) +add_executable(testScriptedEffectLoader ${testScriptedEffectLoader_SRCS}) target_link_libraries(testScriptedEffectLoader + KF5::ConfigGui + KF5::GlobalAccel + KF5::I18n + KF5::Notifications + KF5::Package Qt5::Concurrent Qt5::Qml Qt5::Script Qt5::Sensors Qt5::Test Qt5::X11Extras - KF5::ConfigGui - KF5::GlobalAccel - KF5::I18n - KF5::Notifications - KF5::Package - kwineffects kwin4_effect_builtins + kwineffects ) add_test(NAME kwin-testScriptedEffectLoader COMMAND testScriptedEffectLoader) @@ -192,20 +192,20 @@ ecm_mark_as_test(testScriptedEffectLoader) ######################################################## # Test PluginEffectLoader ######################################################## -set( testPluginEffectLoader_SRCS - test_plugin_effectloader.cpp - mock_effectshandler.cpp +set(testPluginEffectLoader_SRCS ../effectloader.cpp + mock_effectshandler.cpp + test_plugin_effectloader.cpp ) -add_executable( testPluginEffectLoader ${testPluginEffectLoader_SRCS}) +add_executable(testPluginEffectLoader ${testPluginEffectLoader_SRCS}) target_link_libraries(testPluginEffectLoader + KF5::Package Qt5::Concurrent Qt5::Test Qt5::X11Extras - KF5::Package - kwineffects kwin4_effect_builtins + kwineffects ) add_test(NAME kwin-testPluginEffectLoader COMMAND testPluginEffectLoader) @@ -228,32 +228,32 @@ target_link_libraries(effectversionplugin kwineffects) ######################################################## # Test Screens ######################################################## -set( testScreens_SRCS - test_screens.cpp +set(testScreens_SRCS + ../orientation_sensor.cpp + ../screens.cpp + ../x11eventfilter.cpp mock_abstract_client.cpp mock_client.cpp mock_screens.cpp mock_workspace.cpp - ../screens.cpp - ../x11eventfilter.cpp - ../orientation_sensor.cpp + test_screens.cpp ) kconfig_add_kcfg_files(testScreens_SRCS ../settings.kcfgc) -qt5_add_dbus_adaptor( testScreens_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) +qt5_add_dbus_adaptor(testScreens_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) -add_executable( testScreens ${testScreens_SRCS}) +add_executable(testScreens ${testScreens_SRCS}) target_include_directories(testScreens BEFORE PRIVATE ./) target_link_libraries(testScreens - Qt5::DBus - Qt5::Sensors - Qt5::Test - Qt5::X11Extras - Qt5::Widgets KF5::ConfigCore KF5::ConfigGui KF5::I18n KF5::Notifications KF5::WindowSystem + Qt5::DBus + Qt5::Sensors + Qt5::Test + Qt5::Widgets + Qt5::X11Extras ) add_test(NAME kwin_testScreens COMMAND testScreens) @@ -262,48 +262,48 @@ ecm_mark_as_test(testScreens) ######################################################## # Test ScreenEdges ######################################################## -set( testScreenEdges_SRCS - test_screen_edges.cpp +set(testScreenEdges_SRCS + ../atoms.cpp + ../gestures.cpp + ../orientation_sensor.cpp + ../plugins/platforms/x11/standalone/edge.cpp + ../screenedge.cpp + ../screens.cpp + ../virtualdesktops.cpp + ../xcbutils.cpp # init of extensions mock_abstract_client.cpp mock_client.cpp mock_screens.cpp mock_workspace.cpp - ../atoms.cpp - ../gestures.cpp - ../screens.cpp - ../screenedge.cpp - ../virtualdesktops.cpp - ../xcbutils.cpp # init of extensions - ../plugins/platforms/x11/standalone/edge.cpp - ../orientation_sensor.cpp + test_screen_edges.cpp ) kconfig_add_kcfg_files(testScreenEdges_SRCS ../settings.kcfgc) -qt5_add_dbus_interface( testScreenEdges_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/kf5_org.freedesktop.ScreenSaver.xml screenlocker_interface ) -qt5_add_dbus_adaptor( testScreenEdges_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) +qt5_add_dbus_interface(testScreenEdges_SRCS ${KSCREENLOCKER_DBUS_INTERFACES_DIR}/kf5_org.freedesktop.ScreenSaver.xml screenlocker_interface ) +qt5_add_dbus_adaptor(testScreenEdges_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) -add_executable( testScreenEdges ${testScreenEdges_SRCS}) +add_executable(testScreenEdges ${testScreenEdges_SRCS}) set_target_properties(testScreenEdges PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") target_include_directories(testScreenEdges BEFORE PRIVATE ./) target_link_libraries(testScreenEdges + KF5::ConfigCore + KF5::ConfigGui + KF5::GlobalAccel + KF5::I18n + KF5::Notifications + KF5::WaylandServer + KF5::WindowSystem Qt5::DBus Qt5::Sensors Qt5::Test Qt5::X11Extras - KF5::ConfigCore - KF5::ConfigGui - KF5::I18n - KF5::GlobalAccel - KF5::Notifications - KF5::WindowSystem - KF5::WaylandServer - XCB::XCB - XCB::RANDR - XCB::XFIXES - XCB::SYNC XCB::COMPOSITE XCB::DAMAGE XCB::GLX + XCB::RANDR XCB::SHM + XCB::SYNC + XCB::XCB + XCB::XFIXES ) add_test(NAME kwin_testScreenEdges COMMAND testScreenEdges) @@ -312,19 +312,19 @@ ecm_mark_as_test(testScreenEdges) ######################################################## # Test OnScreenNotification ######################################################## -set( testOnScreenNotification_SRCS - onscreennotificationtest.cpp - ../onscreennotification.cpp +set(testOnScreenNotification_SRCS ../input_event_spy.cpp + ../onscreennotification.cpp + onscreennotificationtest.cpp ) -add_executable( testOnScreenNotification ${testOnScreenNotification_SRCS}) +add_executable(testOnScreenNotification ${testOnScreenNotification_SRCS}) target_link_libraries(testOnScreenNotification + KF5::ConfigCore + Qt5::DBus + Qt5::Quick Qt5::Test Qt5::Widgets # QAction include - Qt5::Quick - Qt5::DBus - KF5::ConfigCore ) add_test(NAME kwin-testOnScreenNotification COMMAND testOnScreenNotification) @@ -333,11 +333,11 @@ ecm_mark_as_test(testOnScreenNotification) ######################################################## # Test Gestures ######################################################## -set( testGestures_SRCS - test_gestures.cpp +set(testGestures_SRCS ../gestures.cpp + test_gestures.cpp ) -add_executable( testGestures ${testGestures_SRCS}) +add_executable(testGestures ${testGestures_SRCS}) target_link_libraries(testGestures Qt5::Test @@ -351,20 +351,20 @@ ecm_mark_as_test(testGestures) ######################################################## add_executable(testX11TimestampUpdate test_x11_timestamp_update.cpp) target_link_libraries(testX11TimestampUpdate - Qt5::Test KF5::CoreAddons + Qt5::Test kwin ) add_test(NAME kwin-testX11TimestampUpdate COMMAND testX11TimestampUpdate) ecm_mark_as_test(testX11TimestampUpdate) set(testOpenGLContextAttributeBuilder_SRCS - opengl_context_attribute_builder_test.cpp ../abstract_opengl_context_attribute_builder.cpp ../egl_context_attribute_builder.cpp + opengl_context_attribute_builder_test.cpp ) -if(HAVE_EPOXY_GLX) +if (HAVE_EPOXY_GLX) set(testOpenGLContextAttributeBuilder_SRCS ${testOpenGLContextAttributeBuilder_SRCS} ../plugins/platforms/x11/standalone/glx_context_attribute_builder.cpp) endif() add_executable(testOpenGLContextAttributeBuilder ${testOpenGLContextAttributeBuilder_SRCS}) @@ -373,23 +373,23 @@ add_test(NAME kwin-testOpenGLContextAttributeBuilder COMMAND testOpenGLContextAt ecm_mark_as_test(testOpenGLContextAttributeBuilder) set(testXkb_SRCS - test_xkb.cpp ../xkb.cpp + test_xkb.cpp ) add_executable(testXkb ${testXkb_SRCS}) target_link_libraries(testXkb - Qt5::Test - Qt5::Gui - Qt5::Widgets KF5::ConfigCore - KF5::WindowSystem KF5::WaylandServer + KF5::WindowSystem + Qt5::Gui + Qt5::Test + Qt5::Widgets XKB::XKB ) add_test(NAME kwin-testXkb COMMAND testXkb) ecm_mark_as_test(testXkb) -if(HAVE_GBM) +if (HAVE_GBM) add_executable(testGbmSurface test_gbm_surface.cpp ../plugins/platforms/drm/gbm_surface.cpp) target_link_libraries(testGbmSurface Qt5::Test) add_test(NAME kwin-testGbmSurface COMMAND testGbmSurface) @@ -398,9 +398,8 @@ endif() add_executable(testVirtualKeyboardDBus test_virtualkeyboard_dbus.cpp ../virtualkeyboard_dbus.cpp) target_link_libraries(testVirtualKeyboardDBus - Qt5::Test Qt5::DBus + Qt5::Test ) add_test(NAME kwin-testVirtualKeyboardDBus COMMAND testVirtualKeyboardDBus) ecm_mark_as_test(testVirtualKeyboardDBus) - diff --git a/autotests/libinput/CMakeLists.txt b/autotests/libinput/CMakeLists.txt index b34db02de2..8caa4bb071 100644 --- a/autotests/libinput/CMakeLists.txt +++ b/autotests/libinput/CMakeLists.txt @@ -3,77 +3,77 @@ include_directories(${UDEV_INCLUDE_DIR}) ######################################################## # Test Devices ######################################################## -set( testLibinputDevice_SRCS device_test.cpp mock_libinput.cpp ../../libinput/device.cpp ) +set(testLibinputDevice_SRCS device_test.cpp mock_libinput.cpp ../../libinput/device.cpp ) add_executable(testLibinputDevice ${testLibinputDevice_SRCS}) -target_link_libraries( testLibinputDevice Qt5::Test Qt5::DBus Qt5::Gui KF5::ConfigCore) +target_link_libraries(testLibinputDevice Qt5::Test Qt5::DBus Qt5::Gui KF5::ConfigCore) add_test(NAME kwin-testLibinputDevice COMMAND testLibinputDevice) ecm_mark_as_test(testLibinputDevice) ######################################################## # Test Key Event ######################################################## -set( testLibinputKeyEvent_SRCS - key_event_test.cpp - mock_libinput.cpp - ../../libinput/device.cpp - ../../libinput/events.cpp - ) +set(testLibinputKeyEvent_SRCS + ../../libinput/device.cpp + ../../libinput/events.cpp + key_event_test.cpp + mock_libinput.cpp +) add_executable(testLibinputKeyEvent ${testLibinputKeyEvent_SRCS}) -target_link_libraries( testLibinputKeyEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) +target_link_libraries(testLibinputKeyEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testLibinputKeyEvent COMMAND testLibinputKeyEvent) ecm_mark_as_test(testLibinputKeyEvent) ######################################################## # Test Pointer Event ######################################################## -set( testLibinputPointerEvent_SRCS - pointer_event_test.cpp - mock_libinput.cpp - ../../libinput/device.cpp - ../../libinput/events.cpp - ) +set(testLibinputPointerEvent_SRCS + ../../libinput/device.cpp + ../../libinput/events.cpp + mock_libinput.cpp + pointer_event_test.cpp +) add_executable(testLibinputPointerEvent ${testLibinputPointerEvent_SRCS}) -target_link_libraries( testLibinputPointerEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) +target_link_libraries(testLibinputPointerEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testLibinputPointerEvent COMMAND testLibinputPointerEvent) ecm_mark_as_test(testLibinputPointerEvent) ######################################################## # Test Touch Event ######################################################## -set( testLibinputTouchEvent_SRCS - touch_event_test.cpp - mock_libinput.cpp - ../../libinput/device.cpp - ../../libinput/events.cpp - ) +set(testLibinputTouchEvent_SRCS + ../../libinput/device.cpp + ../../libinput/events.cpp + mock_libinput.cpp + touch_event_test.cpp +) add_executable(testLibinputTouchEvent ${testLibinputTouchEvent_SRCS}) -target_link_libraries( testLibinputTouchEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) +target_link_libraries(testLibinputTouchEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testLibinputTouchEvent COMMAND testLibinputTouchEvent) ecm_mark_as_test(testLibinputTouchEvent) ######################################################## # Test Gesture Event ######################################################## -set( testLibinputGestureEvent_SRCS - gesture_event_test.cpp - mock_libinput.cpp - ../../libinput/device.cpp - ../../libinput/events.cpp - ) +set(testLibinputGestureEvent_SRCS + ../../libinput/device.cpp + ../../libinput/events.cpp + gesture_event_test.cpp + mock_libinput.cpp +) add_executable(testLibinputGestureEvent ${testLibinputGestureEvent_SRCS}) -target_link_libraries( testLibinputGestureEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) +target_link_libraries(testLibinputGestureEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testLibinputGestureEvent COMMAND testLibinputGestureEvent) ecm_mark_as_test(testLibinputGestureEvent) ######################################################## # Test Switch Event ######################################################## -set( testLibinputSwitchEvent_SRCS - switch_event_test.cpp - mock_libinput.cpp +set(testLibinputSwitchEvent_SRCS ../../libinput/device.cpp ../../libinput/events.cpp - ) + mock_libinput.cpp + switch_event_test.cpp +) add_executable(testLibinputSwitchEvent ${testLibinputSwitchEvent_SRCS}) target_link_libraries(testLibinputSwitchEvent Qt5::Test Qt5::DBus Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testLibinputSwitchEvent COMMAND testLibinputSwitchEvent) @@ -82,32 +82,32 @@ ecm_mark_as_test(testLibinputSwitchEvent) ######################################################## # Test Context ######################################################## -set( testLibinputContext_SRCS - context_test.cpp - mock_libinput.cpp - mock_udev.cpp +set(testLibinputContext_SRCS ../../libinput/context.cpp ../../libinput/device.cpp ../../libinput/events.cpp ../../libinput/libinput_logging.cpp ../../logind.cpp - ) + context_test.cpp + mock_libinput.cpp + mock_udev.cpp +) add_executable(testLibinputContext ${testLibinputContext_SRCS}) -target_link_libraries( testLibinputContext +target_link_libraries(testLibinputContext + KF5::ConfigCore + KF5::WindowSystem Qt5::DBus Qt5::Test Qt5::Widgets - KF5::ConfigCore - KF5::WindowSystem - ) +) add_test(NAME kwin-testLibinputContext COMMAND testLibinputContext) ecm_mark_as_test(testLibinputContext) ######################################################## # Test Input Events ######################################################## -set( testInputEvents_SRCS input_event_test.cpp mock_libinput.cpp ../../libinput/device.cpp ../../input_event.cpp ) +set(testInputEvents_SRCS input_event_test.cpp mock_libinput.cpp ../../libinput/device.cpp ../../input_event.cpp) add_executable(testInputEvents ${testInputEvents_SRCS}) -target_link_libraries( testInputEvents Qt5::Test Qt5::DBus Qt5::Gui Qt5::Widgets KF5::ConfigCore) +target_link_libraries(testInputEvents Qt5::Test Qt5::DBus Qt5::Gui Qt5::Widgets KF5::ConfigCore) add_test(NAME kwin-testInputEvents COMMAND testInputEvents) ecm_mark_as_test(testInputEvents) diff --git a/autotests/libxrenderutils/CMakeLists.txt b/autotests/libxrenderutils/CMakeLists.txt index 062dc186dc..ceefcc2f62 100644 --- a/autotests/libxrenderutils/CMakeLists.txt +++ b/autotests/libxrenderutils/CMakeLists.txt @@ -9,5 +9,5 @@ target_link_libraries(blendPictureTest XCB::XCB XCB::RENDER XCB::XFIXES - ) +) ecm_mark_as_test(blendPictureTest) diff --git a/autotests/tabbox/CMakeLists.txt b/autotests/tabbox/CMakeLists.txt index 7130d70500..6657b957c2 100644 --- a/autotests/tabbox/CMakeLists.txt +++ b/autotests/tabbox/CMakeLists.txt @@ -3,31 +3,31 @@ add_definitions(-DKWIN_UNIT_TEST) ######################################################## # Test TabBox::ClientModel ######################################################## -set( testTabBoxClientModel_SRCS - ../../tabbox/clientmodel.cpp - ../../tabbox/desktopmodel.cpp - ../../tabbox/tabboxconfig.cpp - ../../tabbox/tabboxhandler.cpp - ../../tabbox/tabbox_logging.cpp - test_tabbox_clientmodel.cpp - mock_tabboxhandler.cpp - mock_tabboxclient.cpp +set(testTabBoxClientModel_SRCS + ../../tabbox/clientmodel.cpp + ../../tabbox/desktopmodel.cpp + ../../tabbox/tabbox_logging.cpp + ../../tabbox/tabboxconfig.cpp + ../../tabbox/tabboxhandler.cpp + mock_tabboxclient.cpp + mock_tabboxhandler.cpp + test_tabbox_clientmodel.cpp ) -add_executable( testTabBoxClientModel ${testTabBoxClientModel_SRCS} ) +add_executable(testTabBoxClientModel ${testTabBoxClientModel_SRCS}) set_target_properties(testTabBoxClientModel PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") -target_link_libraries( testTabBoxClientModel - Qt5::Core - Qt5::Widgets - Qt5::Script - Qt5::Quick - Qt5::Test - Qt5::DBus - Qt5::X11Extras +target_link_libraries(testTabBoxClientModel KF5::ConfigCore KF5::I18n KF5::Package KF5::WindowSystem + Qt5::Core + Qt5::DBus + Qt5::Quick + Qt5::Script + Qt5::Test + Qt5::Widgets + Qt5::X11Extras XCB::XCB ) add_test(NAME kwin-testTabBoxClientModel COMMAND testTabBoxClientModel) @@ -36,31 +36,31 @@ ecm_mark_as_test(testTabBoxClientModel) ######################################################## # Test TabBox::TabBoxHandler ######################################################## -set( testTabBoxHandler_SRCS - ../../tabbox/clientmodel.cpp - ../../tabbox/desktopmodel.cpp - ../../tabbox/tabboxconfig.cpp - ../../tabbox/tabboxhandler.cpp - ../../tabbox/tabbox_logging.cpp - test_tabbox_handler.cpp - mock_tabboxhandler.cpp - mock_tabboxclient.cpp +set(testTabBoxHandler_SRCS + ../../tabbox/clientmodel.cpp + ../../tabbox/desktopmodel.cpp + ../../tabbox/tabbox_logging.cpp + ../../tabbox/tabboxconfig.cpp + ../../tabbox/tabboxhandler.cpp + mock_tabboxclient.cpp + mock_tabboxhandler.cpp + test_tabbox_handler.cpp ) -add_executable( testTabBoxHandler ${testTabBoxHandler_SRCS} ) +add_executable(testTabBoxHandler ${testTabBoxHandler_SRCS}) set_target_properties(testTabBoxHandler PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") -target_link_libraries( testTabBoxHandler - Qt5::Core - Qt5::Widgets - Qt5::Script - Qt5::Quick - Qt5::Test - Qt5::DBus - Qt5::X11Extras +target_link_libraries(testTabBoxHandler KF5::ConfigCore KF5::I18n KF5::Package KF5::WindowSystem + Qt5::Core + Qt5::DBus + Qt5::Quick + Qt5::Script + Qt5::Test + Qt5::Widgets + Qt5::X11Extras XCB::XCB ) add_test(NAME kwin-testTabBoxHandler COMMAND testTabBoxHandler) @@ -69,14 +69,14 @@ ecm_mark_as_test(testTabBoxHandler) ######################################################## # Test TabBox::TabBoxConfig ######################################################## -set( testTabBoxConfig_SRCS - ../../tabbox/tabboxconfig.cpp +set(testTabBoxConfig_SRCS ../../tabbox/tabbox_logging.cpp + ../../tabbox/tabboxconfig.cpp test_tabbox_config.cpp ) -add_executable( testTabBoxConfig ${testTabBoxConfig_SRCS} ) -target_link_libraries( testTabBoxConfig Qt5::Core Qt5::Test ) +add_executable(testTabBoxConfig ${testTabBoxConfig_SRCS}) +target_link_libraries(testTabBoxConfig Qt5::Core Qt5::Test) add_test(NAME kwin-testTabBoxConfig COMMAND testTabBoxConfig) ecm_mark_as_test(testTabBoxConfig) @@ -84,13 +84,13 @@ ecm_mark_as_test(testTabBoxConfig) ######################################################## # Test TabBox::DesktopChainManager ######################################################## -set( testDesktopChain_SRCS +set(testDesktopChain_SRCS ../../tabbox/desktopchain.cpp ../../tabbox/tabbox_logging.cpp test_desktopchain.cpp ) -add_executable( testDesktopChain ${testDesktopChain_SRCS} ) -target_link_libraries( testDesktopChain Qt5::Core Qt5::Test ) +add_executable(testDesktopChain ${testDesktopChain_SRCS}) +target_link_libraries(testDesktopChain Qt5::Core Qt5::Test) add_test(NAME kwin-testDesktopChain COMMAND testDesktopChain) ecm_mark_as_test(testDesktopChain) diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt index 7de5ca41db..77148b94c1 100644 --- a/data/CMakeLists.txt +++ b/data/CMakeLists.txt @@ -1,13 +1,14 @@ add_subdirectory(icons) ########### next target ############### -add_executable( kwin5_update_default_rules update_default_rules.cpp) - -target_link_libraries( kwin5_update_default_rules Qt5::Core Qt5::DBus KF5::ConfigCore ) - -install(TARGETS kwin5_update_default_rules DESTINATION ${LIB_INSTALL_DIR}/kconf_update_bin/ ) +add_executable(kwin5_update_default_rules update_default_rules.cpp) +target_link_libraries(kwin5_update_default_rules + KF5::ConfigCore + Qt5::Core + Qt5::DBus +) +install(TARGETS kwin5_update_default_rules DESTINATION ${LIB_INSTALL_DIR}/kconf_update_bin/) ########### install files ############### -install(FILES org_kde_kwin.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR}) - +install(FILES org_kde_kwin.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR}) diff --git a/effects/CMakeLists.txt b/effects/CMakeLists.txt index 64d314984a..5ebaf47a7d 100644 --- a/effects/CMakeLists.txt +++ b/effects/CMakeLists.txt @@ -7,7 +7,7 @@ set(kwin_effect_OWN_LIBS kwineffects ) -if( KWIN_HAVE_XRENDER_COMPOSITING ) +if (KWIN_HAVE_XRENDER_COMPOSITING) set(kwin_effect_OWN_LIBS ${kwin_effect_OWN_LIBS} kwinxrenderutils) endif() @@ -16,11 +16,11 @@ set(kwin_effect_KDE_LIBS KF5::ConfigWidgets KF5::GlobalAccel KF5::I18n - KF5::WindowSystem - KF5::Plasma # screenedge effect KF5::IconThemes - KF5::Service KF5::Notifications # screenshot effect + KF5::Plasma # screenedge effect + KF5::Service + KF5::WindowSystem ) set(kwin_effect_QT_LIBS @@ -35,53 +35,58 @@ set(kwin_effect_XLIB_LIBS ) set(kwin_effect_XCB_LIBS - XCB::XCB XCB::IMAGE + XCB::XCB XCB::XFIXES ) -if( KWIN_HAVE_XRENDER_COMPOSITING ) +if (KWIN_HAVE_XRENDER_COMPOSITING) set(kwin_effect_XCB_LIBS ${kwin_effect_XCB_LIBS} XCB::RENDER) endif() set(kwin_effect_OWN_LIBS ${kwin_effect_OWN_LIBS} kwinglutils) -macro( KWIN4_ADD_EFFECT_BACKEND name ) - add_library( ${name} SHARED ${ARGN} ) - target_link_libraries( ${name} PRIVATE ${kwin_effect_OWN_LIBS} ${kwin_effect_KDE_LIBS} ${kwin_effect_QT_LIBS} ${kwin_effect_XLIB_LIBS} ${kwin_effect_XCB_LIBS}) +macro(KWIN4_ADD_EFFECT_BACKEND name) + add_library(${name} SHARED ${ARGN}) + target_link_libraries(${name} PRIVATE + ${kwin_effect_KDE_LIBS} + ${kwin_effect_OWN_LIBS} + ${kwin_effect_QT_LIBS} + ${kwin_effect_XCB_LIBS} + ${kwin_effect_XLIB_LIBS} + ) endmacro() # Adds effect plugin with given name. Sources are given after the name -macro( KWIN4_ADD_EFFECT name ) +macro(KWIN4_ADD_EFFECT name) kwin4_add_effect_backend(kwin4_effect_${name} ${ARGN}) - set_target_properties(kwin4_effect_${name} PROPERTIES VERSION 1.0.0 SOVERSION 1 ) + set_target_properties(kwin4_effect_${name} PROPERTIES VERSION 1.0.0 SOVERSION 1) set_target_properties(kwin4_effect_${name} PROPERTIES OUTPUT_NAME ${KWIN_NAME}4_effect_${name}) - install(TARGETS kwin4_effect_${name} ${INSTALL_TARGETS_DEFAULT_ARGS} ) - + install(TARGETS kwin4_effect_${name} ${INSTALL_TARGETS_DEFAULT_ARGS}) endmacro() # Install the KWin/Effect service type -install( FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) +install(FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) # Create initial variables -set( kwin4_effect_include_directories ) +set(kwin4_effect_include_directories) -set( kwin4_effect_builtins_sources - logging.cpp - effect_builtins.cpp +set(kwin4_effect_builtins_sources blur/blur.cpp blur/blurshader.cpp colorpicker/colorpicker.cpp + coverswitch/coverswitch.cpp cube/cube.cpp cube/cube_proxy.cpp cubeslide/cubeslide.cpp - coverswitch/coverswitch.cpp desktopgrid/desktopgrid.cpp diminactive/diminactive.cpp + effect_builtins.cpp flipswitch/flipswitch.cpp glide/glide.cpp invert/invert.cpp + logging.cpp lookingglass/lookingglass.cpp magiclamp/magiclamp.cpp magnifier/magnifier.cpp @@ -99,15 +104,15 @@ set( kwin4_effect_builtins_sources windowgeometry/windowgeometry.cpp wobblywindows/wobblywindows.cpp zoom/zoom.cpp - ) +) -qt5_add_resources( kwin4_effect_builtins_sources shaders.qrc ) +qt5_add_resources(kwin4_effect_builtins_sources shaders.qrc) kconfig_add_kcfg_files(kwin4_effect_builtins_sources blur/blurconfig.kcfgc + coverswitch/coverswitchconfig.kcfgc cube/cubeconfig.kcfgc cubeslide/cubeslideconfig.kcfgc - coverswitch/coverswitchconfig.kcfgc desktopgrid/desktopgridconfig.kcfgc diminactive/diminactiveconfig.kcfgc fallapart/fallapartconfig.kcfgc @@ -128,7 +133,7 @@ kconfig_add_kcfg_files(kwin4_effect_builtins_sources windowgeometry/windowgeometryconfig.kcfgc wobblywindows/wobblywindowsconfig.kcfgc zoom/zoomconfig.kcfgc - ) +) # scripted effects function(install_scripted_effect name) @@ -157,45 +162,45 @@ install_scripted_effect(windowaperture) # Built-in effects go here # Common effects -add_subdirectory( desktopgrid ) -add_subdirectory( diminactive ) -include( fallapart/CMakeLists.txt ) -include( highlightwindow/CMakeLists.txt ) -include( kscreen/CMakeLists.txt ) -add_subdirectory( magiclamp ) -add_subdirectory( presentwindows ) -add_subdirectory( resize ) -include( screenedge/CMakeLists.txt ) -add_subdirectory( showfps ) -add_subdirectory( showpaint ) -add_subdirectory( slide ) -include( slideback/CMakeLists.txt ) -include( slidingpopups/CMakeLists.txt ) -add_subdirectory( thumbnailaside ) -add_subdirectory( windowgeometry ) -add_subdirectory( zoom ) +add_subdirectory(desktopgrid) +add_subdirectory(diminactive) +include(fallapart/CMakeLists.txt) +include(highlightwindow/CMakeLists.txt) +include(kscreen/CMakeLists.txt) +add_subdirectory(magiclamp) +add_subdirectory(presentwindows) +add_subdirectory(resize) +include(screenedge/CMakeLists.txt) +add_subdirectory(showfps) +add_subdirectory(showpaint) +add_subdirectory(slide) +include(slideback/CMakeLists.txt) +include(slidingpopups/CMakeLists.txt) +add_subdirectory(thumbnailaside) +add_subdirectory(windowgeometry) +add_subdirectory(zoom) # OpenGL-specific effects -add_subdirectory( blur ) -include( backgroundcontrast/CMakeLists.txt ) -add_subdirectory( coverswitch ) -add_subdirectory( cube ) -add_subdirectory( cubeslide ) -add_subdirectory( flipswitch ) -add_subdirectory( glide ) -add_subdirectory( invert ) -add_subdirectory( lookingglass ) -add_subdirectory( magnifier ) -add_subdirectory( mouseclick ) -add_subdirectory( mousemark ) -include( screenshot/CMakeLists.txt ) -include( sheet/CMakeLists.txt ) -include( snaphelper/CMakeLists.txt ) -include( startupfeedback/CMakeLists.txt ) -add_subdirectory( trackmouse ) -add_subdirectory( wobblywindows ) +add_subdirectory(blur) +include(backgroundcontrast/CMakeLists.txt) +add_subdirectory(coverswitch) +add_subdirectory(cube) +add_subdirectory(cubeslide) +add_subdirectory(flipswitch) +add_subdirectory(glide) +add_subdirectory(invert) +add_subdirectory(lookingglass) +add_subdirectory(magnifier) +add_subdirectory(mouseclick) +add_subdirectory(mousemark) +include(screenshot/CMakeLists.txt) +include(sheet/CMakeLists.txt) +include(snaphelper/CMakeLists.txt) +include(startupfeedback/CMakeLists.txt) +add_subdirectory(trackmouse) +add_subdirectory(wobblywindows) ############################################################################### # Add the builtins plugin -kwin4_add_effect( builtins ${kwin4_effect_builtins_sources} ) +kwin4_add_effect(builtins ${kwin4_effect_builtins_sources}) diff --git a/effects/backgroundcontrast/CMakeLists.txt b/effects/backgroundcontrast/CMakeLists.txt index 44ffb6ce41..c6cbcf8a89 100644 --- a/effects/backgroundcontrast/CMakeLists.txt +++ b/effects/backgroundcontrast/CMakeLists.txt @@ -2,6 +2,7 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} - backgroundcontrast/contrast.cpp - backgroundcontrast/contrastshader.cpp ) +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + backgroundcontrast/contrast.cpp + backgroundcontrast/contrastshader.cpp +) diff --git a/effects/blur/CMakeLists.txt b/effects/blur/CMakeLists.txt index b4c99d32ed..7a84e4ee5a 100644 --- a/effects/blur/CMakeLists.txt +++ b/effects/blur/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_blur_config_SRCS blurconfig.kcfgc) add_library(kwin_blur_config MODULE ${kwin_blur_config_SRCS}) target_link_libraries(kwin_blur_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_blur_config blur_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/coverswitch/CMakeLists.txt b/effects/coverswitch/CMakeLists.txt index c1a6aed917..af789e8c9d 100644 --- a/effects/coverswitch/CMakeLists.txt +++ b/effects/coverswitch/CMakeLists.txt @@ -11,10 +11,10 @@ kconfig_add_kcfg_files(kwin_coverswitch_config_SRCS coverswitchconfig.kcfgc) add_library(kwin_coverswitch_config MODULE ${kwin_coverswitch_config_SRCS}) target_link_libraries(kwin_coverswitch_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_coverswitch_config coverswitch_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/cube/CMakeLists.txt b/effects/cube/CMakeLists.txt index ee9e52c90b..ae06792b76 100644 --- a/effects/cube/CMakeLists.txt +++ b/effects/cube/CMakeLists.txt @@ -2,9 +2,7 @@ # Effect # Data files -install( FILES - data/cubecap.png - DESTINATION ${DATA_INSTALL_DIR}/kwin ) +install(FILES data/cubecap.png DESTINATION ${DATA_INSTALL_DIR}/kwin) ####################################### # Config diff --git a/effects/cubeslide/CMakeLists.txt b/effects/cubeslide/CMakeLists.txt index 3d3a29fa7a..8bb5951219 100644 --- a/effects/cubeslide/CMakeLists.txt +++ b/effects/cubeslide/CMakeLists.txt @@ -9,10 +9,10 @@ kconfig_add_kcfg_files(kwin_cubeslide_config_SRCS cubeslideconfig.kcfgc) add_library(kwin_cubeslide_config MODULE ${kwin_cubeslide_config_SRCS}) target_link_libraries(kwin_cubeslide_config - kwineffects KF5::ConfigWidgets KF5::I18n KF5::Service + kwineffects ) kcoreaddons_desktop_to_json(kwin_cubeslide_config cubeslide_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/desktopgrid/CMakeLists.txt b/effects/desktopgrid/CMakeLists.txt index 57df02ea35..151021ace0 100644 --- a/effects/desktopgrid/CMakeLists.txt +++ b/effects/desktopgrid/CMakeLists.txt @@ -1,9 +1,6 @@ ####################################### # Effect -install( FILES - main.qml - DESTINATION ${DATA_INSTALL_DIR}/kwin/effects/desktopgrid/ -) +install(FILES main.qml DESTINATION ${DATA_INSTALL_DIR}/kwin/effects/desktopgrid/) ####################################### # Config @@ -15,14 +12,14 @@ kconfig_add_kcfg_files(kwin_desktopgrid_config_SRCS desktopgridconfig.kcfgc) add_library(kwin_desktopgrid_config MODULE ${kwin_desktopgrid_config_SRCS}) target_link_libraries(kwin_desktopgrid_config - kwineffects - Qt5::Quick KF5::Completion KF5::ConfigWidgets KF5::GlobalAccel KF5::I18n KF5::Service KF5::XmlGui + Qt5::Quick + kwineffects ) kcoreaddons_desktop_to_json(kwin_desktopgrid_config desktopgrid_config.desktop SERVICE_TYPES kcmodule.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/diminactive/CMakeLists.txt b/effects/diminactive/CMakeLists.txt index f19f36a4dd..dc9e46711e 100644 --- a/effects/diminactive/CMakeLists.txt +++ b/effects/diminactive/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_diminactive_config_SRCS diminactiveconfig.kcfgc) add_library(kwin_diminactive_config MODULE ${kwin_diminactive_config_SRCS}) target_link_libraries(kwin_diminactive_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_diminactive_config diminactive_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/fallapart/CMakeLists.txt b/effects/fallapart/CMakeLists.txt index 7f1d43e711..00ff7c854e 100644 --- a/effects/fallapart/CMakeLists.txt +++ b/effects/fallapart/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} fallapart/fallapart.cpp - ) +) diff --git a/effects/glide/CMakeLists.txt b/effects/glide/CMakeLists.txt index 4ae578c711..9beb587820 100644 --- a/effects/glide/CMakeLists.txt +++ b/effects/glide/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_glide_config_SRCS glideconfig.kcfgc) add_library(kwin_glide_config MODULE ${kwin_glide_config_SRCS}) target_link_libraries(kwin_glide_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_glide_config glide_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/highlightwindow/CMakeLists.txt b/effects/highlightwindow/CMakeLists.txt index c459335bd5..712c4a65b7 100644 --- a/effects/highlightwindow/CMakeLists.txt +++ b/effects/highlightwindow/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} highlightwindow/highlightwindow.cpp - ) +) diff --git a/effects/kscreen/CMakeLists.txt b/effects/kscreen/CMakeLists.txt index 46e97f8c40..a6f865337e 100644 --- a/effects/kscreen/CMakeLists.txt +++ b/effects/kscreen/CMakeLists.txt @@ -2,8 +2,8 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} - kscreen/kscreen.cpp +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} + kscreen/kscreen.cpp ) kconfig_add_kcfg_files(kwin4_effect_builtins_sources kscreen/kscreenconfig.kcfgc) diff --git a/effects/magiclamp/CMakeLists.txt b/effects/magiclamp/CMakeLists.txt index c1dc01158c..073546bf20 100644 --- a/effects/magiclamp/CMakeLists.txt +++ b/effects/magiclamp/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_magiclamp_config_SRCS magiclampconfig.kcfgc) add_library(kwin_magiclamp_config MODULE ${kwin_magiclamp_config_SRCS}) target_link_libraries(kwin_magiclamp_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_magiclamp_config magiclamp_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/presentwindows/CMakeLists.txt b/effects/presentwindows/CMakeLists.txt index b49d3138e7..c513fad880 100644 --- a/effects/presentwindows/CMakeLists.txt +++ b/effects/presentwindows/CMakeLists.txt @@ -1,9 +1,6 @@ ####################################### # Effect -install( FILES - main.qml - DESTINATION ${DATA_INSTALL_DIR}/kwin/effects/presentwindows/ -) +install(FILES main.qml DESTINATION ${DATA_INSTALL_DIR}/kwin/effects/presentwindows/) ####################################### # Config diff --git a/effects/resize/CMakeLists.txt b/effects/resize/CMakeLists.txt index 763f2dae33..b6b77ed572 100644 --- a/effects/resize/CMakeLists.txt +++ b/effects/resize/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_resize_config_SRCS resizeconfig.kcfgc) add_library(kwin_resize_config MODULE ${kwin_resize_config_SRCS}) target_link_libraries(kwin_resize_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_resize_config resize_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/screenedge/CMakeLists.txt b/effects/screenedge/CMakeLists.txt index fb1240e437..3504971fb0 100644 --- a/effects/screenedge/CMakeLists.txt +++ b/effects/screenedge/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} screenedge/screenedgeeffect.cpp - ) +) diff --git a/effects/screenshot/CMakeLists.txt b/effects/screenshot/CMakeLists.txt index ddf46df3c5..c0f6d4a220 100644 --- a/effects/screenshot/CMakeLists.txt +++ b/effects/screenshot/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} screenshot/screenshot.cpp - ) +) diff --git a/effects/sheet/CMakeLists.txt b/effects/sheet/CMakeLists.txt index ffd0a8b6c4..fc680bc0a9 100644 --- a/effects/sheet/CMakeLists.txt +++ b/effects/sheet/CMakeLists.txt @@ -2,7 +2,7 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} sheet/sheet.cpp - ) +) kconfig_add_kcfg_files(kwin4_effect_builtins_sources sheet/sheetconfig.kcfgc) diff --git a/effects/showfps/CMakeLists.txt b/effects/showfps/CMakeLists.txt index 564c4e7d49..3bdb7d24c0 100644 --- a/effects/showfps/CMakeLists.txt +++ b/effects/showfps/CMakeLists.txt @@ -8,11 +8,11 @@ kconfig_add_kcfg_files(kwin_showfps_config_SRCS showfpsconfig.kcfgc) add_library(kwin_showfps_config MODULE ${kwin_showfps_config_SRCS}) target_link_libraries(kwin_showfps_config - Qt5::DBus KF5::Completion KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_showfps_config showfps_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/slide/CMakeLists.txt b/effects/slide/CMakeLists.txt index fa35bef2ae..2a974cd9d2 100644 --- a/effects/slide/CMakeLists.txt +++ b/effects/slide/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_slide_config_SRCS slideconfig.kcfgc) add_library(kwin_slide_config MODULE ${kwin_slide_config_SRCS}) target_link_libraries(kwin_slide_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_slide_config slide_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/effects/slideback/CMakeLists.txt b/effects/slideback/CMakeLists.txt index 1564954f41..aa865fb5c2 100644 --- a/effects/slideback/CMakeLists.txt +++ b/effects/slideback/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} slideback/slideback.cpp - ) +) diff --git a/effects/slidingpopups/CMakeLists.txt b/effects/slidingpopups/CMakeLists.txt index b3de9b5988..79246695b8 100644 --- a/effects/slidingpopups/CMakeLists.txt +++ b/effects/slidingpopups/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} slidingpopups/slidingpopups.cpp - ) +) diff --git a/effects/snaphelper/CMakeLists.txt b/effects/snaphelper/CMakeLists.txt index 6b7b980946..73172eb300 100644 --- a/effects/snaphelper/CMakeLists.txt +++ b/effects/snaphelper/CMakeLists.txt @@ -2,6 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} snaphelper/snaphelper.cpp - ) +) diff --git a/effects/startupfeedback/CMakeLists.txt b/effects/startupfeedback/CMakeLists.txt index 19a37836fa..da311aa6ea 100644 --- a/effects/startupfeedback/CMakeLists.txt +++ b/effects/startupfeedback/CMakeLists.txt @@ -2,9 +2,6 @@ # Effect # Source files -set( kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} +set(kwin4_effect_builtins_sources ${kwin4_effect_builtins_sources} startupfeedback/startupfeedback.cpp - ) - -####################################### -# Config +) diff --git a/effects/trackmouse/CMakeLists.txt b/effects/trackmouse/CMakeLists.txt index 471b9ab4d6..19bad9f875 100644 --- a/effects/trackmouse/CMakeLists.txt +++ b/effects/trackmouse/CMakeLists.txt @@ -1,10 +1,7 @@ ####################################### # Effect # Data files -install( FILES - data/tm_inner.png - data/tm_outer.png - DESTINATION ${DATA_INSTALL_DIR}/kwin ) +install(FILES data/tm_inner.png data/tm_outer.png DESTINATION ${DATA_INSTALL_DIR}/kwin) ####################################### # Config diff --git a/effects/wobblywindows/CMakeLists.txt b/effects/wobblywindows/CMakeLists.txt index 6d9d4acdd8..f3e78392d5 100644 --- a/effects/wobblywindows/CMakeLists.txt +++ b/effects/wobblywindows/CMakeLists.txt @@ -8,10 +8,10 @@ kconfig_add_kcfg_files(kwin_wobblywindows_config_SRCS wobblywindowsconfig.kcfgc) add_library(kwin_wobblywindows_config MODULE ${kwin_wobblywindows_config_SRCS}) target_link_libraries(kwin_wobblywindows_config - Qt5::DBus KF5::ConfigWidgets KF5::I18n KF5::Service + Qt5::DBus ) kcoreaddons_desktop_to_json(kwin_wobblywindows_config wobblywindows_config.desktop SERVICE_TYPES kcmodule.desktop) diff --git a/helpers/killer/CMakeLists.txt b/helpers/killer/CMakeLists.txt index 9468eaf55b..79812b38d9 100644 --- a/helpers/killer/CMakeLists.txt +++ b/helpers/killer/CMakeLists.txt @@ -1,16 +1,15 @@ ########### next target ############### -set(kwin_killer_helper_SRCS killer.cpp ) - +set(kwin_killer_helper_SRCS killer.cpp) add_executable(kwin_killer_helper ${kwin_killer_helper_SRCS}) target_link_libraries(kwin_killer_helper - Qt5::Widgets - Qt5::X11Extras KF5::AuthCore KF5::I18n KF5::WidgetsAddons + Qt5::Widgets + Qt5::X11Extras ) -install(TARGETS kwin_killer_helper DESTINATION ${LIBEXEC_INSTALL_DIR} ) +install(TARGETS kwin_killer_helper DESTINATION ${LIBEXEC_INSTALL_DIR}) diff --git a/kcmkwin/CMakeLists.txt b/kcmkwin/CMakeLists.txt index 258650680a..c3de9340ac 100644 --- a/kcmkwin/CMakeLists.txt +++ b/kcmkwin/CMakeLists.txt @@ -1,15 +1,15 @@ remove_definitions(-DQT_NO_CAST_FROM_ASCII -DQT_STRICT_ITERATORS -DQT_NO_CAST_FROM_BYTEARRAY -DQT_NO_KEYWORDS) -add_subdirectory( common ) -add_subdirectory( kwincompositing ) -add_subdirectory( kwinoptions ) -add_subdirectory( kwindecoration ) -add_subdirectory( kwinrules ) -add_subdirectory( kwinscreenedges ) -add_subdirectory( kwinscripts ) -add_subdirectory( kwindesktop ) -add_subdirectory( kwineffects ) +add_subdirectory(common) +add_subdirectory(kwincompositing) +add_subdirectory(kwinoptions) +add_subdirectory(kwindecoration) +add_subdirectory(kwinrules) +add_subdirectory(kwinscreenedges) +add_subdirectory(kwinscripts) +add_subdirectory(kwindesktop) +add_subdirectory(kwineffects) -if( KWIN_BUILD_TABBOX ) -add_subdirectory( kwintabbox ) +if (KWIN_BUILD_TABBOX) + add_subdirectory(kwintabbox) endif() diff --git a/kcmkwin/kwincompositing/CMakeLists.txt b/kcmkwin/kwincompositing/CMakeLists.txt index 651993714c..adbf3b6b49 100644 --- a/kcmkwin/kwincompositing/CMakeLists.txt +++ b/kcmkwin/kwincompositing/CMakeLists.txt @@ -10,24 +10,25 @@ remove_definitions(-DQT_NO_CAST_FROM_ASCII -DQT_STRICT_ITERATORS -DQT_NO_CAST_FR set(kwincomposing_SRC main.cpp - compositing.cpp) + compositing.cpp +) -qt5_add_dbus_interface( kwincomposing_SRC - ${KWIN_SOURCE_DIR}/org.kde.kwin.Compositing.xml kwin_compositing_interface) +qt5_add_dbus_interface(kwincomposing_SRC + ${KWIN_SOURCE_DIR}/org.kde.kwin.Compositing.xml kwin_compositing_interface +) ki18n_wrap_ui(kwincomposing_SRC compositing.ui) add_library(kwincompositing MODULE ${kwincomposing_SRC}) target_link_libraries(kwincompositing - Qt5::DBus - Qt5::Widgets - KF5::CoreAddons KF5::ConfigCore + KF5::CoreAddons KF5::I18n KF5::KCMUtils + Qt5::DBus + Qt5::Widgets ) -INSTALL(TARGETS kwincompositing DESTINATION ${PLUGIN_INSTALL_DIR}) -install(FILES kwincompositing.desktop DESTINATION ${SERVICES_INSTALL_DIR}) -################# list the subdirectories ################# +install(TARGETS kwincompositing DESTINATION ${PLUGIN_INSTALL_DIR}) +install(FILES kwincompositing.desktop DESTINATION ${SERVICES_INSTALL_DIR}) diff --git a/kcmkwin/kwindecoration/CMakeLists.txt b/kcmkwin/kwindecoration/CMakeLists.txt index 461e858fb0..f591f69d5e 100644 --- a/kcmkwin/kwindecoration/CMakeLists.txt +++ b/kcmkwin/kwindecoration/CMakeLists.txt @@ -4,10 +4,10 @@ add_definitions(-DTRANSLATION_DOMAIN=\"kcm_kwindecoration\") add_subdirectory(declarative-plugin) set(kcmkwindecoration_SRCS + declarative-plugin/buttonsmodel.cpp + decorationmodel.cpp kcm.cpp utils.cpp - decorationmodel.cpp - declarative-plugin/buttonsmodel.cpp ) add_library(kcm_kwindecoration MODULE ${kcmkwindecoration_SRCS}) @@ -15,8 +15,8 @@ add_library(kcm_kwindecoration MODULE ${kcmkwindecoration_SRCS}) target_link_libraries(kcm_kwindecoration KDecoration2::KDecoration KF5::I18n - KF5::QuickAddons KF5::NewStuff + KF5::QuickAddons Qt5::Quick ) diff --git a/kcmkwin/kwindesktop/CMakeLists.txt b/kcmkwin/kwindesktop/CMakeLists.txt index 8cb9c5a61d..dabfc1ef26 100644 --- a/kcmkwin/kwindesktop/CMakeLists.txt +++ b/kcmkwin/kwindesktop/CMakeLists.txt @@ -7,20 +7,20 @@ add_definitions(-DTRANSLATION_DOMAIN=\"kcm_kwin_virtualdesktops\") ########### next target ############### set(kcm_kwin_virtualdesktops_PART_SRCS - virtualdesktops.cpp + ../../virtualdesktopsdbustypes.cpp animationsmodel.cpp desktopsmodel.cpp - ../../virtualdesktopsdbustypes.cpp + virtualdesktops.cpp ) add_library(kcm_kwin_virtualdesktops MODULE ${kcm_kwin_virtualdesktops_PART_SRCS}) target_link_libraries(kcm_kwin_virtualdesktops - Qt5::DBus KF5::I18n KF5::KCMUtils KF5::QuickAddons KF5::XmlGui + Qt5::DBus kcmkwincommon ) @@ -31,4 +31,3 @@ kcoreaddons_desktop_to_json(kcm_kwin_virtualdesktops "kcm_kwin_virtualdesktops.d install(TARGETS kcm_kwin_virtualdesktops DESTINATION ${KDE_INSTALL_PLUGINDIR}/kcms) install(FILES kcm_kwin_virtualdesktops.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR}) kpackage_install_package(package kcm_kwin_virtualdesktops kcms) - diff --git a/kcmkwin/kwineffects/CMakeLists.txt b/kcmkwin/kwineffects/CMakeLists.txt index 4a554a4b85..1d97ef1ce2 100644 --- a/kcmkwin/kwineffects/CMakeLists.txt +++ b/kcmkwin/kwineffects/CMakeLists.txt @@ -14,12 +14,12 @@ set(kcm_kwin_effects_PART_SRCS add_library(kcm_kwin_effects MODULE ${kcm_kwin_effects_PART_SRCS}) target_link_libraries(kcm_kwin_effects - Qt5::DBus KF5::I18n KF5::KCMUtils KF5::NewStuff KF5::QuickAddons KF5::XmlGui + Qt5::DBus kcmkwincommon ) diff --git a/kcmkwin/kwinoptions/CMakeLists.txt b/kcmkwin/kwinoptions/CMakeLists.txt index ea719b391a..dd7551fd72 100644 --- a/kcmkwin/kwinoptions/CMakeLists.txt +++ b/kcmkwin/kwinoptions/CMakeLists.txt @@ -2,17 +2,35 @@ # KI18N Translation Domain for this library add_definitions(-DTRANSLATION_DOMAIN=\"kcmkwm\") -set(kcm_kwinoptions_PART_SRCS windows.cpp mouse.cpp main.cpp ${KWIN_SOURCE_DIR}/effects/effect_builtins.cpp ) -ki18n_wrap_ui(kcm_kwinoptions_PART_SRCS actions.ui advanced.ui focus.ui mouse.ui moving.ui) -qt5_add_dbus_interface( kcm_kwinoptions_PART_SRCS - ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) +set(kcm_kwinoptions_PART_SRCS + ${KWIN_SOURCE_DIR}/effects/effect_builtins.cpp + main.cpp + mouse.cpp + windows.cpp +) + +ki18n_wrap_ui(kcm_kwinoptions_PART_SRCS + actions.ui + advanced.ui + focus.ui + mouse.ui + moving.ui +) + +qt5_add_dbus_interface(kcm_kwinoptions_PART_SRCS ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) add_library(kcm_kwinoptions MODULE ${kcm_kwinoptions_PART_SRCS}) target_link_libraries(kcm_kwinoptions Qt5::DBus KF5::Completion KF5::I18n KF5::ConfigWidgets KF5::Service KF5::WindowSystem) -install(TARGETS kcm_kwinoptions DESTINATION ${PLUGIN_INSTALL_DIR} ) - +install(TARGETS kcm_kwinoptions DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### -install( FILES kwinoptions.desktop kwinactions.desktop kwinadvanced.desktop - kwinfocus.desktop kwinmoving.desktop - DESTINATION ${SERVICES_INSTALL_DIR}) +install( + FILES + kwinactions.desktop + kwinadvanced.desktop + kwinfocus.desktop + kwinmoving.desktop + kwinoptions.desktop + DESTINATION + ${SERVICES_INSTALL_DIR} +) diff --git a/kcmkwin/kwinrules/CMakeLists.txt b/kcmkwin/kwinrules/CMakeLists.txt index 34bc7cbaca..31d1e03415 100644 --- a/kcmkwin/kwinrules/CMakeLists.txt +++ b/kcmkwin/kwinrules/CMakeLists.txt @@ -4,7 +4,7 @@ add_definitions(-DKCMRULES) ########### next target ############### include_directories(../../) -set (kwinrules_MOC_HDRS yesnobox.h ../../cursor.h ../../plugins/platforms/x11/standalone/x11cursor.h) +set(kwinrules_MOC_HDRS yesnobox.h ../../cursor.h ../../plugins/platforms/x11/standalone/x11cursor.h) qt5_wrap_cpp(kwinrules_MOC_SRCS ${kwinrules_MOC_HDRS}) set(kwinrules_SRCS ruleswidget.cpp ruleslist.cpp kwinsrc.cpp detectwidget.cpp ${kwinrules_MOC_SRCS}) @@ -12,51 +12,44 @@ ki18n_wrap_ui(kwinrules_SRCS ruleslist.ui detectwidget.ui editshortcut.ui rulesw set(kwin_rules_dialog_KDEINIT_SRCS main.cpp ${kwinrules_SRCS}) -kf5_add_kdeinit_executable( kwin_rules_dialog ${kwin_rules_dialog_KDEINIT_SRCS}) +kf5_add_kdeinit_executable(kwin_rules_dialog ${kwin_rules_dialog_KDEINIT_SRCS}) set(kwin_kcm_rules_XCB_LIBS + XCB::CURSOR XCB::XCB XCB::XFIXES - XCB::CURSOR ) set(kcm_libs - Qt5::Concurrent - Qt5::X11Extras KF5::Completion KF5::ConfigWidgets KF5::I18n KF5::Service KF5::WindowSystem KF5::XmlGui + Qt5::Concurrent + Qt5::X11Extras ) -if(KWIN_BUILD_ACTIVITIES) +if (KWIN_BUILD_ACTIVITIES) set(kcm_libs ${kcm_libs} KF5::Activities) endif() target_link_libraries(kdeinit_kwin_rules_dialog ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS}) -install(TARGETS kdeinit_kwin_rules_dialog ${INSTALL_TARGETS_DEFAULT_ARGS} ) -install(TARGETS kwin_rules_dialog DESTINATION ${LIBEXEC_INSTALL_DIR} ) +install(TARGETS kdeinit_kwin_rules_dialog ${INSTALL_TARGETS_DEFAULT_ARGS}) +install(TARGETS kwin_rules_dialog DESTINATION ${LIBEXEC_INSTALL_DIR}) ########### next target ############### set(kcm_kwinrules_PART_SRCS kcm.cpp ${kwinrules_SRCS}) - add_library(kcm_kwinrules MODULE ${kcm_kwinrules_PART_SRCS}) target_link_libraries(kcm_kwinrules ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS}) -install(TARGETS kcm_kwinrules DESTINATION ${PLUGIN_INSTALL_DIR} ) - - -########### next target ############### - +install(TARGETS kcm_kwinrules DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### -install( FILES kwinrules.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) - - +install(FILES kwinrules.desktop DESTINATION ${SERVICES_INSTALL_DIR}) diff --git a/kcmkwin/kwinscreenedges/CMakeLists.txt b/kcmkwin/kwinscreenedges/CMakeLists.txt index 42506f623e..8b1e05c136 100644 --- a/kcmkwin/kwinscreenedges/CMakeLists.txt +++ b/kcmkwin/kwinscreenedges/CMakeLists.txt @@ -2,35 +2,32 @@ add_definitions(-DTRANSLATION_DOMAIN=\"kcmkwinscreenedges\") include_directories(${KWIN_SOURCE_DIR}/effects) -set( - kcm_screenedges_SRCS +set(kcm_screenedges_SRCS monitor.cpp screenpreviewwidget.cpp - ) -qt5_add_dbus_interface( kcm_screenedges_SRCS - ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) +) +qt5_add_dbus_interface(kcm_screenedges_SRCS ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) set(kcm_kwinscreenedges_PART_SRCS main.cpp ${kcm_screenedges_SRCS}) -ki18n_wrap_ui( kcm_kwinscreenedges_PART_SRCS main.ui ) -add_library( kcm_kwinscreenedges MODULE ${kcm_kwinscreenedges_PART_SRCS} ) +ki18n_wrap_ui(kcm_kwinscreenedges_PART_SRCS main.ui) +add_library(kcm_kwinscreenedges MODULE ${kcm_kwinscreenedges_PART_SRCS}) set(kcm_screenedges_LIBS - Qt5::DBus KF5::Completion KF5::ConfigCore KF5::ConfigWidgets KF5::I18n - KF5::Service KF5::Package KF5::Plasma + KF5::Service + Qt5::DBus kwin4_effect_builtins ) -target_link_libraries( kcm_kwinscreenedges ${X11_LIBRARIES} ${kcm_screenedges_LIBS}) +target_link_libraries(kcm_kwinscreenedges ${X11_LIBRARIES} ${kcm_screenedges_LIBS}) set(kcm_kwintouchscreenedges_PART_SRCS touch.cpp ${kcm_screenedges_SRCS}) -ki18n_wrap_ui( kcm_kwintouchscreenedges_PART_SRCS touch.ui ) -add_library( kcm_kwintouchscreen MODULE ${kcm_kwintouchscreenedges_PART_SRCS} ) -target_link_libraries( kcm_kwintouchscreen ${X11_LIBRARIES} ${kcm_screenedges_LIBS}) +ki18n_wrap_ui(kcm_kwintouchscreenedges_PART_SRCS touch.ui) +add_library(kcm_kwintouchscreen MODULE ${kcm_kwintouchscreenedges_PART_SRCS}) +target_link_libraries(kcm_kwintouchscreen ${X11_LIBRARIES} ${kcm_screenedges_LIBS}) -install( TARGETS kcm_kwinscreenedges kcm_kwintouchscreen DESTINATION ${PLUGIN_INSTALL_DIR} ) - -install( FILES kwinscreenedges.desktop kwintouchscreen.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install(TARGETS kcm_kwinscreenedges kcm_kwintouchscreen DESTINATION ${PLUGIN_INSTALL_DIR}) +install(FILES kwinscreenedges.desktop kwintouchscreen.desktop DESTINATION ${SERVICES_INSTALL_DIR}) diff --git a/kcmkwin/kwinscripts/CMakeLists.txt b/kcmkwin/kwinscripts/CMakeLists.txt index 66145e9e00..b79a3f5c74 100644 --- a/kcmkwin/kwinscripts/CMakeLists.txt +++ b/kcmkwin/kwinscripts/CMakeLists.txt @@ -14,14 +14,14 @@ ki18n_wrap_ui(kcm_SRCS module.ui) add_library(kcm_kwin_scripts MODULE ${kcm_SRCS}) target_link_libraries(kcm_kwin_scripts - Qt5::DBus + KF5::I18n KF5::KCMUtils KF5::KIOCore - KF5::I18n - KF5::Package KF5::NewStuff + KF5::Package + Qt5::DBus ) install(TARGETS kcm_kwin_scripts DESTINATION ${PLUGIN_INSTALL_DIR}) install(FILES kwinscripts.desktop DESTINATION ${SERVICES_INSTALL_DIR}) -install(FILES kwinscripts.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR}) +install(FILES kwinscripts.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR}) diff --git a/kcmkwin/kwintabbox/CMakeLists.txt b/kcmkwin/kwintabbox/CMakeLists.txt index b6b932b0fe..d5a1f28c6f 100644 --- a/kcmkwin/kwintabbox/CMakeLists.txt +++ b/kcmkwin/kwintabbox/CMakeLists.txt @@ -1,40 +1,38 @@ # KI18N Translation Domain for this library add_definitions(-DTRANSLATION_DOMAIN=\"kcm_kwintabbox\") -include_directories( ${KWIN_SOURCE_DIR}/effects ${KWIN_SOURCE_DIR}/tabbox ${KWIN_SOURCE_DIR}) +include_directories(${KWIN_SOURCE_DIR}/effects ${KWIN_SOURCE_DIR}/tabbox ${KWIN_SOURCE_DIR}) ########### next target ############### set(kcm_kwintabbox_PART_SRCS - main.cpp - layoutpreview.cpp - thumbnailitem.cpp ${KWIN_SOURCE_DIR}/tabbox/tabboxconfig.cpp + layoutpreview.cpp + main.cpp + thumbnailitem.cpp ) -ki18n_wrap_ui( kcm_kwintabbox_PART_SRCS main.ui ) -qt5_add_dbus_interface( kcm_kwintabbox_PART_SRCS - ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) +ki18n_wrap_ui(kcm_kwintabbox_PART_SRCS main.ui) +qt5_add_dbus_interface(kcm_kwintabbox_PART_SRCS ${KWIN_SOURCE_DIR}/org.kde.kwin.Effects.xml kwin_effects_interface) add_library(kcm_kwintabbox MODULE ${kcm_kwintabbox_PART_SRCS}) target_link_libraries(kcm_kwintabbox - Qt5::Quick - KF5::KCMUtils KF5::Completion KF5::GlobalAccel KF5::I18n - KF5::Service + KF5::KCMUtils KF5::NewStuff KF5::Package + KF5::Service + Qt5::Quick XCB::XCB kwin4_effect_builtins ) -install(TARGETS kcm_kwintabbox DESTINATION ${PLUGIN_INSTALL_DIR} ) - +install(TARGETS kcm_kwintabbox DESTINATION ${PLUGIN_INSTALL_DIR} ) ########### install files ############### -install( FILES kwintabbox.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) -install( FILES thumbnails/konqueror.png thumbnails/kmail.png thumbnails/systemsettings.png thumbnails/dolphin.png DESTINATION ${DATA_INSTALL_DIR}/kwin/kcm_kwintabbox) -install( FILES kwinswitcher.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR} ) +install(FILES kwintabbox.desktop DESTINATION ${SERVICES_INSTALL_DIR}) +install(FILES thumbnails/konqueror.png thumbnails/kmail.png thumbnails/systemsettings.png thumbnails/dolphin.png DESTINATION ${DATA_INSTALL_DIR}/kwin/kcm_kwintabbox) +install(FILES kwinswitcher.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR}) diff --git a/libkwineffects/CMakeLists.txt b/libkwineffects/CMakeLists.txt index 29d205af3c..3cce6b5806 100644 --- a/libkwineffects/CMakeLists.txt +++ b/libkwineffects/CMakeLists.txt @@ -12,19 +12,19 @@ ecm_setup_version(${PROJECT_VERSION} set(kwin_XRENDERUTILS_SRCS kwinxrenderutils.cpp logging.cpp - ) +) add_library(kwinxrenderutils SHARED ${kwin_XRENDERUTILS_SRCS}) generate_export_header(kwinxrenderutils EXPORT_FILE_NAME kwinxrenderutils_export.h) target_link_libraries(kwinxrenderutils PUBLIC + KF5::WaylandServer Qt5::Core Qt5::Gui + XCB::RENDER XCB::XCB XCB::XFIXES - XCB::RENDER - KF5::WaylandServer - ) +) set_target_properties(kwinxrenderutils PROPERTIES VERSION ${KWINEFFECTS_VERSION_STRING} @@ -36,11 +36,11 @@ install(TARGETS kwinxrenderutils EXPORT kdeworkspaceLibraryTargets ${INSTALL_TAR ### effects lib ### set(kwin_EFFECTSLIB_SRCS - kwineffects.cpp anidata.cpp kwinanimationeffect.cpp + kwineffects.cpp logging.cpp - ) +) set(kwineffects_QT_LIBS Qt5::DBus @@ -60,12 +60,12 @@ set(kwineffects_XCB_LIBS add_library(kwineffects SHARED ${kwin_EFFECTSLIB_SRCS}) generate_export_header(kwineffects EXPORT_FILE_NAME kwineffects_export.h) target_link_libraries(kwineffects -PUBLIC - ${kwineffects_QT_LIBS} - ${kwineffects_KDE_LIBS} - ${kwineffects_XCB_LIBS} + PUBLIC + ${kwineffects_QT_LIBS} + ${kwineffects_KDE_LIBS} + ${kwineffects_XCB_LIBS} ) -if( KWIN_HAVE_XRENDER_COMPOSITING ) +if (KWIN_HAVE_XRENDER_COMPOSITING) target_link_libraries(kwineffects PRIVATE kwinxrenderutils XCB::XFIXES) endif() set_target_properties(kwineffects PROPERTIES @@ -78,14 +78,14 @@ install(TARGETS kwineffects EXPORT kdeworkspaceLibraryTargets ${INSTALL_TARGETS_ # kwingl(es)utils library set(kwin_GLUTILSLIB_SRCS - kwinglutils.cpp - kwingltexture.cpp - kwinglutils_funcs.cpp kwinglplatform.cpp + kwingltexture.cpp + kwinglutils.cpp + kwinglutils_funcs.cpp logging.cpp - ) +) -macro( KWIN4_ADD_GLUTILS_BACKEND name glinclude ) +macro(KWIN4_ADD_GLUTILS_BACKEND name glinclude) include_directories(${glinclude}) add_library(${name} SHARED ${kwin_GLUTILSLIB_SRCS}) generate_export_header(${name} BASE_NAME kwinglutils EXPORT_FILE_NAME kwinglutils_export.h) @@ -104,17 +104,17 @@ set_target_properties(kwinglutils PROPERTIES OUTPUT_NAME ${KWIN_NAME}glutils) target_link_libraries(kwinglutils PUBLIC ${epoxy_LIBRARY}) -install( FILES - kwinglobals.h - kwineffects.h - kwinanimationeffect.h - kwinglplatform.h - kwinglutils.h - kwinglutils_funcs.h - kwingltexture.h - kwinxrenderutils.h +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kwinconfig.h ${CMAKE_CURRENT_BINARY_DIR}/kwineffects_export.h ${CMAKE_CURRENT_BINARY_DIR}/kwinglutils_export.h ${CMAKE_CURRENT_BINARY_DIR}/kwinxrenderutils_export.h + kwinanimationeffect.h + kwineffects.h + kwinglobals.h + kwinglplatform.h + kwingltexture.h + kwinglutils.h + kwinglutils_funcs.h + kwinxrenderutils.h DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) diff --git a/plugins/CMakeLists.txt b/plugins/CMakeLists.txt index 1624fb2b97..9f26622d9d 100644 --- a/plugins/CMakeLists.txt +++ b/plugins/CMakeLists.txt @@ -6,6 +6,6 @@ add_subdirectory(scenes) add_subdirectory(windowsystem) add_subdirectory(kpackage) -if(KWIN_BUILD_DECORATIONS) +if (KWIN_BUILD_DECORATIONS) add_subdirectory(kdecorations) endif() diff --git a/plugins/idletime/CMakeLists.txt b/plugins/idletime/CMakeLists.txt index 21c0dc732f..1325755b03 100644 --- a/plugins/idletime/CMakeLists.txt +++ b/plugins/idletime/CMakeLists.txt @@ -5,9 +5,9 @@ set(idletime_plugin_SRCS add_library(KF5IdleTimeKWinWaylandPrivatePlugin MODULE ${idletime_plugin_SRCS}) set_target_properties(KF5IdleTimeKWinWaylandPrivatePlugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/org.kde.kidletime.platforms/") target_link_libraries(KF5IdleTimeKWinWaylandPrivatePlugin - kwin KF5::IdleTime KF5::WaylandClient + kwin ) install( diff --git a/plugins/kdecorations/CMakeLists.txt b/plugins/kdecorations/CMakeLists.txt index dacf9add6c..2bce237af0 100644 --- a/plugins/kdecorations/CMakeLists.txt +++ b/plugins/kdecorations/CMakeLists.txt @@ -1,2 +1,2 @@ add_definitions(-DTRANSLATION_DOMAIN=\"kwin_clients\") -add_subdirectory( aurorae ) +add_subdirectory(aurorae) diff --git a/plugins/kdecorations/aurorae/src/CMakeLists.txt b/plugins/kdecorations/aurorae/src/CMakeLists.txt index ea032d473a..60423766c1 100644 --- a/plugins/kdecorations/aurorae/src/CMakeLists.txt +++ b/plugins/kdecorations/aurorae/src/CMakeLists.txt @@ -1,8 +1,8 @@ ########### decoration ############### include_directories( - ./lib - ${CMAKE_CURRENT_BINARY_DIR} - ${CMAKE_CURRENT_SOURCE_DIR} + ./lib + ${CMAKE_CURRENT_BINARY_DIR} + ${CMAKE_CURRENT_SOURCE_DIR} ) set(kwin5_aurorae_PART_SRCS @@ -28,41 +28,43 @@ target_link_libraries(kwin5_aurorae install(TARGETS kwin5_aurorae DESTINATION ${PLUGIN_INSTALL_DIR}/org.kde.kdecoration2) set(decoration_plugin_SRCS - decorationplugin.cpp - decorationoptions.cpp colorhelper.cpp - ) + decorationoptions.cpp + decorationplugin.cpp +) add_library(decorationplugin SHARED ${decoration_plugin_SRCS}) set_target_properties(decorationplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org/kde/kwin/decoration/") target_link_libraries(decorationplugin - Qt5::Quick KDecoration2::KDecoration KF5::ConfigWidgets + Qt5::Quick ) install(TARGETS decorationplugin DESTINATION ${QML_INSTALL_DIR}/org/kde/kwin/decoration) ########### install files ############### -install( FILES aurorae.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR} ) -install( FILES - qml/aurorae.qml - qml/AuroraeButton.qml - qml/AuroraeButtonGroup.qml - qml/AuroraeMaximizeButton.qml - qml/Decoration.qml - qml/DecorationButton.qml - qml/MenuButton.qml - qml/AppMenuButton.qml - DESTINATION ${DATA_INSTALL_DIR}/kwin/aurorae ) +install(FILES aurorae.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR}) +install( + FILES + qml/AppMenuButton.qml + qml/AuroraeButton.qml + qml/AuroraeButtonGroup.qml + qml/AuroraeMaximizeButton.qml + qml/Decoration.qml + qml/DecorationButton.qml + qml/MenuButton.qml + qml/aurorae.qml + DESTINATION + ${DATA_INSTALL_DIR}/kwin/aurorae) set(QMLFILES - qml/Decoration.qml - qml/DecorationButton.qml - qml/MenuButton.qml qml/AppMenuButton.qml qml/ButtonGroup.qml + qml/Decoration.qml + qml/DecorationButton.qml + qml/MenuButton.qml qml/qmldir ) -install( FILES ${QMLFILES} DESTINATION ${QML_INSTALL_DIR}/org/kde/kwin/decoration ) +install(FILES ${QMLFILES} DESTINATION ${QML_INSTALL_DIR}/org/kde/kwin/decoration) file(COPY ${QMLFILES} DESTINATION ${CMAKE_BINARY_DIR}/bin/org/kde/kwin/decoration/) -install( FILES kwindecoration.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) +install(FILES kwindecoration.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) diff --git a/plugins/kdecorations/aurorae/themes/plastik/code/CMakeLists.txt b/plugins/kdecorations/aurorae/themes/plastik/code/CMakeLists.txt index cc0a3f819a..5463539077 100644 --- a/plugins/kdecorations/aurorae/themes/plastik/code/CMakeLists.txt +++ b/plugins/kdecorations/aurorae/themes/plastik/code/CMakeLists.txt @@ -1,7 +1,7 @@ set(plastik_plugin_SRCS plastikbutton.cpp plastikplugin.cpp - ) +) add_library(plastikplugin SHARED ${plastik_plugin_SRCS}) set_target_properties(plastikplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org/kde/kwin/decorations/plastik") diff --git a/plugins/platforms/CMakeLists.txt b/plugins/platforms/CMakeLists.txt index 9058f0a1ea..eef7aed045 100644 --- a/plugins/platforms/CMakeLists.txt +++ b/plugins/platforms/CMakeLists.txt @@ -1,10 +1,10 @@ -if(HAVE_DRM) +if (HAVE_DRM) add_subdirectory(drm) endif() if (HAVE_LINUX_FB_H) add_subdirectory(fbdev) endif() -if(HAVE_LIBHYBRIS) +if (HAVE_LIBHYBRIS) add_subdirectory(hwcomposer) endif() add_subdirectory(virtual) diff --git a/plugins/platforms/drm/CMakeLists.txt b/plugins/platforms/drm/CMakeLists.txt index 6a02df5ddf..eff0f8e938 100644 --- a/plugins/platforms/drm/CMakeLists.txt +++ b/plugins/platforms/drm/CMakeLists.txt @@ -13,7 +13,7 @@ set(DRM_SOURCES screens_drm.cpp ) -if(HAVE_GBM) +if (HAVE_GBM) set(DRM_SOURCES ${DRM_SOURCES} egl_gbm_backend.cpp drm_buffer_gbm.cpp @@ -22,7 +22,7 @@ if(HAVE_GBM) ) endif() -if(HAVE_EGL_STREAMS) +if (HAVE_EGL_STREAMS) set(DRM_SOURCES ${DRM_SOURCES} egl_stream_backend.cpp ) @@ -34,7 +34,7 @@ add_library(KWinWaylandDrmBackend MODULE ${DRM_SOURCES}) set_target_properties(KWinWaylandDrmBackend PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.waylandbackends/") target_link_libraries(KWinWaylandDrmBackend kwin Libdrm::Libdrm SceneQPainterBackend SceneOpenGLBackend) -if(HAVE_GBM) +if (HAVE_GBM) target_link_libraries(KWinWaylandDrmBackend gbm::gbm) endif() diff --git a/plugins/platforms/hwcomposer/CMakeLists.txt b/plugins/platforms/hwcomposer/CMakeLists.txt index 772d4e86a3..c3cbf5dde7 100644 --- a/plugins/platforms/hwcomposer/CMakeLists.txt +++ b/plugins/platforms/hwcomposer/CMakeLists.txt @@ -9,11 +9,11 @@ include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl) add_library(KWinWaylandHwcomposerBackend MODULE ${HWCOMPOSER_SOURCES}) set_target_properties(KWinWaylandHwcomposerBackend PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.waylandbackends/") target_link_libraries(KWinWaylandHwcomposerBackend + SceneOpenGLBackend kwin - libhybris::libhardware libhybris::hwcomposer libhybris::hybriseglplatform - SceneOpenGLBackend + libhybris::libhardware ) install( diff --git a/plugins/platforms/virtual/CMakeLists.txt b/plugins/platforms/virtual/CMakeLists.txt index 532a8857f2..ae63d08152 100644 --- a/plugins/platforms/virtual/CMakeLists.txt +++ b/plugins/platforms/virtual/CMakeLists.txt @@ -1,9 +1,9 @@ set(VIRTUAL_SOURCES egl_gbm_backend.cpp - virtual_backend.cpp - virtual_output.cpp scene_qpainter_virtual_backend.cpp screens_virtual.cpp + virtual_backend.cpp + virtual_output.cpp ) include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl) diff --git a/plugins/platforms/wayland/CMakeLists.txt b/plugins/platforms/wayland/CMakeLists.txt index 733a6acfeb..13320b4dc4 100644 --- a/plugins/platforms/wayland/CMakeLists.txt +++ b/plugins/platforms/wayland/CMakeLists.txt @@ -5,7 +5,7 @@ set(WAYLAND_BACKEND_SOURCES wayland_output.cpp ) -if(HAVE_WAYLAND_EGL) +if (HAVE_WAYLAND_EGL) set(WAYLAND_BACKEND_SOURCES egl_wayland_backend.cpp ${WAYLAND_BACKEND_SOURCES}) endif() @@ -14,7 +14,7 @@ add_library(KWinWaylandWaylandBackend MODULE ${WAYLAND_BACKEND_SOURCES}) set_target_properties(KWinWaylandWaylandBackend PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.waylandbackends/") target_link_libraries(KWinWaylandWaylandBackend kwin KF5::WaylandClient SceneQPainterBackend) -if(HAVE_WAYLAND_EGL) +if (HAVE_WAYLAND_EGL) target_link_libraries(KWinWaylandWaylandBackend SceneOpenGLBackend Wayland::Egl) endif() diff --git a/plugins/platforms/x11/CMakeLists.txt b/plugins/platforms/x11/CMakeLists.txt index 8addf0b52e..c62bb44767 100644 --- a/plugins/platforms/x11/CMakeLists.txt +++ b/plugins/platforms/x11/CMakeLists.txt @@ -1,5 +1,5 @@ add_subdirectory(common) add_subdirectory(standalone) -if(X11_XCB_FOUND) +if (X11_XCB_FOUND) add_subdirectory(windowed) endif() diff --git a/plugins/platforms/x11/common/CMakeLists.txt b/plugins/platforms/x11/common/CMakeLists.txt index 677f9f6c9f..d52ff2550f 100644 --- a/plugins/platforms/x11/common/CMakeLists.txt +++ b/plugins/platforms/x11/common/CMakeLists.txt @@ -1,7 +1,7 @@ -if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") +if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-int-to-pointer-cast") endif() -if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") +if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-int-to-void-pointer-cast") endif() include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl) diff --git a/plugins/platforms/x11/standalone/CMakeLists.txt b/plugins/platforms/x11/standalone/CMakeLists.txt index 80c139b772..6bfbc4a032 100644 --- a/plugins/platforms/x11/standalone/CMakeLists.txt +++ b/plugins/platforms/x11/standalone/CMakeLists.txt @@ -1,26 +1,26 @@ set(X11PLATFORM_SOURCES edge.cpp + effects_mouse_interception_x11_filter.cpp + effects_x11.cpp logging.cpp - x11cursor.cpp - x11_platform.cpp - x11_output.cpp - screens_xrandr.cpp - windowselector.cpp + non_composited_outline.cpp overlaywindow_x11.cpp screenedges_filter.cpp - non_composited_outline.cpp - x11_decoration_renderer.cpp - xfixes_cursor_event_filter.cpp - effects_x11.cpp - effects_mouse_interception_x11_filter.cpp + screens_xrandr.cpp sync_filter.cpp + windowselector.cpp + x11_decoration_renderer.cpp + x11_output.cpp + x11_platform.cpp + x11cursor.cpp + xfixes_cursor_event_filter.cpp ) -if(X11_Xinput_FOUND) +if (X11_Xinput_FOUND) set(X11PLATFORM_SOURCES ${X11PLATFORM_SOURCES} xinputintegration.cpp) endif() -if(HAVE_EPOXY_GLX) +if (HAVE_EPOXY_GLX) set(X11PLATFORM_SOURCES ${X11PLATFORM_SOURCES} glxbackend.cpp glx_context_attribute_builder.cpp) endif() @@ -29,11 +29,11 @@ include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl) add_library(KWinX11Platform MODULE ${X11PLATFORM_SOURCES}) set_target_properties(KWinX11Platform PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.platforms/") target_link_libraries(KWinX11Platform eglx11common kwin kwinxrenderutils SceneOpenGLBackend Qt5::X11Extras XCB::CURSOR KF5::Crash) -if(X11_Xinput_FOUND) +if (X11_Xinput_FOUND) target_link_libraries(KWinX11Platform ${X11_Xinput_LIB}) endif() -if(HAVE_DL_LIBRARY) +if (HAVE_DL_LIBRARY) target_link_libraries(KWinX11Platform ${DL_LIBRARY}) endif() diff --git a/plugins/platforms/x11/windowed/CMakeLists.txt b/plugins/platforms/x11/windowed/CMakeLists.txt index 0c86345b63..815c0ee1cb 100644 --- a/plugins/platforms/x11/windowed/CMakeLists.txt +++ b/plugins/platforms/x11/windowed/CMakeLists.txt @@ -1,6 +1,6 @@ set(X11BACKEND_SOURCES - logging.cpp egl_x11_backend.cpp + logging.cpp scene_qpainter_x11_backend.cpp x11windowed_backend.cpp x11windowed_output.cpp @@ -10,7 +10,7 @@ include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl) add_library(KWinWaylandX11Backend MODULE ${X11BACKEND_SOURCES}) set_target_properties(KWinWaylandX11Backend PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.waylandbackends/") target_link_libraries(KWinWaylandX11Backend eglx11common kwin kwinxrenderutils X11::XCB SceneQPainterBackend SceneOpenGLBackend) -if(X11_Xinput_FOUND) +if (X11_Xinput_FOUND) target_link_libraries(KWinWaylandX11Backend ${X11_Xinput_LIB}) endif() diff --git a/plugins/qpa/CMakeLists.txt b/plugins/qpa/CMakeLists.txt index 882c0c32e8..ab9dbc9138 100644 --- a/plugins/qpa/CMakeLists.txt +++ b/plugins/qpa/CMakeLists.txt @@ -22,17 +22,17 @@ add_library(KWinQpaPlugin MODULE ${QPA_SOURCES}) set_target_properties(KWinQpaPlugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/platforms/") set(QT5PLATFORMSUPPORT_LIBS - Qt5FontDatabaseSupport::Qt5FontDatabaseSupport - Qt5ThemeSupport::Qt5ThemeSupport - Qt5EventDispatcherSupport::Qt5EventDispatcherSupport + Qt5FontDatabaseSupport::Qt5FontDatabaseSupport + Qt5ThemeSupport::Qt5ThemeSupport + Qt5EventDispatcherSupport::Qt5EventDispatcherSupport ) target_link_libraries(KWinQpaPlugin - kwin - KF5::WaylandClient + ${FREETYPE_LIBRARIES} ${QT5PLATFORMSUPPORT_LIBS} Fontconfig::Fontconfig - ${FREETYPE_LIBRARIES} + KF5::WaylandClient + kwin ) install( diff --git a/plugins/scenes/CMakeLists.txt b/plugins/scenes/CMakeLists.txt index eb84a43ce8..5c55688e87 100644 --- a/plugins/scenes/CMakeLists.txt +++ b/plugins/scenes/CMakeLists.txt @@ -1,5 +1,5 @@ add_subdirectory(opengl) add_subdirectory(qpainter) -if( KWIN_BUILD_XRENDER_COMPOSITING ) +if (KWIN_BUILD_XRENDER_COMPOSITING) add_subdirectory(xrender) endif() diff --git a/plugins/scenes/opengl/CMakeLists.txt b/plugins/scenes/opengl/CMakeLists.txt index 1134f06440..ac47c82ae7 100644 --- a/plugins/scenes/opengl/CMakeLists.txt +++ b/plugins/scenes/opengl/CMakeLists.txt @@ -1,6 +1,6 @@ set(SCENE_OPENGL_SRCS - scene_opengl.cpp lanczosfilter.cpp + scene_opengl.cpp ) include(ECMQtDeclareLoggingCategory) @@ -20,8 +20,8 @@ qt5_add_resources(SCENE_OPENGL_SRCS resources.qrc) add_library(KWinSceneOpenGL MODULE ${SCENE_OPENGL_SRCS}) set_target_properties(KWinSceneOpenGL PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.scenes/") target_link_libraries(KWinSceneOpenGL - kwin SceneOpenGLBackend + kwin ) install( diff --git a/plugins/scenes/qpainter/CMakeLists.txt b/plugins/scenes/qpainter/CMakeLists.txt index 24f0d9c546..a68bcb20c3 100644 --- a/plugins/scenes/qpainter/CMakeLists.txt +++ b/plugins/scenes/qpainter/CMakeLists.txt @@ -3,8 +3,8 @@ set(SCENE_QPAINTER_SRCS scene_qpainter.cpp) add_library(KWinSceneQPainter MODULE scene_qpainter.cpp) set_target_properties(KWinSceneQPainter PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.scenes/") target_link_libraries(KWinSceneQPainter - kwin SceneQPainterBackend + kwin ) install( diff --git a/plugins/windowsystem/CMakeLists.txt b/plugins/windowsystem/CMakeLists.txt index 48474c3252..68305c955a 100644 --- a/plugins/windowsystem/CMakeLists.txt +++ b/plugins/windowsystem/CMakeLists.txt @@ -4,12 +4,9 @@ set(kwindowsystem_plugin_SRCS windowsystem.cpp ) - add_library(KF5WindowSystemKWinPrivatePlugin MODULE ${kwindowsystem_plugin_SRCS}) set_target_properties(KF5WindowSystemKWinPrivatePlugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/kf5/org.kde.kwindowsystem.platforms/") -target_link_libraries(KF5WindowSystemKWinPrivatePlugin - kwin -) +target_link_libraries(KF5WindowSystemKWinPrivatePlugin kwin) install( TARGETS diff --git a/qml/CMakeLists.txt b/qml/CMakeLists.txt index 4a0d1af232..9be5dd3aa3 100644 --- a/qml/CMakeLists.txt +++ b/qml/CMakeLists.txt @@ -1,3 +1,3 @@ -install( DIRECTORY outline/plasma DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME}/outline ) -install( DIRECTORY onscreennotification/plasma DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME}/onscreennotification ) -install( DIRECTORY virtualkeyboard DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME} ) +install(DIRECTORY outline/plasma DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME}/outline) +install(DIRECTORY onscreennotification/plasma DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME}/onscreennotification) +install(DIRECTORY virtualkeyboard DESTINATION ${DATA_INSTALL_DIR}/${KWIN_NAME}) diff --git a/scripting/CMakeLists.txt b/scripting/CMakeLists.txt index 2160a4f0cf..ca101bf25f 100644 --- a/scripting/CMakeLists.txt +++ b/scripting/CMakeLists.txt @@ -1,10 +1,11 @@ set(kcm_kwin4_genericscripted_SRCS genericscriptedconfig.cpp) qt5_add_dbus_interface(kcm_kwin4_genericscripted_SRCS ${kwin_effects_dbus_xml} kwineffects_interface) add_library(kcm_kwin4_genericscripted MODULE ${kcm_kwin4_genericscripted_SRCS}) -target_link_libraries( kcm_kwin4_genericscripted +target_link_libraries(kcm_kwin4_genericscripted KF5::ConfigWidgets #KCModule KF5::I18n KF5::Service Qt5::DBus - Qt5::UiTools ) -install( TARGETS kcm_kwin4_genericscripted DESTINATION ${PLUGIN_INSTALL_DIR}/kwin/effects/configs ) + Qt5::UiTools +) +install(TARGETS kcm_kwin4_genericscripted DESTINATION ${PLUGIN_INSTALL_DIR}/kwin/effects/configs) diff --git a/tabbox/CMakeLists.txt b/tabbox/CMakeLists.txt index 030bd33fb1..74652e107d 100644 --- a/tabbox/CMakeLists.txt +++ b/tabbox/CMakeLists.txt @@ -1,3 +1,3 @@ # Install the KWin/WindowSwitcher service type -install( FILES kwinwindowswitcher.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) -install( FILES kwindesktopswitcher.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} ) +install(FILES kwinwindowswitcher.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) +install(FILES kwindesktopswitcher.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR}) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 85feee11a6..8230d028ce 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -11,22 +11,20 @@ target_link_libraries(screenedgeshowtest Qt5::Widgets Qt5::X11Extras KF5::Config if (KF5Wayland_FOUND) add_definitions(-DSOURCE_DIR="${KWIN_SOURCE_DIR}") - set(waylandclienttest_SRCS - waylandclienttest.cpp - ) + set(waylandclienttest_SRCS waylandclienttest.cpp) add_executable(waylandclienttest ${waylandclienttest_SRCS}) target_link_libraries(waylandclienttest Qt5::Core Qt5::Gui KF5::WaylandClient) endif() set(libinputtest_SRCS - libinputtest.cpp - ${KWIN_SOURCE_DIR}/libinput/context.cpp - ${KWIN_SOURCE_DIR}/libinput/connection.cpp - ${KWIN_SOURCE_DIR}/libinput/device.cpp - ${KWIN_SOURCE_DIR}/libinput/events.cpp - ${KWIN_SOURCE_DIR}/libinput/libinput_logging.cpp - ${KWIN_SOURCE_DIR}/logind.cpp - ${KWIN_SOURCE_DIR}/udev.cpp + ${KWIN_SOURCE_DIR}/libinput/connection.cpp + ${KWIN_SOURCE_DIR}/libinput/context.cpp + ${KWIN_SOURCE_DIR}/libinput/device.cpp + ${KWIN_SOURCE_DIR}/libinput/events.cpp + ${KWIN_SOURCE_DIR}/libinput/libinput_logging.cpp + ${KWIN_SOURCE_DIR}/logind.cpp + ${KWIN_SOURCE_DIR}/udev.cpp + libinputtest.cpp ) add_executable(libinputtest ${libinputtest_SRCS}) add_definitions(-DKWIN_BUILD_TESTING) @@ -47,10 +45,10 @@ add_executable(cursorhotspottest cursorhotspottest.cpp) target_link_libraries(cursorhotspottest Qt5::Widgets) include_directories(${CMAKE_CURRENT_BINARY_DIR}) -set( orientationtest_SRCS - orientationtest.cpp +set(orientationtest_SRCS ../orientation_sensor.cpp + orientationtest.cpp ) -qt5_add_dbus_adaptor( orientationtest_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) +qt5_add_dbus_adaptor(orientationtest_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/../org.kde.kwin.OrientationSensor.xml ${CMAKE_CURRENT_SOURCE_DIR}/../orientation_sensor.h KWin::OrientationSensor) add_executable(orientationtest ${orientationtest_SRCS}) target_link_libraries(orientationtest Qt5::DBus Qt5::Widgets Qt5::Sensors KF5::ConfigCore KF5::Notifications KF5::I18n)