[Lazarus] Cross-compiling -> MIPS

Mark Morgan Lloyd markMLl.lazarus at telemetry.co.uk
Mon Oct 29 14:48:51 CET 2012


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 (there might be a 
minor glitch in there somewhere because I changed a directory layout 
part way through, but apart from the the commands are still the same).

You start off with a /specific/ version of binutils, slightly older 
won't work and somebody's already said in the ML that newer ones are 
problematic (you /have/ read that thread I pointed you at, haven't 
you?). You build yourself a cross-compiler, you then use that to build 
yourself an RTL. I did that about a week ago, it works.

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 to recompile itself.

As LBSC used to write, "follow the words and music and you won't go 
wrong". However if you continue to guess and not to follow the advice 
people are giving you you won't get anywhere: the compiler has only been 
working for a few weeks and everything is still comparatively fragile.

Apologies if I sound slightly less patient than Henry, Michael et al, 
but the basic compiler *DOES* work (I certainly don't have the 
experience to apply non-standard fixes on the fly, and if I did I'd have 
mentioned it). However as I described in a different thread a few days 
ago there are still problems running Lazarus natively on MIPS, so don't 
try that unless you've got time to start investigating the outstanding 
code generation issues.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]




More information about the Lazarus mailing list