summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <montel@kde.org>2016-09-13 15:31:09 (GMT)
committerMontel Laurent <montel@kde.org>2016-09-13 15:31:09 (GMT)
commit36d12e5d96d52779e7bcce4b64ba6d5b8ed6dd9d (patch)
tree4bb3800ba10110fdedd6e0f0362fa436b3203fe8
parente9bc132a7aac024a39ecf06f8e7016a702b3f8ee (diff)
Add kcoreaddons macro
-rw-r--r--kaddressbook/plugins/sendmail/CMakeLists.txt5
-rw-r--r--kaddressbook/plugins/sendvcards/CMakeLists.txt7
2 files changed, 7 insertions, 5 deletions
diff --git a/kaddressbook/plugins/sendmail/CMakeLists.txt b/kaddressbook/plugins/sendmail/CMakeLists.txt
index fa818fa..2b87d3e 100644
--- a/kaddressbook/plugins/sendmail/CMakeLists.txt
+++ b/kaddressbook/plugins/sendmail/CMakeLists.txt
@@ -11,13 +11,14 @@ set(kaddressbook_sendmailplugin_SRCS
ecm_qt_declare_logging_category(kaddressbook_sendmailplugin_SRCS HEADER kaddressbook_sendmailplugin_debug.h IDENTIFIER KADDRESSBOOK_SENDMAIL_LOG CATEGORY_NAME log_kaddressbook_sendmail)
-add_library(kaddressbook_sendmailplugin MODULE ${kaddressbook_sendmailplugin_SRCS})
+kcoreaddons_add_plugin(kaddressbook_sendmailplugin JSON kaddressbook_sendmailplugin.json SOURCES
+ ${kaddressbook_sendmailplugin_SRCS} INSTALL_NAMESPACE kaddressbook)
+
target_link_libraries(kaddressbook_sendmailplugin
KF5::PimCommon KF5::Completion KF5::IconThemes KF5::MailCommon KF5::XmlGui KF5::I18n
)
-install(TARGETS kaddressbook_sendmailplugin DESTINATION ${PLUGIN_INSTALL_DIR}/kaddressbook)
if (BUILD_TESTING)
add_subdirectory(autotests)
endif()
diff --git a/kaddressbook/plugins/sendvcards/CMakeLists.txt b/kaddressbook/plugins/sendvcards/CMakeLists.txt
index 5bac547..a872f73 100644
--- a/kaddressbook/plugins/sendvcards/CMakeLists.txt
+++ b/kaddressbook/plugins/sendvcards/CMakeLists.txt
@@ -9,14 +9,15 @@ set(kaddressbook_sendvcardsplugin_SRCS
)
ecm_qt_declare_logging_category(kaddressbook_sendvcardsplugin_SRCS HEADER kaddressbook_sendvcardsplugin_debug.h IDENTIFIER KADDRESSBOOK_SENDVCARDS_LOG CATEGORY_NAME log_kaddressbook_sendvcards)
-add_library(kaddressbook_sendvcardsplugin MODULE ${kaddressbook_sendvcardsplugin_SRCS})
+
+kcoreaddons_add_plugin(kaddressbook_sendvcardsplugin JSON kaddressbook_sendvcardsplugin.json SOURCES
+ ${kaddressbook_sendvcardsplugin_SRCS} INSTALL_NAMESPACE kaddressbook)
+
target_link_libraries(kaddressbook_sendvcardsplugin
KF5::PimCommon KF5::Completion KF5::IconThemes KF5::MailCommon KF5::XmlGui KF5::MimeTreeParser KF5::I18n
)
-install(TARGETS kaddressbook_sendvcardsplugin DESTINATION ${PLUGIN_INSTALL_DIR}/kaddressbook)
-
if (BUILD_TESTING)
add_subdirectory(autotests)
endif()