[lug] Odd linking errors

Trever M. Shick tshick at objectwave.com
Wed Feb 20 10:19:53 MST 2002


I'm pretty much a newbie to Linux development, but like gnome, there is a 
glib-config script that you can execute like:

gcc -c x.c `glib-config --cflags --libs whateverlibs`

that is supposed to create the gcc flags for compiling....
Maybe that will help?

let me know if I'm way off base because I'm trying to learn  myself.


Trever M. SHick



On Wed, 20 Feb 2002, Riggs, Rob wrote:

> I'm receiving the following errors when linking some executable
> applications:
> 
> /lib/libc.so.6: undefined reference to `_dl_out_of_memory at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_clktck at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_argv at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_check_map_versions at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_debug_mask at GLIBC_2.2.3'
> /lib/libc.so.6: undefined reference to `_dl_load_lock at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_init_all_dirs at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_debug_printf at GLIBC_2.2.3'
> /lib/libc.so.6: undefined reference to `_dl_init at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_all_dirs at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_nloaded at GLIBC_2.2'
> /lib/libc.so.6: undefined reference to `_dl_pagesize at GLIBC_2.2'
> 
> Now, I've seen similar errors reported on a few lists, but no one seems to
> have an adequate answer as to what causes it. The workaround that I've come
> up with is to explicitly link to ld-linux.so.2 at the very end of the linker
> command line. 
> 
> However, when running the linker with verbose output, I see that it does
> indeed link with ld-linux.so.2, but at the beginning.
> 
> collect2 version 2.96 20000731 (Red Hat Linux 7.1 2.96-85) (i386 Linux/ELF)
> /usr/bin/ld -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 ....
> 
> I'm running Red Hat 7.1 with the latest patches.
> 
> This doesn't occur in most cases. For instance I haven't had any problems
> with stock SRPMS failing to compile and link. This is only occuring with an
> in house app that I am looking at porting from Solaris.
> 
> Any clue as to what would cause this problem?
> 
> -Rob
> 
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> 




More information about the LUG mailing list