Skip to content

Commit 1445cef

Browse files
authored
Set MLIR_LINK_MLIR_DYLIB to not link shared libMLIR (iree-org#19613)
With llvm/llvm-project@10ef20f, support for `MLIR_LINK_MLIR_DYLIB` was introduced. With `LLVM_LINK_LLVM_DYLIB` set to `ON` at https://github.com/iree-org/iree/blob/cdf24b9be0354f06879ba08db85ff8a5dbe49b14/build_tools/llvm/llvm_config.cmake#L30, this setting is propagated to `MLIR_LINK_MLIR_DYLIB`. This break the BYO LLVM workflow, see iree-org#19549, hence, setting to `OFF`.
1 parent 340ffbb commit 1445cef

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

build_tools/llvm/mlir_config.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ if(NOT EXISTS ${LLVM_DIR})
1919
message(FATAL_ERROR "LLVM_DIR (${LLVM_DIR}) does not exist")
2020
endif()
2121

22+
# TODO: Fixes needed to allow setting to `ON` to allow that
23+
# all the tools will use libMLIR shared library
24+
set(MLIR_LINK_MLIR_DYLIB OFF CACHE BOOL "")
25+
2226
# When exceptions are disabled, unwind tables are large and useless
2327
set(LLVM_ENABLE_UNWIND_TABLES OFF CACHE BOOL "")
2428

0 commit comments

Comments
 (0)