[clang] c82e4ef - Always -I clang/include when tblgen'ing in Clang.
John McCall via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 16 10:34:07 PST 2019
Author: John McCall
Date: 2019-12-16T13:33:59-05:00
New Revision: c82e4ef6960b9f09fc77abc10f374417007f5f00
URL: https://github.com/llvm/llvm-project/commit/c82e4ef6960b9f09fc77abc10f374417007f5f00
DIFF: https://github.com/llvm/llvm-project/commit/c82e4ef6960b9f09fc77abc10f374417007f5f00.diff
LOG: Always -I clang/include when tblgen'ing in Clang.
Added:
Modified:
clang/cmake/modules/AddClang.cmake
clang/include/clang/AST/CMakeLists.txt
clang/include/clang/AST/TypeProperties.td
Removed:
################################################################################
diff --git a/clang/cmake/modules/AddClang.cmake b/clang/cmake/modules/AddClang.cmake
index 5a1b5cd03b53..577cc11ab015 100644
--- a/clang/cmake/modules/AddClang.cmake
+++ b/clang/cmake/modules/AddClang.cmake
@@ -17,8 +17,9 @@ function(clang_tablegen)
message(FATAL_ERROR "SOURCE source-file required by clang_tablegen")
endif()
+ set( CLANG_TABLEGEN_ARGUMENTS -I ${CLANG_SOURCE_DIR}/include )
set( LLVM_TARGET_DEFINITIONS ${CTG_SOURCE} )
- tablegen(CLANG ${CTG_UNPARSED_ARGUMENTS})
+ tablegen(CLANG ${CTG_UNPARSED_ARGUMENTS} ${CLANG_TABLEGEN_ARGUMENTS})
if(CTG_TARGET)
add_public_tablegen_target(${CTG_TARGET})
diff --git a/clang/include/clang/AST/CMakeLists.txt b/clang/include/clang/AST/CMakeLists.txt
index 292abe451f78..3a6fddb02914 100644
--- a/clang/include/clang/AST/CMakeLists.txt
+++ b/clang/include/clang/AST/CMakeLists.txt
@@ -1,25 +1,20 @@
clang_tablegen(Attrs.inc -gen-clang-attr-classes
- -I ${CMAKE_CURRENT_SOURCE_DIR}/../../
SOURCE ../Basic/Attr.td
TARGET ClangAttrClasses)
clang_tablegen(AttrImpl.inc -gen-clang-attr-impl
- -I ${CMAKE_CURRENT_SOURCE_DIR}/../../
SOURCE ../Basic/Attr.td
TARGET ClangAttrImpl)
clang_tablegen(AttrTextNodeDump.inc -gen-clang-attr-text-node-dump
- -I ${CMAKE_CURRENT_SOURCE_DIR}/../../
SOURCE ../Basic/Attr.td
TARGET ClangAttrTextDump)
clang_tablegen(AttrNodeTraverse.inc -gen-clang-attr-node-traverse
- -I ${CMAKE_CURRENT_SOURCE_DIR}/../../
SOURCE ../Basic/Attr.td
TARGET ClangAttrTraverse)
clang_tablegen(AttrVisitor.inc -gen-clang-attr-ast-visitor
- -I ${CMAKE_CURRENT_SOURCE_DIR}/../../
SOURCE ../Basic/Attr.td
TARGET ClangAttrVisitor)
diff --git a/clang/include/clang/AST/TypeProperties.td b/clang/include/clang/AST/TypeProperties.td
index 76404c8df764..abb605316c95 100644
--- a/clang/include/clang/AST/TypeProperties.td
+++ b/clang/include/clang/AST/TypeProperties.td
@@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
-include "PropertiesBase.td"
-include "../Basic/TypeNodes.td"
+include "clang/AST/PropertiesBase.td"
+include "clang/Basic/TypeNodes.td"
let Class = ComplexType in {
def : Property<"elementType", QualType> {
More information about the cfe-commits
mailing list