• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1###########################################################
2## TableGen: Compile .td files to .inc.
3###########################################################
4ifeq ($(LOCAL_MODULE_CLASS),)
5    LOCAL_MODULE_CLASS := STATIC_LIBRARIES
6endif
7
8ifneq ($(strip $(TBLGEN_TABLES)),)
9
10intermediates := $(call local-intermediates-dir)
11
12ifneq ($(findstring AttrImpl.inc,$(TBLGEN_TABLES)),)
13LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/AttrImpl.inc
14$(intermediates)/include/clang/AST/AttrImpl.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
15$(intermediates)/include/clang/AST/AttrImpl.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
16	$(call transform-host-clang-td-to-out,clang-attr-impl)
17endif
18
19ifneq ($(findstring AttrList.inc,$(TBLGEN_TABLES)),)
20LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Basic/AttrList.inc
21$(intermediates)/include/clang/Basic/AttrList.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
22$(intermediates)/include/clang/Basic/AttrList.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
23	$(call transform-host-clang-td-to-out,clang-attr-list)
24endif
25
26ifneq ($(findstring AttrSpellings.inc,$(TBLGEN_TABLES)),)
27LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Lex/AttrSpellings.inc
28$(intermediates)/include/clang/Lex/AttrSpellings.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
29$(intermediates)/include/clang/Lex/AttrSpellings.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
30	$(call transform-host-clang-td-to-out,clang-attr-spelling-list)
31endif
32
33ifneq ($(findstring AttrPCHRead.inc,$(TBLGEN_TABLES)),)
34LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Serialization/AttrPCHRead.inc
35$(intermediates)/include/clang/Serialization/AttrPCHRead.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
36$(intermediates)/include/clang/Serialization/AttrPCHRead.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
37	$(call transform-host-clang-td-to-out,clang-attr-pch-read)
38endif
39
40ifneq ($(findstring AttrPCHWrite.inc,$(TBLGEN_TABLES)),)
41LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Serialization/AttrPCHWrite.inc
42$(intermediates)/include/clang/Serialization/AttrPCHWrite.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
43$(intermediates)/include/clang/Serialization/AttrPCHWrite.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
44	$(call transform-host-clang-td-to-out,clang-attr-pch-write)
45endif
46
47ifneq ($(findstring AttrLateParsed.inc,$(TBLGEN_TABLES)),)
48LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Parse/AttrLateParsed.inc
49$(intermediates)/include/clang/Parse/AttrLateParsed.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
50$(intermediates)/include/clang/Parse/AttrLateParsed.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
51	$(call transform-host-clang-td-to-out,clang-attr-late-parsed-list)
52endif
53
54ifneq ($(findstring Attrs.inc,$(TBLGEN_TABLES)),)
55LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/Attrs.inc
56$(intermediates)/include/clang/AST/Attrs.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
57$(intermediates)/include/clang/AST/Attrs.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
58	$(call transform-host-clang-td-to-out,clang-attr-classes)
59endif
60
61ifneq ($(findstring AttrParsedAttrKinds.inc,$(TBLGEN_TABLES)),)
62LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Sema/AttrParsedAttrKinds.inc
63$(intermediates)/include/clang/Sema/AttrParsedAttrKinds.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
64$(intermediates)/include/clang/Sema/AttrParsedAttrKinds.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
65	$(call transform-host-clang-td-to-out,clang-attr-parsed-attr-kinds)
66endif
67
68ifneq ($(findstring AttrParsedAttrList.inc,$(TBLGEN_TABLES)),)
69LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Sema/AttrParsedAttrList.inc
70$(intermediates)/include/clang/Sema/AttrParsedAttrList.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
71$(intermediates)/include/clang/Sema/AttrParsedAttrList.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
72	$(call transform-host-clang-td-to-out,clang-attr-parsed-attr-list)
73endif
74
75ifneq ($(findstring AttrTemplateInstantiate.inc,$(TBLGEN_TABLES)),)
76LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Sema/AttrTemplateInstantiate.inc
77$(intermediates)/include/clang/Sema/AttrTemplateInstantiate.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
78$(intermediates)/include/clang/Sema/AttrTemplateInstantiate.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Attr.td $(CLANG_TBLGEN)
79	$(call transform-host-clang-td-to-out,clang-attr-template-instantiate)
80endif
81
82ifneq ($(findstring Checkers.inc,$(TBLGEN_TABLES)),)
83LOCAL_GENERATED_SOURCES += $(intermediates)/Checkers.inc
84$(intermediates)/Checkers.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
85$(intermediates)/Checkers.inc: \
86  $(CLANG_ROOT_PATH)/lib/StaticAnalyzer/Checkers/Checkers.td \
87  $(CLANG_ROOT_PATH)/include/clang/StaticAnalyzer/Checkers/CheckerBase.td \
88  $(CLANG_TBLGEN)
89	$(call transform-host-clang-td-to-out,clang-sa-checkers)
90endif
91
92ifneq ($(findstring CommentCommandInfo.inc,$(TBLGEN_TABLES)),)
93LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/CommentCommandInfo.inc
94$(intermediates)/include/clang/AST/CommentCommandInfo.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
95$(intermediates)/include/clang/AST/CommentCommandInfo.inc: \
96  $(CLANG_ROOT_PATH)/include/clang/AST/CommentCommands.td \
97  $(CLANG_TBLGEN)
98	$(call transform-host-clang-td-to-out,clang-comment-command-info)
99endif
100
101ifneq ($(findstring CommentHTMLTagsProperties.inc,$(TBLGEN_TABLES)),)
102LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/CommentHTMLTagsProperties.inc
103$(intermediates)/include/clang/AST/CommentHTMLTagsProperties.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
104$(intermediates)/include/clang/AST/CommentHTMLTagsProperties.inc: \
105  $(CLANG_ROOT_PATH)/include/clang/AST/CommentHTMLTags.td \
106  $(CLANG_TBLGEN)
107	$(call transform-host-clang-td-to-out,clang-comment-html-tags-properties)
108endif
109
110ifneq ($(findstring CommentHTMLTags.inc,$(TBLGEN_TABLES)),)
111LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/CommentHTMLTags.inc
112$(intermediates)/include/clang/AST/CommentHTMLTags.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
113$(intermediates)/include/clang/AST/CommentHTMLTags.inc: \
114  $(CLANG_ROOT_PATH)/include/clang/AST/CommentHTMLTags.td \
115  $(CLANG_TBLGEN)
116	$(call transform-host-clang-td-to-out,clang-comment-html-tags)
117endif
118
119ifneq ($(findstring CommentNodes.inc,$(TBLGEN_TABLES)),)
120LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/CommentNodes.inc
121$(intermediates)/include/clang/AST/CommentNodes.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
122$(intermediates)/include/clang/AST/CommentNodes.inc: \
123  $(CLANG_ROOT_PATH)/include/clang/Basic/CommentNodes.td \
124  $(CLANG_TBLGEN)
125	$(call transform-host-clang-td-to-out,clang-comment-nodes)
126endif
127
128ifneq ($(filter Diagnostic%Kinds.inc,$(TBLGEN_TABLES)),)
129LOCAL_GENERATED_SOURCES += $(addprefix $(intermediates)/include/clang/Basic/,$(filter Diagnostic%Kinds.inc,$(TBLGEN_TABLES)))
130$(intermediates)/include/clang/Basic/Diagnostic%Kinds.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
131$(intermediates)/include/clang/Basic/Diagnostic%Kinds.inc: \
132  $(CLANG_ROOT_PATH)/include/clang/Basic/Diagnostic.td \
133  $(CLANG_ROOT_PATH)/include/clang/Basic/Diagnostic%Kinds.td \
134  $(CLANG_TBLGEN)
135	$(call transform-host-clang-td-to-out,clang-diags-defs -clang-component=$(patsubst Diagnostic%Kinds.inc,%,$(@F)))
136endif
137
138ifneq ($(findstring DiagnosticGroups.inc,$(TBLGEN_TABLES)),)
139LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Basic/DiagnosticGroups.inc
140$(intermediates)/include/clang/Basic/DiagnosticGroups.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
141$(intermediates)/include/clang/Basic/DiagnosticGroups.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Diagnostic.td $(CLANG_ROOT_PATH)/include/clang/Basic/DiagnosticGroups.td $(CLANG_TBLGEN)
142	$(call transform-host-clang-td-to-out,clang-diag-groups)
143endif
144
145ifneq ($(findstring DiagnosticIndexName.inc,$(TBLGEN_TABLES)),)
146LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Basic/DiagnosticIndexName.inc
147$(intermediates)/include/clang/Basic/DiagnosticIndexName.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
148$(intermediates)/include/clang/Basic/DiagnosticIndexName.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/Diagnostic.td $(CLANG_TBLGEN)
149	$(call transform-host-clang-td-to-out,clang-diag-groups)
150endif
151
152ifneq ($(findstring DeclNodes.inc,$(TBLGEN_TABLES)),)
153LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/DeclNodes.inc
154$(intermediates)/include/clang/AST/DeclNodes.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
155$(intermediates)/include/clang/AST/DeclNodes.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/DeclNodes.td $(CLANG_TBLGEN)
156	$(call transform-host-clang-td-to-out,clang-decl-nodes)
157endif
158
159ifneq ($(findstring StmtNodes.inc,$(TBLGEN_TABLES)),)
160LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/AST/StmtNodes.inc
161$(intermediates)/include/clang/AST/StmtNodes.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
162$(intermediates)/include/clang/AST/StmtNodes.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/StmtNodes.td $(CLANG_TBLGEN)
163	$(call transform-host-clang-td-to-out,clang-stmt-nodes)
164endif
165
166ifneq ($(findstring arm_neon.inc,$(TBLGEN_TABLES)),)
167LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Basic/arm_neon.inc
168$(intermediates)/include/clang/Basic/arm_neon.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
169$(intermediates)/include/clang/Basic/arm_neon.inc: $(CLANG_ROOT_PATH)/include/clang/Basic/arm_neon.td $(CLANG_TBLGEN)
170	$(call transform-host-clang-td-to-out,arm-neon-sema)
171endif
172
173ifneq ($(findstring Options.inc,$(TBLGEN_TABLES)),)
174LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Driver/Options.inc
175$(intermediates)/include/clang/Driver/Options.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
176$(intermediates)/include/clang/Driver/Options.inc: $(CLANG_ROOT_PATH)/include/clang/Driver/Options.td $(CLANG_ROOT_PATH)/include/clang/Driver/OptParser.td $(CLANG_TBLGEN) $(CLANG_ROOT_PATH)/include/clang/Driver/CC1Options.td
177	$(call transform-host-clang-td-to-out,opt-parser-defs)
178endif
179
180ifneq ($(findstring CC1AsOptions.inc,$(TBLGEN_TABLES)),)
181LOCAL_GENERATED_SOURCES += $(intermediates)/include/clang/Driver/CC1AsOptions.inc
182$(intermediates)/include/clang/Driver/CC1AsOptions.inc: TBLGEN_LOCAL_MODULE := $(LOCAL_MODULE)
183$(intermediates)/include/clang/Driver/CC1AsOptions.inc: $(CLANG_ROOT_PATH)/include/clang/Driver/CC1AsOptions.td $(CLANG_ROOT_PATH)/include/clang/Driver/OptParser.td $(CLANG_TBLGEN)
184	$(call transform-host-clang-td-to-out,opt-parser-defs)
185endif
186
187LOCAL_C_INCLUDES += $(intermediates)/include
188
189endif
190