'Compiler cannot create executables'

Ken Moffat ken at linuxfromscratch.org
Sun Aug 21 13:43:14 PDT 2005

On Sun, 21 Aug 2005, Cliff McDiarmid wrote:

> Hi
> I forgot to mention this in reply to Ken.
> Surely the key to the problem is this line from config.log, it is the same whatever package I try to compile.   What is `--eh-frame-hdr'??
> configure:2828: checking for C compiler default output file name
> configure:2831: gcc  -O2 -mcpu=i686 -march=i686   conftest.c  >&5
> /usr/bin/ld: unrecognized option `--eh-frame-hdr'
> Try `ld --help' or `ld --usage' for more information.
> collect2: ld returned 64 exit status

  AFAIK it's a detail of the toolchain (google isn't very good at 
matching things starting with a dash, even in quotes, but trying without 
the dashes found a bit, including a post from Greg Schafer from before 
5.0 showing that this wasn't detected (under the old method, this would 
be before 'pure lfs') if the host system was running binutils-2.12. 
That is why this feature should be present in LFS-5 or later.

  As to what it does, no idea, but it looks as if gcc is passing it to 
ld.  A search on my running 6.1 system shows eh-frame-hdr is in ld, g++, 
c++, cpp, gcc and within gcc's specfile.  Looks as if the specfile is 
what causes gcc to use the flag.  Also a reference in 'info gcc'.  Did 
you delete /usr/lib/libgcc_s* ?

  das eine Mal als Tragödie, das andere Mal als Farce

More information about the blfs-support mailing list