[fpc-pascal] FPCUP Windows now has Go32V2 cross compiling support
Tomas Hajny
XHajT03 at hajny.biz
Fri Sep 20 18:55:35 CEST 2013
On Fri, September 20, 2013 18:42, Reinier Olislagers wrote:
Hi Reinier,
> Recent posts have lead me to look again at my FPC/Lazarus
> downloader/compiler fpcup [1] to see if I could get cross compiling
> going from win64 or win64 to Go32v2.
>
> This works for me:
> 1) Setup:
> Create directory c:\development
> Get crosscompile binutils from
> ftp://ftp.freepascal.org/pub/fpc/contrib/cross/mingw/binutils-2.20-win32-i386-go32v2.zip
> Place the binaries in c:\development\cross\bin\i386-go32v2
>
> Binaries include
> i386-go32v2-ar.exe
> i386-go32v2-as.exe
> i386-go32v2-ld.exe
> i386-go32v2-objdump.exe
> i386-go32v2-strip.exe
>
> 2) Let fpcup compile a new FPC and Lazarus:
> fpcup
>
> 3) Then do a cross compile; note this does require the cross compilation
> binutils but fpcup will warn you if they're missing
> fpcup --cputarget=i386 --ostarget=go32v2
>
Which FPC branch do you use, trunk or fixes? If it is trunk, it should be
able to use not only the internal assembler but also internal linker and
thus these binutils are not used at all (unless also using -Xe). If it is
fixes, then I wonder what happens there because the linker included in the
package above completely refuses object files created by FPC 2.6.2
(admittedly, I haven't tested a fixes snapshot, but I wouldn't expect
major changes in this area merged to fixes) - the linker complains about
unsupported section type and doesn't find the required symbols.
Tomas
More information about the fpc-pascal
mailing list