kst-plot pch code broken by newer cmake

David Faure faure at kde.org
Sun Mar 16 18:37:06 UTC 2014

kst-plot doesn't compile with cmake 3.

[  0%] Generating kstcore_pch.h.gch
<command-line>:0:1: error: macro names must be identifiers

 a stray "-D" on the command line, with no identifier.

Added debug output (attached), and got this:
-- kst_add_pch_rule _definitions=KST_HAVE_REVISION_H;$<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>;QT_GUI_LIB;QT_CORE_LIB;BUILD_KSTAPP
--    -D$<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>
--    -DQT_GUI_LIB

The new template expression thingie whose real name I forgot, breaks such code.
I don't know what the fix is, though.

Proper support for PCH seems unfinished. http://www.cmake.org/Bug/view.php?id=1260
Meanwhile maybe we can just disable PCH support in kst-plot when cmake version >= 3?

David Faure, faure at kde.org, http://www.davidfaure.fr
Working on KDE, in particular KDE Frameworks 5
-------------- next part --------------
A non-text attachment was scrubbed...
Name: KstPchSupport.cmake.diff
Type: text/x-patch
Size: 591 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-buildsystem/attachments/20140316/dee8c274/attachment.diff>

More information about the Kde-buildsystem mailing list