[KDE/Mac] KDE4/KF5 header clash? ( No luck with building KF5/Frameworks)

Ian Wadham iandw.au at gmail.com
Tue Mar 24 09:52:41 UTC 2015

Hi René,

On 23/03/2015, at 9:40 PM, René J.V. Bertin wrote:

> On Sunday March 22 2015 09:51:01 René J.V. Bertin wrote:
>> I saw a statement from Boudewijn Rempt on the Calligra ML that 
>>> you cannot have both a kde4 and a kf5 development system unless
>>> you do some weird stuff
> ...
>> I'm CC'ing David in hope he can shed some light on this particular aspect. 
> More on this:
> (quoth Boudewijn R:)
>>> Does that mean that the KDE (4 and 5) headers are not conceived to co-exist (the libraries are, I'd presume) or else, why is that?
>>> If in general one cannot have a system that allows you to build KDE4 applications as well as KF5 applications that's something we're going to want to know and deal with (as soon and as far as possible) in MacPorts ...
>> The problem is kde4libs support: that framework conflicts with the regular 
>> kde4 headers.

One way out of this might be to exclude kdelibs4support from Frameworks/KF5 on MacPorts,
on the principle that, by the time a KF5 app reaches us it should have been fully ported to
Frameworks.  Leastways, Laurent Montel has been porting KDE Games apps in two stages,
basic porting and then removal of kdelibs4support.  And I do not think he putting any games
in for release if they still require kdelibs4support.  But maybe it is not so easy to go that way
with larger KDE 4 apps (such as Calligra?).

> So we should be fine if we configure KF5 to put its headers in, say, /opt/local/include/kf5 instead of just /opt/local/include like KDE4 does (in MacPorts)?
> (Or we'd have to re-organise KDE4 too so it puts its headers into /opt/local/include/kde4, to prevent accidental confusion ...)
> It's surprising though that KF5 wasn't conceived to avoid this kind of name clashing , e.g. by putting the kde4support headers in a subdirectory and inciting devs to change their #include statements to add that path (#include <kde4support/kfoo.h> instead of #include <kfoo.h>).

I wonder if we could try using CMAKE_INCLUDE_PATH.  I might give it a go in the next day
or two, when I can find some time,  See http://www.cmake.org/Wiki/CMake_Useful_Variables.

Cheers, Ian W.

More information about the kde-mac mailing list