gcc-3.4.3 bootstrap error

Terror Duizel duizeltjuh at hotmail.com
Thu Feb 23 10:19:41 PST 2006

On 2/23/06, Terror Duizel <duizeltjuh at hotmail.com> wrote:
>i did everything as the book says but i get the next error when bootstrap
>mv libgcc_s.so.1.tmp libgcc_s.so.1 && ln -s libgcc_s.so.1 libgcc_s.so
>/tools/i686-pc-linux-gnu/bin/ld:/usr/lib/libc.so: file format not
>recognized; treating as linker script
>/tools/i686-pc-linux-gnu/bin/ld:/usr/lib/libc.so:5: syntax error
>collect2: ld returned 1 exit status

What's your host distro?

As a workaround, try the following after clearing the gcc-build
directory.  Change --enable-shared to --disable-shared in the
configure line.  Then, if everything completes successfully, run the
following command after `make install':

ln -sv libgcc.a `gcc -print-libgcc-file-name | \
	sed 's/libgcc/&_eh/'`

This should give you a symlink libgcc_eh.a -> libgcc.a in


it doesn't work my host distro is fedora linux 4 with gcc-4.0 could this be 
the problem.

  You're right at the start of chapter 5, binutils decided you were
running on i686, but now it fails to recognize the host's libc ?

>/tools/i686-pc-linux-gnu/bin/ld:/usr/lib/libc.so:5: syntax error

  Is this an ancient libc5 system ?  If it is, it's way too old to build
LFS.  Or, perhaps, you have some sort of libc5 for compatability with
very old applications ?

  If it isn't running libc5, what cpu and distro, and what do 'ld -V'
'gcc -v' and '/lib/libc.so.6' report ?


my distro is fedora linux 4 and my cpu is a athlon xp 2800+

lfs:/mnt/lfs/sources/gcc-build$ ld -v
GNU ld version 20041220

lfs:/mnt/lfs/sources/gcc-build$ gcc -v
Using built-in specs.
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info --enable-shared --enable-threads=posix 
--enable-checking=release --with-system-zlib --enable-__cxa_atexit 
--disable-libunwind-exceptions --enable-libgcj-multifile 
--enable-languages=c,c++,objc,java,f95,ada --enable-java-awt=gtk 
Thread model: posix
gcc version 4.0.0 20050519 (Red Hat 4.0.0-8)

lfs:/mnt/lfs/sources/gcc-build$ /lib/libc.so.6
GNU C Library development release version 2.3.5, by Roland McGrath et al.
Copyright (C) 2005 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
Compiled by GNU CC version 4.0.0 20050525 (Red Hat 4.0.0-9).
Compiled on a Linux 2.4.20 system on 2005-05-30.
Available extensions:
        GNU libio by Per Bothner
        crypt add-on version 2.1 by Michael Glad and others
        Native POSIX Threads Library by Ulrich Drepper et al
        The C stubs add-on version 2.1.2.
        NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
        Glibc-2.0 compatibility add-on by Cristian Gafton
        GNU Libidn by Simon Josefsson
Thread-local storage support included.
For bug reporting instructions, please see:

More information about the lfs-support mailing list