[flang-commits] [flang] 52d31be - [flang] Fix missing generated includes in out of tree build
David Spickett via flang-commits
flang-commits at lists.llvm.org
Wed Oct 19 06:20:31 PDT 2022
Author: David Spickett
Date: 2022-10-19T13:20:25Z
New Revision: 52d31be80eea6d051b7271528e70b852c490e201
URL: https://github.com/llvm/llvm-project/commit/52d31be80eea6d051b7271528e70b852c490e201
DIFF: https://github.com/llvm/llvm-project/commit/52d31be80eea6d051b7271528e70b852c490e201.diff
LOG: [flang] Fix missing generated includes in out of tree build
875fd9df76ded4a88a3a44b690f290ea98f91705 added a new dialect
with some generated files.
When flang is built out of tree (build llvm/clang/mlir first, then
build flang pointing at the first build) those files were not created
at all.
I don't 100% understand why not but juding by the comment at the top
of the file, add_mlir_interface probably expects to run in an MLIR
directory, as add_mlir_dialect does.
So in the same way, I've just inlined enough of that function to
fix the out of tree build.
Reviewed By: jeanPerier
Differential Revision: https://reviews.llvm.org/D136250
Added:
Modified:
flang/include/flang/Optimizer/Dialect/CMakeLists.txt
Removed:
################################################################################
diff --git a/flang/include/flang/Optimizer/Dialect/CMakeLists.txt b/flang/include/flang/Optimizer/Dialect/CMakeLists.txt
index 00d06cd02bde..8f3d47cf6c8c 100644
--- a/flang/include/flang/Optimizer/Dialect/CMakeLists.txt
+++ b/flang/include/flang/Optimizer/Dialect/CMakeLists.txt
@@ -12,9 +12,12 @@ mlir_tablegen(FIROps.h.inc -gen-op-decls)
mlir_tablegen(FIROps.cpp.inc -gen-op-defs)
mlir_tablegen(FIROpsTypes.h.inc --gen-typedef-decls)
mlir_tablegen(FIROpsTypes.cpp.inc --gen-typedef-defs)
-add_mlir_interface(FortranVariableInterface)
add_public_tablegen_target(FIROpsIncGen)
+set(LLVM_TARGET_DEFINITIONS FortranVariableInterface.td)
+mlir_tablegen(FortranVariableInterface.h.inc -gen-op-interface-decls)
+mlir_tablegen(FortranVariableInterface.cpp.inc -gen-op-interface-defs)
+
set(LLVM_TARGET_DEFINITIONS CanonicalizationPatterns.td)
mlir_tablegen(CanonicalizationPatterns.inc -gen-rewriters)
add_public_tablegen_target(CanonicalizationPatternsIncGen)
More information about the flang-commits
mailing list