Fwd: kdelibs compilation error
faure at kde.org
Fri Oct 1 21:11:28 CEST 2010
On Friday 01 October 2010, Tomas Vavra wrote:
> I have problem with building kdelibs it always finishes with this error:
> * [while linking kded4]
> /backup/devel/kde4/build/kdelibs/lib/libnepomuk.so.4: undefined reference
> to `Soprano::Vocabulary::NAO::userVisible()'
Alex, can you look into this?
I spent some time on IRC with Tomas, and I have no idea why he gets this
error. Well, nepomuk and soprano are both missing on the link line, but why,
and why not for others... (they are both present on my machine, when linking
kio links to nepomuk and soprano just fine,
then other things link ok, but then kded4 doesn't link because it links to
kio, which links to nepomuk, and when this happens it fails as above, due to a
missing -lsoprano. In fact -lnepomuk is missing too, but apparently it finds it
as a direct dependency of libkio?
So, what is it that puts dependent libs on the link line? The _LIB_DEPENDS
From CMakeCache.txt they look fine (i.e. similar to mine)
I thought I understood the idea of "kio links to nepomuk for implementation
reasons, so it doesn't export it in its LINK_INTERFACE".
But then why does linking kded4 fail, when kded4 does NOT use nepomuk/soprano,
unless we add -lsoprano to the link line?
I'm confused by whether all dependent libs must be listed on the link line or
not [btw he uses GNU ld, not gold]. Well, I guess they must be, since they
are for me.
He tried http://www.davidfaure.fr/2010/kio.diff and this helped link kded4, but
compilation failed again with the same error when linking
kutils/kemoticons/tests/kemoticonstest. I think that's because this one
doesn't use kio directly... It links kemoticons, which links kio, which....
you get the point. It's indirect.
He's using cmake-2.8.2, just like me, almost (I use the git version).
David Faure, faure at kde.org, http://www.davidfaure.fr
Sponsored by Nokia to work on KDE, incl. Konqueror (http://www.konqueror.org).
More information about the Kde-buildsystem