mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-06 12:16:59 +00:00
![Sebastian Pop](/assets/img/avatar_default.png)
This patch allows us to use cmake to specify a cross compiler: target different than host. In particular, it moves LLVM_DEFAULT_TARGET_TRIPLE and TARGET_TRIPLE variables from cmake/config-ix.cmake to the toplevel CMakeLists.txt to make them available at configure time. Here is the command line that I have used to test my patches to create a Hexagon cross compiler hosted on x86: $ cmake -G Ninja -D LLVM_TARGETS_TO_BUILD:STRING=Hexagon -D TARGET_TRIPLE:STRING=hexagon-unknown-linux-gnu -D LLVM_DEFAULT_TARGET_TRIPLE:STRING=hexagon-unknown-linux-gnu -D LLVM_TARGET_ARCH:STRING=hexagon-unknown-linux-gnu .. $ ninja check llvm-svn: 162219
See docs/CMake.html for instructions on how to build LLVM with CMake.