powerpc-rtems-gcc question

Brendan Simon brendan at dgs.monash.edu.au
Sat Oct 31 08:59:42 UTC 1998


I have successfully compiled the gcc suite following the rtems-4.0.0
documentation.  Before I try to use RTEMS I thought I would try a little
test that flashes a led on the ADS board.  It is about 20 lines of code
but the executalbe seems quite large.  I used objcopy to generate an
s-record and it is nearly 4kb.  I am not using any libc functions (that
I know of anyway).  Is the compliler linking in all of libc or parts of
RTEMS by default ???
Can I use this as a pure powerpc compiler without an implicit linking.
It also complains about _start not being defined.  I assume crt0.o is
being linked in but I'm not quite sure which one and where the source is
that generated the crt0.o

The command is
powerpc-rtems-gcc -Wall -O2 -Wl,-Ttext=0x1000000,-Tdata=0x20000000 -o
leds.elf leds.c

The only library that I assume is being linked in implicitly is libc.a.
Is this true ?
Are there any linker scripts involved.  Can I define my own if need be
and where should I put it.

Thanks.
Brendan Simon




More information about the users mailing list