[fpc-devel] Windows -> arm-linux (eabi) crossbinutils

Marco van de Voort marcov at stack.nl
Sat Dec 4 17:57:05 CET 2010


Hello crosscompilers,

After a break, I've picked up generating crossbinutils again, and I
succesfully generated win32->arm-elf-linux crossbins.

I used these for e.g. Sheevaplug crosscompiling

ftp://ftp.freepascal.org/pub/fpc/contrib/cross/binutils-2.20-arm-linux-elf.zip

Note that FPC is a bit troublesome in the sense that it wants to run an exe
as assembler on windows. 

Therefore, if you want to pass extra parameters to as, you can't simply make
a wrapper shell script like on unix.

A simple skeleton source for making a simple wrapper is in the "fpcbuild"
archive:

http://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/install/cross/aswrapper.pas?root=fpcbuild&view=log

I compile this and rename the result to arm-linux-as.exe. This allows me to
pass -meabi=4 to AS, as required by sheeva.

One can see the require eabi version on the device by executing by e.g.

cd /usr/lib
readelf -h crt1.o |grep Flags

(install elfutils if necessary)

Greetings

Marco



More information about the fpc-devel mailing list