[LLVMdev] Setting up a cross-compiler for cortex-m3

Renato Golin rengolin at systemcall.org
Wed Jul 18 06:52:15 PDT 2012


On 18 July 2012 14:33, salvatore benedetto
<salvatore.benedetto at gmail.com> wrote:
> but I still haven't figure out how to build for cortex-m3
>
> clang -march=armv7-m -mfloat-abi=soft <something missing?> testReference.cpp -c

-march should have done the trick.

You can also try -mcpu=cortex-m3,

or try -ccc-host-triple armv7m-none-gnueabi (or -eabi),

and possibly -ccc-gcc-name code sourcery's gcc,

or possibly --sysroot=code sourcery/libc

-- 
cheers,
--renato

http://systemcall.org/



More information about the llvm-dev mailing list