[gui] Add KGuiAddons as an optional dependency

This will be needed to replace QClipboard in some places.

Signed-off-by: Kevin Ottens <ervin@kde.org>
This commit is contained in:
Kevin Ottens 2024-03-06 18:17:55 +01:00
parent 0e301e75d9
commit 312da848bc

View file

@ -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