cmake 3.9 breaks compiling kconfig (and dbus adaptors/interfaces)

Sebastian Holtermann sebholt at xwmw.org
Sun Jul 2 21:16:56 UTC 2017


Hi David.

> another issue with cmake 3.9 seems to be the case where the header is called foo_p.h rather than foo.h (as is often done for files that won't get installed, in a library).
> 
> Example: kconfigwidgets.git fails to build, with this error:
> 
> CMakeFiles/KF5ConfigWidgets.dir/kcolorschememanager.cpp.o: In function `KColorSchemeModel::KColorSchemeModel(QObject*)':
> /d/kde/src/5/frameworks/kconfigwidgets/src/kcolorschememanager.cpp:39: undefined reference to `vtable for KColorSchemeModel'
> 
> src/kcolorschememanager_p.h: class KColorSchemeModel : public QAbstractListModel
> src/kcolorschememanager.cpp: KColorSchemeModel::KColorSchemeModel(QObject *parent)
> (no moc include anywhere, AUTOMOC used to take care of this)
> 
> Same problem in kxmlgui, sonnet, knewstuff...
> 
> Can you have a look?

This is an regression, but I think I found the problem.
Unfortunately while removing code duplication, a for loop was exited too
early. I'm surprised this wasn't caught by the tests.
Could you test this branch, please:
https://gitlab.kitware.com/sebholt/cmake/tree/autogen_p

--
Sebastian


More information about the Kde-buildsystem mailing list