undefined reference to dlopen, dlclose, dlsym and dlerror
After a harddisk crash I had to reinstall my system. Now I'm having problems compiling programs, like modlogan 0.8.13.
./configure runs okay, but during make I get the error: mplugins.o(.text+0xed): In function `mplugins_load_plugins': /usr/src/modlogan-0.8.13/src/mplugins.c:127: undefined reference to `dlopen' mplugins.o(.text+0x11c):/usr/src/modlogan-0.8.13/src/mplugins.c:142: undefined reference to `dlsym' mplugins.o(.text+0x2f5):/usr/src/modlogan-0.8.13/src/mplugins.c:134: undefined reference to `dlerror' mplugins.o(.text+0x43c): In function `mplugins_free': /usr/src/modlogan-0.8.13/src/mplugins.c:212: undefined reference to `dlclose' collect2: ld returned 1 exit status make[3]: *** [modlogan] Error 1 make[3]: Leaving directory `/usr/src/modlogan-0.8.13/src' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/usr/src/modlogan-0.8.13/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/src/modlogan-0.8.13' make: *** [all] Error 2 In the configure output I see: checking for dlopen... no checking for dlopen in -ldl... no checking for dlopen in -lsvld... no checking for dld_link in -ldld... no checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes configure: creating libtool appending configuration tag "CXX" to libtool I have these packages installed: glib-1.2.10, glib2-2.6.5, glibc-2.3.5, glibc-solibs-2.3.5, glibc-zoneinfo-2.3.5, libtool-1.5.14 I don't know where to start, the system is fresh... I got the same errors with checkinstall. Thanks for any directions. |
This looks like a problem with the libdl package, or possibly the libdb-devel package if you have one of those. libdb handles dynamic linking, and implements these functions in the files /usr/lib/libdl.a and /usr/lib/libdl.so
(Re)install libdbl and I think that should fix it. |
libdl seemed to be in the glibc en glibc-solibs packages. Reinstalling the glibc package solved the problem indeed.
Thanks for the hint! |
Quote:
- Jerry Kaidor |
This was a very long time ago, but I'm pretty sure that I just reinstalled the package that came with Slackware.
|
Quote:
* Inside the "src/osdep/unix" directory, I modified Makefile - the "slx" ( Shadow Linux ) target to include "-ldl" in the BASELDFLAGS list. BTW, the package I was trying to build was UW IMAP. - Jerry Kaidor |
All times are GMT -5. The time now is 12:12 AM. |