[llvm-dev] Requesting for help.
sumedh jambekar via llvm-dev
llvm-dev at lists.llvm.org
Mon Jul 23 05:04:43 PDT 2018
Hello All,
I need some help with respect to cross compiling for ARM.
While trying to cross compile for the ARM target, I am hitting some errors.
I need some help in this.
I use the following command to cross compile for ARM Cortex A72 (ARM v8-a),
64 bit architecture:
*cmake -v CC='clang' CXX='clang++'
-DCMAKE_C_COMPILER=../build_directory_llvm/bin/clang
-DCMAKE_CXX_COMPILER=../build_directory_llvm/bin/clang++
-DLLVM_TABLEGEN=../build_llvm_directory/bin/llvm-tblgen
-DCLANG_TABLEGEN=../build_llvm_directory/bin/clang-tblgen
-DCROSSCOMPILING=True -DCMAKE_INSTALL_PREFIX=../tmp_two
-DLLVM_DEFAULT_TARGET_TRIPLE=aarch64-linux-gnu -DLLVM_TARGET_ARCH=AARCH64
-DLLVM_TARGETS_TO_BUILD=ARM -DCMAKE_CXX_FLAGS='-target aarch64-linux-gnu
--sysroot=../myOwnToolChainTwo/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/aarch64-linux-gnu/libc
--gcc-toolchain=../myOwnToolChainTwo/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/
-mcpu=cortex-a72' -DLLVM_ENABLE_LIBCXX=ON -DLLVM_ENABLE_PIC=False ../llvm/*
I hit the error stating that "*error: unable to create target: 'No
available targets are compatible with this triple.*'"
I am using ARMv8-a as my target which is 64 bit. Can you please let me know
whether the target triple I am using is correct? Can you also please let me
know whether I am using the right -mcpu option?
Thanks,
Sumedh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20180723/9febeb3e/attachment.html>
More information about the llvm-dev
mailing list