Skip to content
Commit 1dbb7a35 authored by Sebastian Neubauer's avatar Sebastian Neubauer
Browse files

[CMake] Fix cross-compiling with LLVM as CMake subproject

When embedding LLVM as a CMake subproject, using cross-compiling does
not work at the moment. This also affects -DLLVM_OPTIMIZED_TABLEGEN=1,
which uses the same CMake infrastructure.

This patch replaces global CMake variables with the current version,
which allows cross-compilation to work in a subproject.

CMAKE_BINARY_DIR -> CMAKE_CURRENT_BINARY_DIR
CMAKE_SOURCE_DIR -> CMAKE_CURRENT_SOURCE_DIR
CMAKE_PROJECT_NAME -> PROJECT_NAME

Differential Revision: https://reviews.llvm.org/D78913
parent ad2da052
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment