[fpc-devel] Problem with fpcmake when doing crossbuild
mail at michael-ring.org
Tue May 28 12:24:16 CEST 2013
In case my guesswork was right this would be the fix to Makefile.fpc:
--- Makefile.fpc (revision 24625)
+++ Makefile.fpc (working copy)
@@ -169,8 +169,12 @@
# Always use newly created fpcmake
# Build/install options
@@ -316,6 +320,11 @@
# create new compiler
$(MAKE) compiler_cycle RELEASE=1
+# Buld a new native fpcmake when cross-compiling.
+# Fresh native compiler and RTL are ready at this stage.
+ $(MAKE) -C utils/fpcm bootstrap $(BUILDOPTS)
$(MAKE) rtl_clean $(CLEANOPTS)
# build everything
Am 28.05.13 10:59, schrieb Michael Ring:
> I was having troubles today installing ppcrossarm from trunk, I have a
> workarround for the problem but I question myself how to really fix
> the problem:
> make clean buildbase CROSSINSTALL=1 OS_TARGET=embedded CPU_TARGET=arm
> SUBARCH=$SUBARCH CROSSOPT="-godwarfsets -gw2 -O-"
> works fine. But then installation goes wrong because fpcmake was not
> build, but it is needed for installation (Question is why it is
> necessary to invoke fpcmake at all;-)).
> I can fix this by adding:
> make -C utils/fpcm bootstrap 'FPC=/Users/ring/devel/fpc/compiler/ppc'
> OS_TARGET=darwin CPU_TARGET=i386
> to my buildscript, but my guess is that this should better be added to
> the buildbase rule, there's an entry for that in the build rule
> *ifdef CROSSCOMPILE
> $(MAKE) -C utils/fpcm bootstrap $(BUILDOPTS)
> I have added this rule to my makefile, seems to work. I have no idea
> if I break anything by adding this to the makefile
> fpcmake is now created in directory utils/fpcm/fpcmake
> Now installation nearly works, last problem is that FPCMAKE path gets
> defined wrong as:
> make -C embedded all
> /Users/ring/devel/fpc/utils/fpcm/bin/i386-darwin/fpcmake -p
> -Tarm-embedded Makefile.fpc
> make: /Users/ring/devel/fpc/utils/fpcm/bin/i386-darwin/fpcmake: No
> such file or directory
> I can fix this by defining FPCMAKENEW to the real position of fpcmake
> after the build:
> sudo make installbase CROSSINSTALL=1 OS_TARGET=embedded
> CPU_TARGET=arm SUBARCH=$SUBARCH CROSSOPT="-godwarfsets -gw2 -O-"
> At this point I ask myself if this error exists because I did
> something wrong building fpcmake.
> Any ideas?
> fpc-devel maillist - fpc-devel at lists.freepascal.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fpc-devel