summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Montel <[email protected]>2018-01-15 08:00:33 +0100
committerLaurent Montel <[email protected]>2018-01-15 08:00:33 +0100
commite77100e17995ec8982aba3acdb3884dbda6f47b0 (patch)
treefe54828f196a45c381881f9f17a456b6c309fa15
parent8301e547658dce3c8710fc4d2303614a73480d68 (diff)
Fix check
-rw-r--r--CMakeLists.txt13
1 files changed, 6 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 68a2014..33109b8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -22,13 +22,6 @@ include(ECMQtDeclareLoggingCategory)
include(ECMAddTests)
include(ECMCoverageOption)
-if(NOT CMAKE_VERSION VERSION_LESS "3.10.0")
- # CMake 3.9+ warns about automoc on files without Q_OBJECT, and doesn't know about other macros.
- # 3.10+ lets us provide more macro names that require automoc.
- # Remove this when depending on a Frameworks or ECM version that solves this upstream.
- list(APPEND CMAKE_AUTOMOC_MACRO_NAMES "K_PLUGIN_FACTORY_WITH_JSON")
-endif()
-
set(LIBKDEPIM_LIB_VERSION ${PIM_VERSION})
set(AKONADICONTACT_LIB_VERSION "5.7.40")
set(QT_REQUIRED_VERSION "5.8.0")
@@ -81,6 +74,12 @@ install(FILES
${CMAKE_CURRENT_BINARY_DIR}/MailTransportDBusServiceConfig.cmake
DESTINATION "${CMAKECONFIG_INSTALL_PREFIX}/MailTransportDBusService")
+if(NOT CMAKE_VERSION VERSION_LESS "3.10.0" AND KF5_VERSION VERSION_LESS "5.42.0")
+ # CMake 3.9+ warns about automoc on files without Q_OBJECT, and doesn't know about other macros.
+ # 3.10+ lets us provide more macro names that require automoc.
+ # KF5 >= 5.42 takes care itself of adding its macros in its cmake config files
+ list(APPEND CMAKE_AUTOMOC_MACRO_NAMES "K_PLUGIN_FACTORY_WITH_JSON")
+endif()
add_subdirectory(src)