Port-powerpc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Known probs with ld-1.5.2 and dwarf2?



Hello,

I'm trying out the GCC trunk (gcc.gnu.org) on a 1.5.2 userland but am finding it generates dud executables. It appears to be related to the debug info vis:

ac131313@nettle$ gcc --version
gcc (GCC) 3.1 20020202 (experimental)
Copyright (C) 2002 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 PARTICULAR PURPOSE.

Strip the debug info before linking:

ac131313@nettle$ gcc -g -c hello.c
ac131313@nettle$ strip -g hello.o
ac131313@nettle$ gcc hello.o
ac131313@nettle$ ./a.out
Hello World

Don't strip the debug info before linking:

ac131313@nettle$ gcc -g -c hello.c
ac131313@nettle$ gcc hello.o
ac131313@nettle$ ./a.out
bash: ./a.out: cannot execute binary file

Compile without debug info:

ac131313@nettle$ gcc -c hello.c
ac131313@nettle$ gcc hello.o
ac131313@nettle$ ./a.out
Hello World

The gcc is generating dwarf2 debug info.

Is this a known problem?

Andrew




Home | Main Index | Thread Index | Old Index