Problems linking PSIM programs

Wealand, Barry barry.wealand@lmco.com
Fri Aug 11 18:51:00 GMT 2006


Hello -

I'm trying to use gcc 2.95.3 with binutils 2.14 and newlib 1.9.0 to
build a simple hello.c for use with the PowerPC simulator.  Compiler,
binutils, and newlib were all configured with --target=powerpc-eabi for
a sparc-sun-solaris2.8 host.  I attempt to compile hello.c with:

powerpc-eabi-gcc -msim -o hello hello.c

The response is:

/u00/users/bwealand/GCC/tools/v2.95.3/H-sparc-sun-solaris2.8/powerpc-eab
i/bin/ld: hello: Not enough room for program headers (allocated 2, need
3)
/u00/users/bwealand/GCC/tools/v2.95.3/H-sparc-sun-solaris2.8/powerpc-eab
i/bin/ld: final link failed: Bad value

In the bug-binutils archive, I notice that this problem has appeared in
a number of different situations.  One recommended solution has been to
use later versions of binutils.  I have tried 3 separate versions:
2.11.2, 2.12, and 2.14.  All produce the same result.

>From previous experience, using gcc 3.4.4 with binutils 2.14 and newlib
1.14.0, I can build hello.c as described above just fine.

I'd appreciate some guidance.  What else should I try / look for?

Thanks in advance!

Barry Wealand
Lockheed Martin
barry.wealand@lmco.com



More information about the Binutils mailing list