Don't set MLIR_TABLEGEN_EXE (#1197)

With llvm/llvm-project@112499f landed, `MLIR_TABLEGEN_EXE` is given as a
cache variable in the MLIR core project. Other external projects, such
as TORCH-MLIR, should not set the variable as this breaks
cross-compilation.
pull/1199/head
Marius Brehler 2022-08-09 16:06:12 +02:00 committed by GitHub
parent 202076c6e3
commit 747356186f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 4 deletions

View File

@ -100,9 +100,6 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
else()
message(STATUS "Torch-MLIR in-tree build.")
# In-tree build with LLVM_EXTERNAL_PROJECTS=torch-mlir
# FIXME: This should really be inherited from the LLVM tree. In particular,
# it's going to change when cross-compiling.
set(MLIR_TABLEGEN_EXE mlir-tblgen)
if (TORCH_MLIR_ENABLE_MHLO)
set(MLIR_PDLL_TABLEGEN_EXE mlir-pdll)
endif()

View File

@ -30,7 +30,6 @@ else()
# Configure CMake and tablegen.
list(APPEND CMAKE_MODULE_PATH ${MLIR_MAIN_SRC_DIR}/cmake/modules)
list(APPEND CMAKE_MODULE_PATH ${LLVM_MAIN_SRC_DIR}/cmake)
set(MLIR_TABLEGEN_EXE mlir-tblgen)
include(TableGen)
include(AddLLVM)