[cfe-dev] How to compile Clang for ARM Linux on x86_64 Linux?
Anton Korobeynikov
anton at korobeynikov.info
Sun Sep 29 00:35:36 PDT 2013
> It looks like it didn't find clang++, but it did find clang, so maybe you
> need the symlink from clang++ to clang there to make it work. It should be
> there, no idea why it's not.
>
> arm-linux-gnueabihf-g++ will not be able to compile a simple test program
> because CMake will try to execute it and it won't run (it's ARM).
cmake seems does not honor CC / CXX env. variables. The "hard way" to
specify C/C++ compiler there is via -DCMAKE_C_COMPILER=clang
-DCMAKE_CXX_COMPILER=clang++
Also, I remember that some versions of cmake had bug, where it used
clang as C compiler and something else as C++ compiler. Something like
http://www.cmake.org/Bug/view.php?id=13505
--
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University
More information about the cfe-dev
mailing list