Issues with ld: "bootstrap with --static" rearing its ugly head

Stephen Bosch manager at vodacomm.ca
Thu Nov 20 13:57:29 PST 2003


This is brilliant. I am encountering exactly the same problem building 
LFS 5.0 from Slackware 8.1:

Erik Postma wrote:
> Hi all,
> 
> Working on LFS 5.0 from SuSE 7.0. I had the following issues:

> 2) During make check of binutils pass 2 in chap. 5, one test failed
> unexpectedly: 
> 
>  ld/testsuite/ld-bootstrap/bootstrap.exp "bootstrap with --static"
> 
> Now I wish I had read more carefully the text saying "There should be no
> unexpected fails here." Having grown bold by the "solution" to the
> previous failure I decided I'd just continue again. I now realise that
> was _not_ a wise thing.

I don't recall any such failure, but if I am having the next thing 
happen, then it must have failed.

> 3) In chapter 6 section Re-adjusting the toolchain I ran (just like the
> book says) make -C ld install in the binutils-build directory, then
> removed the binutils-build directory, and subsequently applied the sed
> script. Then the 'make a trivial C program, compile it and readelf it'
> test. This failed horribly:
> 
> # gcc dummy.c
> /tools/lib/gcc-lib/i686-pc-linux-gnu/3.3.1/../../../../i686-pc-linux-gnu/
> bin/ld: error while loading shared libraries: libbfd-2.14.so: cannot open
> shared object file: No such file or directory collect2: ld returned 127
> exit status
> 
> After some backtracking, ld turned out to be
> the problem:
> 
> # ldd /tools/bin/ld
>         libbfd-2.14.so => not found
>         libc.so.6 => /tools/lib/libc.so.6 (0x40017000)
>         /tools/lib/ld-linux.so.2 => /tools/lib/ld-linux.so.2 (0x40000000)

This is *exactly* what I get. As it has taken me three days to get this 
far, I am not relishing the prospect of starting over, especially as I 
need this machine for work.

A few people have had this problem. Perhaps a note about the 
--disable-nls should be added to LFS 5.0? Erik is also right -- that's a 
bit of a kludge.

Erik, I presume you started over?

I will try again with LFS 5.0 making sure to use --disable-nls with 
binutils pass 2, but if it does this again I'm going back to 4.1.

-Stephen-




More information about the lfs-support mailing list