This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: linker errors when compiling and linking with a new glibc


On Friday 20 March 2009 13:55:03 Ryan Arnold wrote:
> On Fri, Mar 20, 2009 at 12:48 PM, Daniel De La Zerda wrote:
> > I don't think that debugging will help. When I run /bin/ls I get a
> > segmentation fault as well, but when I run /bin/cat I don't get the
> > segmentation fault and it works as expected. I think I can't just include
> > the original "/lib/libgcc_s.so.1" that is installed in my system into my
> > new glibc tree. I'm not an expert but I think I have to get one that is
> > built with my own glibc, but I dont know how. Does anybody know?
>
> The segmentation fault when running /bin/ls is a symptom of trying to
> use LD_LIBRARY_PATH when the path you specify doesn't have  a complete
> set of libraries.  Personally I rarely ever use LD_LIBRARY_PATH.  The
> loader can't find the libraries it needs.

not so sure ... if your old glibc is in /lib, then setting LD_LIBRARY_PATH to 
the new glibc is wrong -- the old loader will still be used (since /bin/ls set 
PT_INTERP to a hardcoded path).  you need to manually execute the new loader, 
tell the new loader where the new libs are, and then tell it the binary to 
execute.

but i've only been half following this discussion ... maybe i'm completely off 
base
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]