[uClibc]cvs commit to uClibc/ld.so by andersen

Erik Andersen andersen at lineo.com
Mon Apr 16 23:10:50 UTC 2001


On Mon Apr 16, 2001 at 04:48:13PM -0500, Manuel Novoa III wrote:
> Erik,
> 
> On Mon, 16 Apr 2001, Erik Andersen wrote:
> > Well, right now is is about 20k and doesn't work at all.  Easpecially not
> > for things like ELF binaries...  I'm reading through some shared lib
> > loader code to make sure I understand everything involved in making
> > one that actually works.  So far I just took some code, make it compile,
> > and checked it in.  But that code is (as Michael Shmulevich correctly
> > noticed nad much to my embarassement) designed for a.out junk...
> > 
> > So the stuff that I checked in isn't going to work at all.  The ELF loading
> > stuff in the ld.so package (in the d-link directory) is ugly and was designed 
> > to work around the failings of a badly designed C library.  The stuff in Glibc 
> > looks workable, but seems overly large.
> > 
> > For the moment I think I'll just remove the ld.so junk to avoid further 
> > embarassment,
> 
> Maybe I wasn't clear in my emails earlier.  I have a patched version of
> ld.so-1.9.11 which generates two dynamic linkers ld-linux-<arch>-uclibc.so.1;
> one looks in /lib and /usr/lib as usual (intended for a glibc-less system) and
> one which looks in /usr/<arch>-linux-uclibc/lib only (intended for a
> development system).  The later also looks for the ld.so.cache file in
> /usr/<arch>-linux-uclibc/etc and I've built the appropriate versions of
> ldconfig, ldd, etc.  The idea is that you put the second version in /lib on the
> devel system, and it works (assuming same arch of course).  You put the first
> version in /lib on the target system.  Since the paths of the shared libs
> aren't included in the compiled bins, the shared lib dependencies are resolved
> correctly in both cases.  I've successfully used this even with libdl.so.  I
> was just waiting for your input about directory locations.  Oh yes, of course
> you need to set DYNAMIC_LINKER appropriately when you build the gcc wrapper.

Ok.  Cool.  Mind checking it in then?  

Still, longer term, we do need something more like what is in glibc.
This will provide us with dlopen() and friends (which are needed for
iptables, for example), and also hopefully will allow us to run on 
any platform, not just i386, m68k, and sparc (which is what 
ld.so 1.9.11 is limited to).

 -Erik

--
Erik B. Andersen   email:  andersen at lineo.com
--This message was written using 73% post-consumer electrons--





More information about the uClibc mailing list