From e25c84c0463f5a43d3b2bb836850f5c5963a2846 Mon Sep 17 00:00:00 2001 From: Chris Xiong Date: Fri, 30 Sep 2022 23:58:46 -0400 Subject: Add context menu for the image view. Shortcuts are currently broken. Will be fixed in future commits. --- qdeduper/CMakeLists.txt | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'qdeduper/CMakeLists.txt') diff --git a/qdeduper/CMakeLists.txt b/qdeduper/CMakeLists.txt index 7373331..3adc4ba 100644 --- a/qdeduper/CMakeLists.txt +++ b/qdeduper/CMakeLists.txt @@ -3,9 +3,13 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON) option(QDEDUPER_USE_QT6 "Build qdeduper with Qt 6" OFF) if (QDEDUPER_USE_QT6) - find_package(Qt6 REQUIRED COMPONENTS Widgets Concurrent) + find_package(Qt6 REQUIRED COMPONENTS Widgets Concurrent OPTIONAL_COMPONENTS DBus) else() - find_package(Qt5 REQUIRED COMPONENTS Widgets Concurrent) + find_package(Qt5 REQUIRED COMPONENTS Widgets Concurrent OPTIONAL_COMPONENTS DBus) +endif() + +if (Qt5DBus_FOUND OR Qt6DBus_FOUND) + add_compile_definitions(HAS_QTDBUS) endif() set(CMAKE_AUTOMOC ON) @@ -21,6 +25,7 @@ add_executable(qdeduper pathchooser.cpp settings.cpp preferencedialog.cpp + utilities.cpp resources.qrc ) @@ -30,6 +35,12 @@ target_link_libraries(qdeduper if (QDEDUPER_USE_QT6) target_link_libraries(qdeduper Qt6::Widgets Qt6::Concurrent) + if(Qt6DBus_FOUND) + target_link_libraries(qdeduper Qt6::DBus) + endif() else() target_link_libraries(qdeduper Qt5::Widgets Qt5::Concurrent) + if(Qt5DBus_FOUND) + target_link_libraries(qdeduper Qt5::DBus) + endif() endif() -- cgit v1.2.3