is ne weile her, dass ich was mit FPC gemacht habe, nun is es aber mal wieder so weit. ich habe folgendes vor; habe ein router auf dem ich openWRT aufgespielt habe welcher mit einem MIPS CPU ausgestattet ist. nun will ich mit meiner windows-büchse ein "hello-world" coden und das für mein router compilieren.
kurzerhand mal google gefragt wie das funzen könnte, mit dem ergebnis zu diesem wiki eintrag:
http://wiki.freepascal.org/MIPS_port
daraufhin habe ich folgendes gemacht:
1. Lazarus 1.0.2 (FPC 2.6.0) installiert -> c:\lazarus\
2. Aktuelles Snapshot besorgt: http://www.freepascal.org/develop.html (2.7.X) -> c:\fpctrunk\
3. MIPS compiler erstellt: c:\fpctrunk\compiler\ppmipsel.lpi -> c:\fpctrunk\compiler\mips\pp.exe
4. Crosscompiler erstellen:
Batch File:
Code: Alles auswählen
cd C:\fpctrunc\
set PATH=C:\lazarus\fpc\2.6.0\bin\i386-win32;C:\fpctrunc\compiler\mipsel
make cycle CPU_TARGET=mipsel OS_TARGET=linux
pause
darauf hin habe ich von "cycle" auf "all" gewechselt. nachdem er nun etliche zeilen in die console geballert hat, endet es hiermit:C:\fpctrunc>make cycle CPU_TARGET=mipsel OS_TARGET=linux
make: *** No rule to make target `cycle'. Stop.
darauf hin habe ich das ganze um den "PP" parameter erweitert:make -C C:/fpctrunc/rtl 'OPT= ' all
make[4]: Entering directory `C:/fpctrunc/rtl'
make -C linux all
make[5]: Entering directory `C:/fpctrunc/rtl/linux'
mipsel-linux-as -EL -o C:/fpctrunc/rtl/units/mipsel-linux/prt0.o mipsel/prt0.as
process_begin: CreateProcess((null), mipsel-linux-as -EL -o C:/fpctrunc/rtl/unit
s/mipsel-linux/prt0.o mipsel/prt0.as, ...) failed.
make (e=2): Das System kann die angegebene Datei nicht finden.
make[5]: *** [prt0.o] Error 2
make[5]: Leaving directory `C:/fpctrunc/rtl/linux'
make[4]: *** [linux_all] Error 2
make[4]: Leaving directory `C:/fpctrunc/rtl'
make[3]: *** [rtl] Error 2
make[3]: Leaving directory `C:/fpctrunc/compiler'
make[2]: *** [cycle] Error 2
make[2]: Leaving directory `C:/fpctrunc/compiler'
make[1]: *** [compiler_cycle] Error 2
make[1]: Leaving directory `C:/fpctrunc'
make: *** [build-stamp.mipsel-linux] Error 2
Code: Alles auswählen
make all CPU_TARGET=mipsel OS_TARGET=linux PP=pp.exe
darauf hin habe ich "PATH" noch um ein paar angaben erweitert wo er "mips.inc" files finden kann, leider ohne ersichtliche änderung. nun habe ich die doku nochmal genauer gelesen und mir ist dieser teil aufgefallen:make -C C:/fpctrunc/rtl 'OPT= ' all
make[4]: Entering directory `C:/fpctrunc/rtl'
make -C win32 all
make[5]: Entering directory `C:/fpctrunc/rtl/win32'
pp.exe -Ur -Xs -O2 -n -Fi../inc -Fi../i386 -Fi../win -FE. -FUC:/fpctrunc/rtl/uni
ts/i386-win32 -di386 -dRELEASE -Us -Sg system.pp -Fi../win
system.inc(242,4) Fatal: Can't open include file "mips.inc"
Fatal: Compilation aborted
make[5]: *** [system.ppu] Error 1
make[5]: Leaving directory `C:/fpctrunc/rtl/win32'
make[4]: *** [win32_all] Error 2
make[4]: Leaving directory `C:/fpctrunc/rtl'
make[3]: *** [rtl] Error 2
make[3]: Leaving directory `C:/fpctrunc/compiler'
make[2]: *** [cycle] Error 2
make[2]: Leaving directory `C:/fpctrunc/compiler'
make[1]: *** [compiler_cycle] Error 2
make[1]: Leaving directory `C:/fpctrunc'
make: *** [build-stamp.mipsel-linux] Error 2
da "make" das template "cycle" nicht kennt, gehe ich mal davon aus, dass dieser hinweiß zutrifft und "cycle" nicht aktiviert ist? da ich aber "all" nutzt sollte das doch egal sein, oder ? kurzum, ich stocher hier nur in einer trüben suppe rum ohne wirklich zu wissen was ich hier tue. nun den aufruf an euch, ist mein vorhaben überhaupt möglich? und wenn, wie? alternativ, wenn ich das nicht mit windows machen kann, dann vielleicht mit einer linux-distri (zB ubuntu/debian) ?Note: This will only possible with make cycle is activated for mips, at the moment this method cannot be used.
greez & thx,
sky...