Commit 1d257970 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Autogenerate categories file

parent 114273c7
......@@ -132,5 +132,14 @@ if (NOT ${MIMETREEPARSER_ONLY_BUILD})
add_subdirectory(webengineviewer)
endif()
install(FILES messagelib.renamecategories messagelib.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR})
if (ECM_VERSION VERSION_LESS "5.68.0")
install(FILES messagelib.renamecategories messagelib.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR})
else ()
ecm_qt_install_logging_categories(
EXPORT MESSAGELIB
FILE messagelib.categories
DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR}
)
endif()
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
......@@ -168,7 +168,15 @@ set( messagecomposer_src
ki18n_wrap_ui(messagecomposer_src
imagescaling/ui/imagescalingwidget.ui
)
ecm_qt_declare_logging_category(messagecomposer_src HEADER messagecomposer_debug.h IDENTIFIER MESSAGECOMPOSER_LOG CATEGORY_NAME org.kde.pim.messagecomposer)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(messagecomposer_src HEADER messagecomposer_debug.h IDENTIFIER MESSAGECOMPOSER_LOG CATEGORY_NAME org.kde.pim.messagecomposer)
else()
ecm_qt_declare_logging_category(messagecomposer_src HEADER messagecomposer_debug.h IDENTIFIER MESSAGECOMPOSER_LOG CATEGORY_NAME org.kde.pim.messagecomposer
DESCRIPTION "messagelib (messagecomposer)"
OLD_CATEGORY_NAMES log_messagecomposer
EXPORT MESSAGELIB
)
endif()
if(KDEPIM_ENTERPRISE_BUILD)
......
......@@ -43,7 +43,16 @@ ki18n_wrap_ui(messagecore_LIB_SRCS
attachment/ui/attachmentpropertiesdialog_readonly.ui
)
ecm_qt_declare_logging_category(messagecore_LIB_SRCS HEADER messagecore_debug.h IDENTIFIER MESSAGECORE_LOG CATEGORY_NAME org.kde.pim.messagecore)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(messagecore_LIB_SRCS HEADER messagecore_debug.h IDENTIFIER MESSAGECORE_LOG CATEGORY_NAME org.kde.pim.messagecore)
else()
ecm_qt_declare_logging_category(messagecore_LIB_SRCS HEADER messagecore_debug.h IDENTIFIER MESSAGECORE_LOG CATEGORY_NAME org.kde.pim.messagecore
DESCRIPTION "messagelib (messagecore)"
OLD_CATEGORY_NAMES log_messagecore
EXPORT MESSAGELIB
)
endif()
add_library(KF5MessageCore ${messagecore_LIB_SRCS})
generate_export_header(KF5MessageCore BASE_NAME messagecore)
......
......@@ -48,7 +48,16 @@ set(libmessagelist_SRCS
widget.cpp
messagelistutil.cpp
)
ecm_qt_declare_logging_category(libmessagelist_SRCS HEADER messagelist_debug.h IDENTIFIER MESSAGELIST_LOG CATEGORY_NAME org.kde.pim.messagelist)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(libmessagelist_SRCS HEADER messagelist_debug.h IDENTIFIER MESSAGELIST_LOG CATEGORY_NAME org.kde.pim.messagelist)
else()
ecm_qt_declare_logging_category(libmessagelist_SRCS HEADER messagelist_debug.h IDENTIFIER MESSAGELIST_LOG CATEGORY_NAME org.kde.pim.messagelist
DESCRIPTION "messagelib (messagelist)"
OLD_CATEGORY_NAMES log_messagelist
EXPORT MESSAGELIB
)
endif()
kconfig_add_kcfg_files(libmessagelist_SRCS
core/messagelistsettings.kcfgc
......
......@@ -271,8 +271,22 @@ set(libmessageviewer_SRCS
qt5_add_resources(libmessageviewer_SRCS messagepartthemes.qrc)
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer)
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_dkimcheckerdebug.h IDENTIFIER MESSAGEVIEWER_DKIMCHECKER_LOG CATEGORY_NAME org.kde.pim.messageviewer_dkimchecker)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer)
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_dkimcheckerdebug.h IDENTIFIER MESSAGEVIEWER_DKIMCHECKER_LOG CATEGORY_NAME org.kde.pim.messageviewer_dkimchecker)
else()
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer
DESCRIPTION "messagelib (messageviewer)"
OLD_CATEGORY_NAMES log_messageviewer
EXPORT MESSAGELIB
)
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_dkimcheckerdebug.h IDENTIFIER MESSAGEVIEWER_DKIMCHECKER_LOG CATEGORY_NAME org.kde.pim.messageviewer_dkimchecker
DESCRIPTION "messagelib (messageviewer dkim support)"
EXPORT MESSAGELIB
)
endif()
kconfig_add_kcfg_files(libmessageviewer_SRCS
settings/globalsettings_messageviewer.kcfgc
)
......
......@@ -4,8 +4,8 @@ ecm_add_test(webengineembedparttest.cpp ../webengineembedpart.cpp
LINK_LIBRARIES Qt5::Test Qt5::Core
)
set(webengineparthtmlwritertestdebug_SRCS)
ecm_qt_declare_logging_category(webengineparthtmlwritertestdebug_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer)
#set(webengineparthtmlwritertestdebug_SRCS)
#ecm_qt_declare_logging_category(webengineparthtmlwritertestdebug_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer)
#ecm_add_test(webengineparthtmlwritertest.cpp ../webengineembedpart.cpp ../webengineparthtmlwriter.cpp ${webengineparthtmlwritertestdebug_SRCS}
......
......@@ -110,7 +110,16 @@ set(libmimetreeparser_SRCS
${mimetreeparser_temporaryfile_SRCS}
)
ecm_qt_declare_logging_category(libmimetreeparser_SRCS HEADER mimetreeparser_debug.h IDENTIFIER MIMETREEPARSER_LOG CATEGORY_NAME org.kde.pim.mimetreeparser)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(libmimetreeparser_SRCS HEADER mimetreeparser_debug.h IDENTIFIER MIMETREEPARSER_LOG CATEGORY_NAME org.kde.pim.mimetreeparser)
else()
ecm_qt_declare_logging_category(libmimetreeparser_SRCS HEADER mimetreeparser_debug.h IDENTIFIER MIMETREEPARSER_LOG CATEGORY_NAME org.kde.pim.mimetreeparser
DESCRIPTION "messagelib (mimetreeparser)"
OLD_CATEGORY_NAMES log_mimetreeparser
EXPORT MESSAGELIB
)
endif()
add_library(KF5MimeTreeParser
${libmimetreeparser_SRCS}
......
......@@ -24,9 +24,17 @@ set(templateparser_LIB_SRCS
templateparseremailaddressrequesterinterfacewidget.cpp
templateconvertcommandjob.cpp
)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(templateparser_LIB_SRCS HEADER templateparser_debug.h IDENTIFIER TEMPLATEPARSER_LOG CATEGORY_NAME org.kde.pim.templateparser)
else()
ecm_qt_declare_logging_category(templateparser_LIB_SRCS HEADER templateparser_debug.h IDENTIFIER TEMPLATEPARSER_LOG CATEGORY_NAME org.kde.pim.templateparser
DESCRIPTION "messagelib (templateparser)"
OLD_CATEGORY_NAMES log_templateparser
EXPORT MESSAGELIB
)
endif()
ecm_qt_declare_logging_category(templateparser_LIB_SRCS HEADER templateparser_debug.h IDENTIFIER TEMPLATEPARSER_LOG CATEGORY_NAME org.kde.pim.templateparser)
kconfig_add_kcfg_files(templateparser_LIB_SRCS settings/templatesconfiguration_kfg.kcfgc)
......
......@@ -77,7 +77,15 @@ set(libwebengineviewer_SRCS
${libwebengineviewer_accesskey_SRCS}
)
ecm_qt_declare_logging_category(libwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(libwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
else()
ecm_qt_declare_logging_category(libwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer
DESCRIPTION "messagelib (webengineviewer)"
EXPORT MESSAGELIB
)
endif()
add_library(KF5WebEngineViewer ${libwebengineviewer_SRCS} ${libwebengineviewer_webengine_SRCS})
......
set(testwebengineviewer_webengine_SRCS)
ecm_qt_declare_logging_category(testwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(testwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
else()
ecm_qt_declare_logging_category(testwebengineviewer_webengine_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer
DESCRIPTION "messagelib (webengineviewer)"
EXPORT MESSAGELIB
)
endif()
include_directories(${Messagelib_BINARY_DIR})
ecm_add_test(webhittestresulttest.cpp
TEST_NAME webhittestresulttest
......
set(testwebengineviewer_webengine_common_SRCS)
ecm_qt_declare_logging_category(testwebengineviewer_webengine_common_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
if (ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(testwebengineviewer_webengine_common_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer)
else()
ecm_qt_declare_logging_category(testwebengineviewer_webengine_common_SRCS HEADER webengineviewer_debug.h IDENTIFIER WEBENGINEVIEWER_LOG CATEGORY_NAME org.kde.pim.webengineviewer
DESCRIPTION "messagelib (webengineviewer)"
EXPORT MESSAGELIB
)
endif()
add_definitions( -DCHECKPHISHINGURL_DATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}/data" )
ecm_add_test(checkphishingurljobtest.cpp ../checkphishingurljob.cpp ../updatedatabaseinfo.cpp ../checkphishingurlutil.cpp ${testwebengineviewer_webengine_common_SRCS}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment