Re: [Lazarus] Cross-compiling - MIPS

2012-10-30 Thread Mark Morgan Lloyd
Red herring alert :-) SkyDiablo wrote: [Built what he believed was a binary for mipsel, and on running it on the target got] # cat /proc/version Linux version 2.6.32.27 (gcc version 4.3.3 (GCC) ) # sh helloWorld4MIPS helloWorld4MIPS: line 1: syntax error: unexpected ( I've just had

Re: [Lazarus] Cross-compiling - MIPS

2012-10-30 Thread SkyDiablo
YES, i think i got it! okay, i was not sure over the hole time if my toolchain is the right choise... but now, i know it, yes it is! i use this toolchain to compiling a helloWorld c++ application and got the same error with fpc. some time later, i get a response from my test-system: FPU

Re: [Lazarus] Cross-compiling - MIPS

2012-10-30 Thread Mark Morgan Lloyd
SkyDiablo wrote: YES, i think i got it! okay, i was not sure over the hole time if my toolchain is the right choise... but now, i know it, yes it is! i use this toolchain to compiling a helloWorld c++ application and got the same error with fpc. some time later, i get a response from my

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread SkyDiablo
i cant see the solution, i think it is the wrong binutilspack, right? Am 28.10.2012 21:40, schrieb Mark Morgan Lloyd: SkyDiablo wrote: it is a simple openWRT linux system. okay, i think i need other binunits/toolchain for compiling? can anyone help me to compile the right toolchain for

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Mark Morgan Lloyd
SkyDiablo wrote: i cant see the solution, i think it is the wrong binutilspack, right? What do you mean? Am 28.10.2012 21:40, schrieb Mark Morgan Lloyd: SkyDiablo wrote: it is a simple openWRT linux system. okay, i think i need other binunits/toolchain for compiling? can anyone help me to

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread SkyDiablo
okay, again from scratch. I downloaded and installed the bintuils for windows: Sourcery CodeBench Lite 2012.03-63 for MIPS GNU / Linux - https://sourcery.mentor.com/GNUToolchain/release2190 Then I looked at the FPC 2.7.x Sources downloaded (daily snapshot) -

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Mark Morgan Lloyd
SkyDiablo wrote: okay, again from scratch. I downloaded and installed the bintuils for windows: No. You've already said that you've got a Debian (presumably x86) system available. Use that, and follow the instructions I put in the wiki page: I wrote those line-by-line as I was doing the job

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread SkyDiablo
Having the cross compiler and RTL, you should then be able to either build a native compiler etc. or to compile trivial programs (some fancy stuff won't work yet because you haven't built the full FCL). The native compiler can be copied onto your mipsel system, and is currently good enough

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Lukasz Sokol
On 29/10/2012 12:44, SkyDiablo wrote: okay, again from scratch. I downloaded and installed the bintuils for windows: [snip] # sh helloWorld4MIPS helloWorld4MIPS: line 1: syntax error: unexpected ( what can or should I do now that I can programs under lazarus for my router which is

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Mark Morgan Lloyd
SkyDiablo wrote: Having the cross compiler and RTL, you should then be able to either build a native compiler etc. or to compile trivial programs (some fancy stuff won't work yet because you haven't built the full FCL). The native compiler can be copied onto your mipsel system, and is

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread SkyDiablo
Am 29.10.2012 15:53, schrieb Lukasz Sokol: You produced an /executable/ ? Then why not just do ./helloWorld4MIPS in the dir where the binary is copied to ? (yes, dot-slash is needed unless you have this directory added to PATH) AFAIK, doing sh $file will attempt to run it as shell

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Mark Morgan Lloyd
SkyDiablo wrote: Am 29.10.2012 15:53, schrieb Lukasz Sokol: You produced an /executable/ ? Then why not just do ./helloWorld4MIPS in the dir where the binary is copied to ? (yes, dot-slash is needed unless you have this directory added to PATH) AFAIK, doing sh $file will attempt to run

