[flang-commits] [flang] [flang] [mlir] Avoid clobbering mlir-tblgen target by defining dummy imported targets (PR #150987)
via flang-commits
flang-commits at lists.llvm.org
Tue Aug 19 09:12:59 PDT 2025
Acture wrote:
> > I set `LLVM_TOOLS_BINARY_DIR` to the `bin` directory produced by the tblgen-only build (`${buildLlvmTools.tblgen}/bin`). I also tried pointing it to the `bin` directories from the libllvm package (`${libllvm.out}/bin`) and the full llvm build (`${llvm.out}/bin`), but none of them worked.
>
> mlir-tblgen is in the install of MLIR. Did you make sure you have this binary in one of the path you tried to use?
I’ve just double-checked. In the Nix build setup the situation is a bit different: the tblgen tools are split into a dedicated output, so mlir-tblgen does not appear in the MLIR “install” tree. Concretely:
`
# From the tblgen build (${buildLlvmTools.tblgen}/bin):
$ ls /nix/store/5hynj7y0y5pjdfyfg6hhxi9f5mpxgl6p-mlir-20.1.6/bin/
mlir-linalg-ods-yaml-gen* mlir-pdll-lsp-server* mlir-rewrite* tblgen-lsp-server*
mlir-lsp-server* mlir-query* mlir-runner* update_core_linalg_named_ops.sh*
mlir-opt* mlir-reduce* mlir-translate*
# From the MLIR install output (${mlir.out}/bin)
$ ls /nix/store/pfcxcpmhxc4944dd5pw9kx3fnla9vbzm-llvm-tblgen-20.1.6/bin/
clang-tblgen* llvm-lit* llvm-tblgen* update_core_linalg_named_ops.sh*
clang-tidy-confusable-chars-gen* llvm-min-tblgen* mlir-tblgen*
`
Are there any other expectations that I should satisfy for Flang’s configure step?
https://github.com/llvm/llvm-project/pull/150987
More information about the flang-commits
mailing list