From: Stella Laurenzo Date: Wed, 1 Jan 2020 00:32:41 +0000 (-0800) Subject: Add missing mlir-headers target and add tablegen'd deps to it. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7d82d20f37f0873a07d74c97a081ee6a4c16bdc8;p=platform%2Fupstream%2Fllvm.git Add missing mlir-headers target and add tablegen'd deps to it. Summary: Prior to this, "ninja install-mlir-headers" failed with an error indicating the missing target. Verified that from a clean build, the installed headers include generated files. Subscribers: mgorny, mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D72045 --- diff --git a/mlir/CMakeLists.txt b/mlir/CMakeLists.txt index a81221a..be76e8d 100644 --- a/mlir/CMakeLists.txt +++ b/mlir/CMakeLists.txt @@ -17,6 +17,7 @@ function(add_mlir_dialect dialect dialect_doc_filename) mlir_tablegen(${dialect}.h.inc -gen-op-decls) mlir_tablegen(${dialect}.cpp.inc -gen-op-defs) add_public_tablegen_target(MLIR${dialect}IncGen) + add_dependencies(mlir-headers MLIR${dialect}IncGen) # Generate Dialect Documentation set(LLVM_TARGET_DEFINITIONS ${dialect_doc_filename}.td) @@ -32,6 +33,10 @@ function(add_mlir_dialect dialect dialect_doc_filename) add_dependencies(mlir-doc ${dialect_doc_filename}DocGen) endfunction() +# Installing the headers and docs needs to depend on generating any public +# tablegen'd targets. +add_custom_target(mlir-headers) +set_target_properties(mlir-headers PROPERTIES FOLDER "Misc") add_custom_target(mlir-doc) # TODO: This is to handle the current static registration, but should be