Re: [Lazarus] Cross-compiling - MIPS

2012-10-29 Thread Mark Morgan Lloyd
Mark Morgan Lloyd wrote: SkyDiablo wrote: Am 29.10.2012 15:53, schrieb Lukasz Sokol: You produced an /executable/ ? Then why not just do ./helloWorld4MIPS in the dir where the binary is copied to ? (yes, dot-slash is needed unless you have this directory added to PATH) AFAIK, doing sh

Re: [Lazarus] Cross-compiling - MIPS

2012-10-28 Thread SkyDiablo
it is a simple openWRT linux system. okay, i think i need other binunits/toolchain for compiling? can anyone help me to compile the right toolchain for windows? the task is: create a crosscompile compiler for FPC from windows to linux MIPS systems... in the past i have learn to compile the

Re: [Lazarus] Cross-compiling - MIPS

2012-10-28 Thread Mark Morgan Lloyd
SkyDiablo wrote: it is a simple openWRT linux system. okay, i think i need other binunits/toolchain for compiling? can anyone help me to compile the right toolchain for windows? the task is: create a crosscompile compiler for FPC from windows to linux MIPS systems... in the past i have learn

Re: [Lazarus] Cross-compiling - MIPS

2012-10-27 Thread SkyDiablo
ok, now i can compile some binaries, but they dont run on my target system, i get this error: helloWorld4MIPS: line 1: syntax error: unexpected ( so i'm not sure about the right toolchain? i get a binary thats starts with ?ELF, what does it mean this ELF ? by the way, i have switch to

Re: [Lazarus] Cross-compiling - MIPS

2012-10-27 Thread waldo kitty
On 10/27/2012 15:37, SkyDiablo wrote: ok, now i can compile some binaries, but they dont run on my target system, i get this error: i cannot help very much with your goals but... helloWorld4MIPS: line 1: syntax error: unexpected ( so i'm not sure about the right toolchain? i get a binary

Re: [Lazarus] Cross-compiling - MIPS

2012-10-26 Thread SkyDiablo
ok, i play around with this stuff, but now i get this error at compiling: project1.lpr(0,0) Fatal: Can not find unit system used by Project1. i cant fix it :( Am 25.10.2012 20:15, schrieb Sven Barth: On 25.10.2012 20:05, SkyDiablo wrote: This is related to the fact that 2.6.0's fpcmake

Re: [Lazarus] Cross-compiling - MIPS

2012-10-26 Thread Sven Barth
Am 26.10.2012 18:59 schrieb SkyDiablo skydia...@gmx.net: ok, i play around with this stuff, but now i get this error at compiling: project1.lpr(0,0) Fatal: Can not find unit system used by Project1. i cant fix it :( There are three things you can try: 1. Ensure that your project settings

Re: [Lazarus] Cross-compiling - MIPS

2012-10-25 Thread Sven Barth
Am 24.10.2012 22:08 schrieb SkyDiablo skydia...@gmx.net: wow ! thats amazing! okay, i create the follow batch-file: === set PATH=C:\lazarus\fpc\2.6.0\bin\i386-win32;C:\Program Files (x86)\CodeSourcery\Sourcery G++ Lite\lib\gcc set

Re: [Lazarus] Cross-compiling - MIPS

2012-10-25 Thread SkyDiablo
so, next one. there was an fail PREFIX at all so i change it to mips-linux-gnu-, this scrips works at first: === set PATH=C:\lazarus\fpc\2.6.0\bin\i386-win32;C:\Program Files (x86)\CodeSourcery\Sourcery G++ Lite\lib\gcc;C:\Program Files

Re: [Lazarus] Cross-compiling - MIPS

2012-10-25 Thread Sven Barth
Am 25.10.2012 12:06, schrieb SkyDiablo: so, next one. there was an fail PREFIX at all so i change it to mips-linux-gnu-, this scrips works at first: === set PATH=C:\lazarus\fpc\2.6.0\bin\i386-win32;C:\Program Files (x86)\CodeSourcery\Sourcery

Re: [Lazarus] Cross-compiling - MIPS

2012-10-25 Thread SkyDiablo
This is related to the fact that 2.6.0's fpcmake does not support mips-linux yet. Possible solution: First do (once, independantly) the following: (assuming the current dir is your 2.7.1 source directory) cd utils\fpcm make all And then add FPCMAKE=%YOURSOURCEDIR%\utils\fpcm\fpcmake.exe to

Re: [Lazarus] Cross-compiling - MIPS

2012-10-25 Thread Sven Barth
On 25.10.2012 20:05, SkyDiablo wrote: This is related to the fact that 2.6.0's fpcmake does not support mips-linux yet. Possible solution: First do (once, independantly) the following: (assuming the current dir is your 2.7.1 source directory) cd utils\fpcm make all And then add

Re: [Lazarus] Cross-compiling - MIPS

2012-10-24 Thread SkyDiablo
wow ! thats amazing! okay, i create the follow batch-file: === set PATH=C:\lazarus\fpc\2.6.0\bin\i386-win32;C:\Program Files (x86)\CodeSourcery\Sourcery G++ Lite\lib\gcc set PREFIX=mips-linux- set BINUTILSDIR=C:\Program Files

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Mark Morgan Lloyd
SkyDiablo wrote: hiho! i search a solution to build my hello world source from my windows x64 system to a openWRT (linux) with a MIPS CPU system - cross-compiling? i do not find a working solution :( now i'm trying to build with a debian system, but is dosnt work for now :( First, this is

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Michael Schnell
Hi, I suggest first seeking for help to do a command line Hello World for your MIPS system in the fpc developer's mailing ( fpc-de...@lists.freepascal.org ) list and when this works, try to do a Lazarus application, as same involves compiling the LCL for MIPS which I suppose is a decent

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Henry Vermaak
On 22/10/12 09:20, Mark Morgan Lloyd wrote: SkyDiablo wrote: hiho! i search a solution to build my hello world source from my windows x64 system to a openWRT (linux) with a MIPS CPU system - cross-compiling? i do not find a working solution :( now i'm trying to build with a debian system,

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Mark Morgan Lloyd
Michael Schnell wrote: Hi, I suggest first seeking for help to do a command line Hello World for your MIPS system in the fpc developer's mailing ( fpc-de...@lists.freepascal.org ) list and when this works, try to do a Lazarus application, as same involves compiling the LCL for MIPS which I

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Mark Morgan Lloyd
Henry Vermaak wrote: First, this is the Lazarus conf and while FPC now works (subject to some potential code generation issues) targeting little-endian MIPS it's probably some while before Lazarus will. The issue here is that building Lazarus requires the current stable version of FPC (2.6.0),

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Henry Vermaak
On 22/10/12 10:02, Mark Morgan Lloyd wrote: Henry Vermaak wrote: I built lazarus with fpc 2.7.1 for armhf this weekend. Why do you say 2.6.0 is needed? Because of the feeling with which most developers insist that 2.6.0 is the one true way :-) Yes, I tend to use 2.6.0, too, but armhf port

Re: [Lazarus] Cross-compiling - MIPS

2012-10-22 Thread Vincent Snijders
2012/10/22 Henry Vermaak henry.verm...@gmail.com: Yes. I remember a rule that lazarus trunk is supposed to compile with both the latest fpc release and fpc trunk. Don't know if that's still the case, though. And with fixes head, because that is likely to be used by the next FPC release.

[Lazarus] Cross-compiling - MIPS

2012-10-21 Thread SkyDiablo
hiho! i search a solution to build my hello world source from my windows x64 system to a openWRT (linux) with a MIPS CPU system - cross-compiling? i do not find a working solution :( now i'm trying to build with a debian system, but is dosnt work for now :( greez thx, sky... --