libkdeinit_ libraries
Waldo Bastian
bastian at kde.org
Wed Jul 16 23:06:03 BST 2003
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Wednesday 16 July 2003 23:45, Michael Matz wrote:
> Hi,
>
> On Wed, 16 Jul 2003, Adriaan de Groot wrote:
> > Recently, KDE HEAD stopped starting up for me, with all kdeinit started
> > processes yielding errors because of a missing kdemain function. This is
> > documented in the "kdeinit & missing "main" symbol" thread on -devel.
> >
> > The attached patch looks in libkdeinit_foo before looking in foo itself,
> > and gets KDE HEAD started properly. I'm hesitant to just commit it, since
> > I don't really know (a) what this kdeinit stuff is good for (b) what to
> > do in the other branch of the if(), when the pathname starts with a / .
>
> I have not read the thread on kde-devel, but your patch definitely is
> wrong, in the sense that it's a workaround for something which shouldn't
> happen, which only works on ELF systems. You can't dlopen libraries
> basically.
>
> kinit.cpp should search for "kdemain" _and_ "main" symbols in the tried
> DSO, and if I read correctly it indeed does so for version
> "KDE_IS_VERSION(3, 90, 0)". Unless all (or at least most) of KDE CVS is
> converted to do it correctly this should remain this way (i.e. search main
> if kdemain isn't found).
>
> It should be investigated, why the DSO in question didn't provide a
> kdemain symbol, and second why kinit didn't look for main in that case.
The problem is that the kdemain() is placed in the wrong library.
kdemain is in dcopserver.cpp and the Makefile adds a forward declaration in
dcopserver.la.cpp as well.
dcopserver.cpp gets compiled into dcopserver.lo and linked into
libkdeinit_dcopserver.la
dcopserver.la.cpp gets compiled into dcopserver.la.o and linked into the
dcopserver executable.
dcopserver.la gets linked against dcopserver_dummy.lo (which is build from the
empty dcopserver_dummy.cpp) and libkdeinit_dcopserver.la. So
libkdeinit_dcopserver.la contains kdemain, but dcopserver.la itself does not.
IMHO A solution would be to let dcopserver_dummy.cpp contain a forward
declaration just like dcopserver.la.cpp, instead of being empty.
Cheers,
Waldo
- --
bastian at kde.org -=|[ SuSE, The Linux Desktop Experts ]|=- bastian at suse.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iD8DBQE/FcxLN4pvrENfboIRAl0/AJ0S3uz8h2av3iD+YoMTujjpDgun0ACbBV94
LKBsO4HBTO+OQ75nWdW/lOI=
=rplE
-----END PGP SIGNATURE-----
More information about the kde-core-devel
mailing list