ltdl.c in kinit
Paulo Jorge Guedes
Paulo.Guedes at artelecom.pt
Mon Apr 17 19:36:11 CEST 2006
> -----Original Message-----
> From: David Faure [mailto:faure at kde.org]
> Sent: segunda-feira, 17 de Abril de 2006 17:55
> To: Paulo Jorge Guedes
> Subject: Re: ltdl.c in kinit
>
> On Mon, Apr 17, 2006 at 05:22:06PM +0100, Paulo Jorge Guedes wrote:
> > Hi,
> >
> > This commit:
> >
> > --- CMakeLists.txt (revision 530673)
> > +++ CMakeLists.txt (working copy)
> > @@ -84,7 +84,7 @@
> > ########### next target ###############
> > -set(kioslave_SRCS kioslave.cpp)
> > +set(kioslave_SRCS kioslave.cpp ${CMAKE_SOURCE_DIR}/libltdl/ltdl.c)
> > kde4_automoc(${kioslave_SRCS})
> >
> > The code from ltdl.c is already in libkdecore, which kioslave links
to,
> > so no need to add it again.
> > ____________________________________
> >
> > breaks linkage on Windows (both mingw and msvc). It makes sense
though
> > :)
> > There is a similar case with kstyles/keramic.
> >
> > CMakeFiles/kioslave.dir/kioslave.obj: In function `main':
> > d:/kde/kdelibs/kinit/kioslave.cpp:66: undefined reference to
`lt_dlinit'
> > CMakeFiles/kioslave.dir/kioslave.obj: In function `main':
> >
D:/downloads/qt-win-opensource-src-4.1.1/include/QtCore/qbytearray.h:329
> > : undefined reference to `lt_dlopen'
> > CMakeFiles/kioslave.dir/kioslave.obj: In function `main':
> > d:/kde/kdelibs/kinit/kioslave.cpp:76: undefined reference to
`lt_dlsym'
> > d:/kde/kdelibs/kinit/kioslave.cpp:71: undefined reference to
> > `lt_dlerror'
> > d:/kde/kdelibs/kinit/kioslave.cpp:79: undefined reference to
`lt_dlsym'
> > d:/kde/kdelibs/kinit/kioslave.cpp:82: undefined reference to
> > `lt_dlerror'
> > collect2: ld returned 1 exit status
>
> I guess those methods need to be declared with KDECORE_EXPORT then;
can
> you try that?
It works :)
KDECORE_EXPORT doesn't work (yes, I included kdemacros.h), I had to use
__declspec(dllexport) directly.
BTW, is this obsolete?
#ifdef DLL_EXPORT
# define LT_GLOBAL_DATA __declspec(dllexport)
#else
# define LT_GLOBAL_DATA
#endif
Paulo
More information about the Kde-buildsystem
mailing list