[uClibc] About dynamic linking link to libc.so.6 and ld-linux.so.2
Rob Landley
rob at landley.net
Tue Jul 6 04:16:26 UTC 2004
On Monday 05 July 2004 05:22, ZivHuang wrote:
> Hi all:
>
> I builded uClibc 0.9.26 under red hat 9.
>
> When I used mips cross compiler to build my programs, I found some dynamic
> linking programs link to libc.so.6 and ld-linux.so.2 when pthread library
> is utilized.
>
> Can someone tell my what's wrong? Thanks. ^_^
>
> Best regards.
>
> Ziv
There's some unresolved symbol it's not getting out of uclibc. It could be
anything. Sometimes it means one of the libraries you're linking to is
linking to libc.so.6, sometimes it's a weak symbol, sometimes it's a library
path ordering problem...
This is why the chroot environment was invented. Sometimes gcc _can_ find
things in uclibc, but has a hardwired call to glibc sneak in there somewhere
instead. (If your compiler uses libgcc, for example...) Gcc is only tested
against glibc by the gcc developers, there are strange dependencies all
overthe place that are only semi-documented.
In a chroot environment, there only is uclibc, so there's nothing there to
confuse gcc. Hence the "buildroot" setup, which you can use to build stuff
and then copy it to the parent system if you'd like...
Rob
--
www.linucon.org: Linux Expo and Science Fiction Convention
October 8-10, 2004 in Austin Texas. (I'm the con chair.)
More information about the uClibc
mailing list