Commit 4c69635a authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use new macro for autogenerating categories file

parent da4ffe5a
...@@ -34,6 +34,7 @@ include(ECMAddTests) ...@@ -34,6 +34,7 @@ include(ECMAddTests)
include(ECMQtDeclareLoggingCategory) include(ECMQtDeclareLoggingCategory)
include(GenerateExportHeader) include(GenerateExportHeader)
add_definitions(-DTRANSLATION_DOMAIN="kdebugsettings") add_definitions(-DTRANSLATION_DOMAIN="kdebugsettings")
add_definitions(-DQT_NO_FOREACH) add_definitions(-DQT_NO_FOREACH)
if (EXISTS "${CMAKE_SOURCE_DIR}/.git") if (EXISTS "${CMAKE_SOURCE_DIR}/.git")
...@@ -55,6 +56,11 @@ add_subdirectory( src ) ...@@ -55,6 +56,11 @@ add_subdirectory( src )
if (BUILD_TESTING) if (BUILD_TESTING)
add_subdirectory( autotests ) add_subdirectory( autotests )
endif() endif()
install( FILES data/kde.categories data/kde.renamecategories data/kdebugsettings.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR} ) if (NOT ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_install_logging_categories(EXPORT KDEBUGSETTINGS FILE kdebugsettings.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR})
else()
install( FILES data/kdebugsettings.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR} )
endif()
install( FILES data/kde.categories data/kde.renamecategories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR} )
feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES) feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES)
...@@ -3,6 +3,13 @@ include_directories(${CMAKE_BINARY_DIR}) ...@@ -3,6 +3,13 @@ include_directories(${CMAKE_BINARY_DIR})
set(kdebugsettings_debug_SRCS) set(kdebugsettings_debug_SRCS)
ecm_qt_declare_logging_category(kdebugsettings_debug_SRCS HEADER kdebugsettings_debug.h IDENTIFIER KDEBUGSETTINGS_LOG CATEGORY_NAME log_kdebugsettings) ecm_qt_declare_logging_category(kdebugsettings_debug_SRCS HEADER kdebugsettings_debug.h IDENTIFIER KDEBUGSETTINGS_LOG CATEGORY_NAME log_kdebugsettings)
if (NOT ECM_VERSION VERSION_LESS "5.68.0")
ecm_qt_declare_logging_category(kdebugsettings_debug_SRCS HEADER kdebugsettings_debug.h IDENTIFIER KDEBUGSETTINGS_LOG CATEGORY_NAME log_kdebugsettings DESCRIPTION "kdebugsettings"
EXPORT KDEBUGSETTINGS)
else()
ecm_qt_declare_logging_category(kdebugsettings_debug_SRCS HEADER kdebugsettings_debug.h IDENTIFIER KDEBUGSETTINGS_LOG CATEGORY_NAME log_kdebugsettings)
endif()
set(kdebugsettings_LIB_SRCS set(kdebugsettings_LIB_SRCS
kdebugsettingsloadingcategories.cpp kdebugsettingsloadingcategories.cpp
kdeloggingcategory.cpp kdeloggingcategory.cpp
......
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