[cfe-dev] Cross-compile LLVM/Clang bug on macosx

Anton Smirnov dev at antonsmirnov.name
Wed Sep 25 22:21:04 PDT 2013


Hello.

I'm trying to cross-compile clang to run on Android devices (both arm and
x86).
I've read "getting started" <http://llvm.org/docs/GettingStarted.html>
(including
cross-compilation section) and all the websites about clang
cross-compilation that i was able to find.

So i'm pretty sure it's bug.

i've followed all the steps to checkout the sources and started to compile
it according to my aim:

../llvm/configure --prefix=/softdev/clang/arm --host=arm-linux-androideabi
--with-float=hard --with-fpu=neon --enable-optimized --enable-targets=arm

then i'm getting make error:

ld: unknown option:
--version-script=/Users/asmirnov/Documents/dev/src/llvm/autoconf/ExportMap.map
clang: error: linker command failed with exit code 1 (use -v to see
invocation)
make[2]: ***
[/Users/asmirnov/Documents/dev/src/llvm_build/Release+Asserts/bin/FileCheck]
Error 1
make[1]: *** [FileCheck/.makeall] Error 2
make: *** [all] Error 1

the problem is that macosx ld does not support "--version-script" parameter.
this seems to relate to cross-compilation only as compilation for host
system lasts much longer and i believe it's okay.

What can be done?
Thanks in advance and regards, Anton.

PS. It's for free project ArduinoDroid:
https://play.google.com/store/apps/details?id=name.antonsmirnov.android.arduinodroid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130926/ba41602a/attachment.html>


More information about the cfe-dev mailing list