Getting ecm files from the ECM package
Alexander Neundorf
neundorf at kde.org
Sun Nov 3 13:21:55 UTC 2013
On Saturday 02 November 2013, Stephen Kelly wrote:
> Alexander Neundorf wrote:
> > In case we decide to go this way (i.e. the "my ideal view" plus optional
> > downloading), and we should hear Stephens opinion on that,
>
> My opinion:
>
> 1) The current situation with ECM and KF5 is just fine.
do you really consider having such code in ECMConfig.cmake "just fine" ?
--- a/ECMConfig.cmake.in
+++ b/ECMConfig.cmake.in
@@ -17,3 +17,10 @@
include("${ECM_MODULE_DIR}/ECMUseFindModules.cmake")
+if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.13)
+ find_package(Qt5Core 5.2.0 REQUIRED)
+ set_property(TARGET Qt5::Core PROPERTY INTERFACE_COMPILE_DEFINITIONS
+ QT_CORE_LIB
+ $<$<NOT:$<OR:$<CONFIG:Debug>,$<CONFIG:DebugFull>>>:QT_NO_DEBUG>)
+else()
+ message(FATAL_ERROR \"Remove this hack."
+ " Set CMAKE_MAP_IMPORTED_TARGET_DEBUGFULL to DEBUG instead.\")
+endif()
+
This code unconditionally searches for QtCore (and sets a target property
where I'm not sure how many people here can understand what's going on).
This goes completely against my original intentions for ECM, i.e. to be usable
by any cmake-using projects.
As it is, IMO it would be appropriate to rename it to kde-cmake-modules.
Alex
More information about the Kde-frameworks-devel
mailing list