[LLVMdev] Cross compiling llvm with arm toolchain

Martin Guy martinwguy at gmail.com
Tue Jul 6 04:28:33 PDT 2010

> I've tried arm-2008q3-72,
>  arm-2009 and arm-2010q1-202 from code-sourcery with little success -
>  arm2010q1 fails to compile, arm-2009 take an age to link and arm-2008q3
>  seems to work but only when compiled with -O0. Does anyone have any
>  advice on the matter?

CS's release series is renowned for being bug-ridden.

To be fair, this is probably because CS do bleeding-edge new GCC
developments without any community involvement. The good news is that
their ground-breaking work usually gets merged into mainline GCC
subsequently, and tested and quality-controlled as time goes by. So,
unless you need some feature only present in a CS release, you're more
likely to get a working cross-compiler by using one derived from the
main release sequence of GCC.
  One example is the ones provided by the emdebian.org - if you need
to install the Debian packages that emdebian provide onto a non-Debian
system, you can simply "ar x" the .deb file, the unpack the resulting
data.tar.gz in /, maybe also checking the contents of "control.tar.gz"
for any symbolic-link-creation in its "postinst" script.

Another way would be to use llvm itself, of course. All llvm binaries
can generate code for all supported processors.


More information about the llvm-dev mailing list