Thread overview
GDC cross compiler documentation / tutorial
Nov 04, 2012
Johannes Pfau
Nov 04, 2012
Jacob Carlborg
Nov 04, 2012
Johannes Pfau
Nov 04, 2012
Jacob Carlborg
November 04, 2012
I wrote some documentation on how to build a gdc cross-compiler: http://gdcproject.org/wiki/Cross%20Compiler

For now there's only a tutorial describing how to use crosstool-NG with gdc, but crosstool-NG already supports many different configurations: http://gdcproject.org/wiki/Cross%20Compiler/crosstool-NG

crosstool-NG allows to build cross compilers for these architectures: Alpha, ARM, AVR32, Blackfin, MIPS, OpenRISC/or32(+), PowerPC, s390, SPARC, SuperH, x86

Supported C libraries: uclibc, eglibc, glibc, mingw, newlib

Supported OS: linux, windows, bare-metal

Some configurations probably won't work with gdc right now, windows/mingw builds probably need additional patches to be usable.

crosstool-NG also allows to build canadian-cross compilers, where the
build machine != host machine != target machine.
For example this allows to build a cross compiler on Linux/x86-64 which
runs on Windows/x86 and compiles code for Linux/ARM.
November 04, 2012
On 2012-11-04 11:44, Johannes Pfau wrote:

> Supported OS: linux, windows, bare-metal

No support for Mac OS X? The compilers on Mac OS X are cross-compilers out of the box.

-- 
/Jacob Carlborg
November 04, 2012
Am Sun, 04 Nov 2012 11:48:08 +0100
schrieb Jacob Carlborg <doob@me.com>:

> On 2012-11-04 11:44, Johannes Pfau wrote:
> 
> > Supported OS: linux, windows, bare-metal
> 
> No support for Mac OS X? The compilers on Mac OS X are cross-compilers out of the box.
> 

AFAICS you can use crosstool-NG on OSX to generate cross compilers which run on OSX and compile for other OS, but you can't create a cross compiler which runs on windows / linux and compiles for OSX.
November 04, 2012
On 2012-11-04 12:02, Johannes Pfau wrote:

> AFAICS you can use crosstool-NG on OSX to generate cross compilers
> which run on OSX and compile for other OS, but you can't create a cross
> compiler which runs on windows / linux and compiles for OSX.

Ok, I see. I was mostly thinking of compiling both 32 and 64bit or compiling for ARM.

-- 
/Jacob Carlborg