From 312da848bcd62c165ccd1b7c0dde8d45a75c0c2e Mon Sep 17 00:00:00 2001 From: Kevin Ottens Date: Wed, 6 Mar 2024 18:17:55 +0100 Subject: [PATCH] [gui] Add KGuiAddons as an optional dependency This will be needed to replace QClipboard in some places. Signed-off-by: Kevin Ottens --- src/gui/CMakeLists.txt | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 097e4df7909e..a921ea1a6ea8 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -1,6 +1,7 @@ project(gui) find_package(Qt5 REQUIRED COMPONENTS Widgets Svg Qml Quick QuickControls2 QuickWidgets Xml Network) find_package(KF5Archive REQUIRED) +find_package(KF5GuiAddons) if(QUICK_COMPILER) find_package(Qt5QuickCompiler) @@ -563,6 +564,14 @@ target_link_libraries(nextcloudCore KF5::Archive ) +if(KF5GuiAddons_FOUND) + target_link_libraries(nextcloudCore + PUBLIC + KF5::GuiAddons + ) + add_definitions(-DHAVE_KGUIADDONS) +endif() + add_subdirectory(socketapi) # skip unity inclusion for files which cause problems with a CMake unity build