1## @file
2# This file is used to define class for data type structure
3#
4# Copyright (c) 2011 - 2014, Intel Corporation. All rights reserved.<BR>
5#
6# This program and the accompanying materials are licensed and made available
7# under the terms and conditions of the BSD License which accompanies this
8# distribution. The full text of the license may be found at
9# http://opensource.org/licenses/bsd-license.php
10#
11# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
13
14'''
15DataType
16'''
17
18##
19# Module List Items
20#
21MODULE_LIST = ["BASE",
22               "SEC",
23               "PEI_CORE",
24               "PEIM",
25               "DXE_CORE",
26               "DXE_DRIVER",
27               "SMM_CORE",
28               "DXE_RUNTIME_DRIVER",
29               "DXE_SAL_DRIVER",
30               "DXE_SMM_DRIVER",
31               "UEFI_DRIVER",
32               "UEFI_APPLICATION",
33               "USER_DEFINED"]
34
35VALID_DEPEX_MODULE_TYPE_LIST = ["PEIM",
36                                "DXE_DRIVER",
37                                "DXE_SMM_DRIVER",
38                                "DXE_RUNTIME_DRIVER",
39                                "DXE_SAL_DRIVER",
40                                "UEFI_DRIVER",
41                                ]
42##
43# Usage List Items
44#
45USAGE_LIST = ["CONSUMES",
46              "SOMETIMES_CONSUMES",
47              "PRODUCES",
48              "SOMETIMES_PRODUCES"]
49
50TAB_LANGUAGE_EN_US = 'en-US'
51TAB_LANGUAGE_ENG   = 'eng'
52TAB_LANGUAGE_EN    = 'en'
53TAB_LANGUAGE_EN_X  = 'en-x-tianocore'
54
55USAGE_ITEM_PRODUCES           = 'PRODUCES'
56USAGE_ITEM_SOMETIMES_PRODUCES = 'SOMETIMES_PRODUCES'
57USAGE_ITEM_CONSUMES           = 'CONSUMES'
58USAGE_ITEM_SOMETIMES_CONSUMES = 'SOMETIMES_CONSUMES'
59USAGE_ITEM_TO_START           = 'TO_START'
60USAGE_ITEM_BY_START           = 'BY_START'
61USAGE_ITEM_NOTIFY             = 'NOTIFY'
62USAGE_ITEM_UNDEFINED          = 'UNDEFINED'
63
64USAGE_CONSUMES_LIST = [USAGE_ITEM_CONSUMES,
65                       'CONSUMED',
66                       'ALWAYS_CONSUMED',
67                       'ALWAYS_CONSUMES'
68                       ]
69
70USAGE_PRODUCES_LIST = [USAGE_ITEM_PRODUCES,
71                       'PRODUCED',
72                       'ALWAYS_PRODUCED',
73                       'ALWAYS_PRODUCES'
74                       ]
75
76USAGE_SOMETIMES_PRODUCES_LIST = [USAGE_ITEM_SOMETIMES_PRODUCES,
77                                 'SOMETIMES_PRODUCED'
78                                 ]
79
80USAGE_SOMETIMES_CONSUMES_LIST = [USAGE_ITEM_SOMETIMES_CONSUMES,
81                                 'SOMETIMES_CONSUMED'
82                                 ]
83
84ITEM_UNDEFINED = 'UNDEFINED'
85
86TAB_PCD_VALIDRANGE = '@ValidRange'
87TAB_PCD_VALIDLIST = '@ValidList'
88TAB_PCD_EXPRESSION = '@Expression'
89TAB_PCD_PROMPT = '@Prompt'
90TAB_STR_TOKENCNAME = 'STR'
91TAB_STR_TOKENPROMPT = 'PROMPT'
92TAB_STR_TOKENHELP = 'HELP'
93TAB_STR_TOKENERR = 'ERR'
94
95#
96# Dictionary of usage tokens and their synonmys
97#
98ALL_USAGE_TOKENS = {
99  "PRODUCES"           : "PRODUCES",
100  "PRODUCED"           : "PRODUCES",
101  "ALWAYS_PRODUCES"    : "PRODUCES",
102  "ALWAYS_PRODUCED"    : "PRODUCES",
103  "SOMETIMES_PRODUCES" : "SOMETIMES_PRODUCES",
104  "SOMETIMES_PRODUCED" : "SOMETIMES_PRODUCES",
105  "CONSUMES"           : "CONSUMES",
106  "CONSUMED"           : "CONSUMES",
107  "ALWAYS_CONSUMES"    : "CONSUMES",
108  "ALWAYS_CONSUMED"    : "CONSUMES",
109  "SOMETIMES_CONSUMES" : "SOMETIMES_CONSUMES",
110  "SOMETIMES_CONSUMED" : "SOMETIMES_CONSUMES",
111  "SOMETIME_CONSUMES"  : "SOMETIMES_CONSUMES",
112  "UNDEFINED"          : "UNDEFINED"
113  }
114
115PROTOCOL_USAGE_TOKENS = {
116  "TO_START"           : "TO_START",
117  "BY_START"           : "BY_START"
118  }
119
120PROTOCOL_USAGE_TOKENS.update (ALL_USAGE_TOKENS)
121
122#
123# Dictionary of GUID type tokens
124#
125GUID_TYPE_TOKENS = {
126  "Event"          : "Event",
127  "File"           : "File",
128  "FV"             : "FV",
129  "GUID"           : "GUID",
130  "Guid"           : "GUID",
131  "HII"            : "HII",
132  "HOB"            : "HOB",
133  "Hob"            : "HOB",
134  "Hob:"           : "HOB",
135  "SystemTable"    : "SystemTable",
136  "TokenSpaceGuid" : "TokenSpaceGuid",
137  "UNDEFINED"      : "UNDEFINED"
138  }
139
140#
141# Dictionary of Protocol Notify tokens and their synonyms
142#
143PROTOCOL_NOTIFY_TOKENS = {
144  "NOTIFY"          : "NOTIFY",
145  "PROTOCOL_NOTIFY" : "NOTIFY",
146  "UNDEFINED"       : "UNDEFINED"
147  }
148
149#
150# Dictionary of PPI Notify tokens and their synonyms
151#
152PPI_NOTIFY_TOKENS = {
153  "NOTIFY"     : "NOTIFY",
154  "PPI_NOTIFY" : "NOTIFY",
155  "UNDEFINED"  : "UNDEFINED"
156  }
157
158EVENT_TOKENS = {
159  "EVENT_TYPE_PERIODIC_TIMER" : "EVENT_TYPE_PERIODIC_TIMER",
160  "EVENT_TYPE_RELATIVE_TIMER" : "EVENT_TYPE_RELATIVE_TIMER",
161  "UNDEFINED"                 : "UNDEFINED"
162  }
163
164BOOTMODE_TOKENS = {
165  "FULL"                  : "FULL",
166  "MINIMAL"               : "MINIMAL",
167  "NO_CHANGE"             : "NO_CHANGE",
168  "DIAGNOSTICS"           : "DIAGNOSTICS",
169  "DEFAULT"               : "DEFAULT",
170  "S2_RESUME"             : "S2_RESUME",
171  "S3_RESUME"             : "S3_RESUME",
172  "S4_RESUME"             : "S4_RESUME",
173  "S5_RESUME"             : "S5_RESUME",
174  "FLASH_UPDATE"          : "FLASH_UPDATE",
175  "RECOVERY_FULL"         : "RECOVERY_FULL",
176  "RECOVERY_MINIMAL"      : "RECOVERY_MINIMAL",
177  "RECOVERY_NO_CHANGE"    : "RECOVERY_NO_CHANGE",
178  "RECOVERY_DIAGNOSTICS"  : "RECOVERY_DIAGNOSTICS",
179  "RECOVERY_DEFAULT"      : "RECOVERY_DEFAULT",
180  "RECOVERY_S2_RESUME"    : "RECOVERY_S2_RESUME",
181  "RECOVERY_S3_RESUME"    : "RECOVERY_S3_RESUME",
182  "RECOVERY_S4_RESUME"    : "RECOVERY_S4_RESUME",
183  "RECOVERY_S5_RESUME"    : "RECOVERY_S5_RESUME",
184  "RECOVERY_FLASH_UPDATE" : "RECOVERY_FLASH_UPDATE",
185  "UNDEFINED"             : "UNDEFINED"
186  }
187
188HOB_TOKENS = {
189  "PHIT"                : "PHIT",
190  "MEMORY_ALLOCATION"   : "MEMORY_ALLOCATION",
191  "LOAD_PEIM"           : "LOAD_PEIM",
192  "RESOURCE_DESCRIPTOR" : "RESOURCE_DESCRIPTOR",
193  "FIRMWARE_VOLUME"     : "FIRMWARE_VOLUME",
194  "UNDEFINED"           : "UNDEFINED"
195  }
196
197##
198# Usage List Items for Protocol
199#
200PROTOCOL_USAGE_LIST = USAGE_LIST + ["TO_START", "BY_START"]
201
202##
203# End of Line
204# Use this but not os.linesep for os.linesep has bug in it.
205#
206END_OF_LINE = '\n'
207
208##
209# Arch List Items
210#
211ARCH_LIST = ["IA32",
212             "X64",
213             "IPF",
214             "EBC",
215             "COMMON"]
216##
217# PCD driver type list items
218#
219PCD_DIRVER_TYPE_LIST = ["PEI_PCD_DRIVER", "DXE_PCD_DRIVER"]
220
221##
222# Boot Mode List Items
223#
224BOOT_MODE_LIST = ["FULL",
225                  "MINIMAL",
226                  "NO_CHANGE",
227                  "DIAGNOSTICS",
228                  "DEFAULT",
229                  "S2_RESUME",
230                  "S3_RESUME",
231                  "S4_RESUME",
232                  "S5_RESUME",
233                  "FLASH_UPDATE",
234                  "RECOVERY_FULL",
235                  "RECOVERY_MINIMAL",
236                  "RECOVERY_NO_CHANGE",
237                  "RECOVERY_DIAGNOSTICS",
238                  "RECOVERY_DEFAULT",
239                  "RECOVERY_S2_RESUME",
240                  "RECOVERY_S3_RESUME",
241                  "RECOVERY_S4_RESUME",
242                  "RECOVERY_S5_RESUME",
243                  "RECOVERY_FLASH_UPDATE"]
244
245##
246# Event Type List Items
247#
248EVENT_TYPE_LIST = ["EVENT_TYPE_PERIODIC_TIMER",
249                   "EVENT_TYPE_RELATIVE_TIMER"]
250
251##
252# Hob Type List Items
253#
254HOB_TYPE_LIST = ["PHIT",
255                 "MEMORY_ALLOCATION",
256                 "RESOURCE_DESCRIPTOR",
257                 "FIRMWARE_VOLUME",
258                 "LOAD_PEIM"]
259
260##
261# GUID_TYPE_LIST
262#
263GUID_TYPE_LIST = ["Event", "File", "FV", "GUID", "HII", "HOB",
264                  "SystemTable", "TokenSpaceGuid", "Variable"]
265##
266# PCD Usage Type List of Package
267#
268PCD_USAGE_TYPE_LIST_OF_PACKAGE = ["FeatureFlag", "PatchableInModule",
269                             "FixedAtBuild", "Dynamic", "DynamicEx"]
270
271##
272# PCD Usage Type List of Module
273#
274PCD_USAGE_TYPE_LIST_OF_MODULE = ["FEATUREPCD", "PATCHPCD", "FIXEDPCD", "PCD", "PCDEX"]
275##
276# PCD Usage Type List of UPT
277#
278PCD_USAGE_TYPE_LIST_OF_UPT = PCD_USAGE_TYPE_LIST_OF_MODULE
279
280##
281# Binary File Type List
282#
283BINARY_FILE_TYPE_LIST = ["PE32", "PIC", "TE", "DXE_DEPEX", "VER", "UI", "COMPAT16", "FV", "BIN", "RAW",
284                         "ACPI", "ASL",
285                         "PEI_DEPEX",
286                         "SMM_DEPEX",
287                         "SUBTYPE_GUID",
288                         "DISPOSABLE"
289                         ]
290BINARY_FILE_TYPE_LIST_IN_UDP = \
291                        ["GUID", "FREEFORM",
292                         "UEFI_IMAGE", "PE32", "PIC",
293                         "PEI_DEPEX",
294                         "DXE_DEPEX",
295                         "SMM_DEPEX",
296                         "FV", "TE",
297                         "BIN", "VER", "UI"
298                         ]
299
300SUBTYPE_GUID_BINARY_FILE_TYPE = "FREEFORM"
301##
302# Possible values for COMPONENT_TYPE, and their descriptions, are listed in
303# the table,
304# "Component (module) Types." For each component, the BASE_NAME and
305# COMPONENT_TYPE
306# are required. The COMPONENT_TYPE definition is case sensitive.
307#
308COMPONENT_TYPE_LIST = [
309                       "APPLICATION",
310                       "ACPITABLE",
311                       "APRIORI",
312                       "BINARY",
313                       "BS_DRIVER",
314                       "CONFIG",
315                       "FILE",
316                       "FVIMAGEFILE",
317                       "LIBRARY",
318                       "LOGO",
319                       "LEGACY16",
320                       "MICROCODE",
321                       "PE32_PEIM",
322                       "PEI_CORE",
323                       "RAWFILE",
324                       "RT_DRIVER",
325                       "SAL_RT_DRIVER",
326                       "SECURITY_CORE",
327                       "COMBINED_PEIM_DRIVER",
328                       "PIC_PEIM",
329                       "RELOCATABLE_PEIM"
330                       ]
331
332##
333# Common Definitions
334#
335TAB_SPLIT = '.'
336TAB_COMMENT_EDK1_START = '/*'
337TAB_COMMENT_EDK1_END = '*/'
338TAB_COMMENT_EDK1_SPLIT = '//'
339TAB_COMMENT_SPLIT = '#'
340TAB_EQUAL_SPLIT = '='
341TAB_DEQUAL_SPLIT = '=='
342TAB_VALUE_SPLIT = '|'
343TAB_COMMA_SPLIT = ','
344TAB_HORIZON_LINE_SPLIT = '-'
345TAB_SPACE_SPLIT = ' '
346TAB_UNDERLINE_SPLIT = '_'
347TAB_SEMI_COLON_SPLIT = ';'
348TAB_COLON_SPLIT = ':'
349TAB_SECTION_START = '['
350TAB_SECTION_END = ']'
351TAB_OPTION_START = '<'
352TAB_OPTION_END  = '>'
353TAB_SLASH = '\\'
354TAB_BACK_SLASH = '/'
355TAB_SPECIAL_COMMENT = '##'
356TAB_HEADER_COMMENT = '@file'
357TAB_BINARY_HEADER_COMMENT = '@BinaryHeader'
358TAB_STAR = '*'
359TAB_ENCODING_UTF16LE = 'utf_16_le'
360TAB_CAPHEX_START = '0X'
361TAB_HEX_START = '0x'
362TAB_PCD_ERROR = 'Error'
363TAB_PCD_ERROR_SECTION_COMMENT = 'Error message section'
364TAB_UNI_FILE_SUFFIXS = ['.uni', '.UNI', '.Uni']
365
366TAB_EDK_SOURCE = '$(EDK_SOURCE)'
367TAB_EFI_SOURCE = '$(EFI_SOURCE)'
368TAB_WORKSPACE = '$(WORKSPACE)'
369
370TAB_ARCH_NULL = ''
371TAB_ARCH_COMMON = 'COMMON'
372TAB_ARCH_IA32 = 'IA32'
373TAB_ARCH_X64 = 'X64'
374TAB_ARCH_IPF = 'IPF'
375TAB_ARCH_ARM = 'ARM'
376TAB_ARCH_EBC = 'EBC'
377
378ARCH_LIST = \
379[TAB_ARCH_IA32, TAB_ARCH_X64, TAB_ARCH_IPF, TAB_ARCH_ARM, TAB_ARCH_EBC]
380
381SUP_MODULE_BASE = 'BASE'
382SUP_MODULE_SEC = 'SEC'
383SUP_MODULE_PEI_CORE = 'PEI_CORE'
384SUP_MODULE_PEIM = 'PEIM'
385SUP_MODULE_DXE_CORE = 'DXE_CORE'
386SUP_MODULE_DXE_DRIVER = 'DXE_DRIVER'
387SUP_MODULE_DXE_RUNTIME_DRIVER = 'DXE_RUNTIME_DRIVER'
388SUP_MODULE_DXE_SAL_DRIVER = 'DXE_SAL_DRIVER'
389SUP_MODULE_DXE_SMM_DRIVER = 'DXE_SMM_DRIVER'
390SUP_MODULE_UEFI_DRIVER = 'UEFI_DRIVER'
391SUP_MODULE_UEFI_APPLICATION = 'UEFI_APPLICATION'
392SUP_MODULE_USER_DEFINED = 'USER_DEFINED'
393SUP_MODULE_SMM_CORE = 'SMM_CORE'
394
395SUP_MODULE_LIST = \
396[SUP_MODULE_BASE, SUP_MODULE_SEC, SUP_MODULE_PEI_CORE, SUP_MODULE_PEIM, \
397SUP_MODULE_DXE_CORE, SUP_MODULE_DXE_DRIVER, \
398                   SUP_MODULE_DXE_RUNTIME_DRIVER, SUP_MODULE_DXE_SAL_DRIVER, \
399                   SUP_MODULE_DXE_SMM_DRIVER, SUP_MODULE_UEFI_DRIVER, \
400                   SUP_MODULE_UEFI_APPLICATION, SUP_MODULE_USER_DEFINED, \
401                   SUP_MODULE_SMM_CORE]
402SUP_MODULE_LIST_STRING = TAB_VALUE_SPLIT.join(l for l in SUP_MODULE_LIST)
403
404EDK_COMPONENT_TYPE_LIBRARY = 'LIBRARY'
405EDK_COMPONENT_TYPE_SECUARITY_CORE = 'SECUARITY_CORE'
406EDK_COMPONENT_TYPE_PEI_CORE = 'PEI_CORE'
407EDK_COMPONENT_TYPE_COMBINED_PEIM_DRIVER = 'COMBINED_PEIM_DRIVER'
408EDK_COMPONENT_TYPE_PIC_PEIM = 'PIC_PEIM'
409EDK_COMPONENT_TYPE_RELOCATABLE_PEIM = 'RELOCATABLE_PEIM'
410EDK_COMPONENT_TYPE_BS_DRIVER = 'BS_DRIVER'
411EDK_COMPONENT_TYPE_RT_DRIVER = 'RT_DRIVER'
412EDK_COMPONENT_TYPE_SAL_RT_DRIVER = 'SAL_RT_DRIVER'
413EDK_COMPONENT_TYPE_APPLICATION = 'APPLICATION'
414EDK_NAME   = 'EDK'
415EDKII_NAME = 'EDKII'
416
417BINARY_FILE_TYPE_FW = 'FW'
418BINARY_FILE_TYPE_GUID = 'GUID'
419BINARY_FILE_TYPE_PREEFORM = 'PREEFORM'
420BINARY_FILE_TYPE_UEFI_APP = 'UEFI_APP'
421BINARY_FILE_TYPE_UNI_UI = 'UNI_UI'
422BINARY_FILE_TYPE_SEC_UI = 'SEC_UI'
423BINARY_FILE_TYPE_UNI_VER = 'UNI_VER'
424BINARY_FILE_TYPE_SEC_VER = 'SEC_VER'
425BINARY_FILE_TYPE_LIB = 'LIB'
426BINARY_FILE_TYPE_PE32 = 'PE32'
427BINARY_FILE_TYPE_PIC = 'PIC'
428BINARY_FILE_TYPE_PEI_DEPEX = 'PEI_DEPEX'
429BINARY_FILE_TYPE_DXE_DEPEX = 'DXE_DEPEX'
430BINARY_FILE_TYPE_SMM_DEPEX = 'SMM_DEPEX'
431BINARY_FILE_TYPE_TE = 'TE'
432BINARY_FILE_TYPE_VER = 'VER'
433BINARY_FILE_TYPE_UI = 'UI'
434BINARY_FILE_TYPE_BIN = 'BIN'
435BINARY_FILE_TYPE_FV = 'FV'
436BINARY_FILE_TYPE_UI_LIST = [BINARY_FILE_TYPE_UNI_UI,
437                            BINARY_FILE_TYPE_SEC_UI,
438                            BINARY_FILE_TYPE_UI
439                            ]
440BINARY_FILE_TYPE_VER_LIST = [BINARY_FILE_TYPE_UNI_VER,
441                            BINARY_FILE_TYPE_SEC_VER,
442                            BINARY_FILE_TYPE_VER
443                            ]
444
445DEPEX_SECTION_LIST = ['<PEI_DEPEX>',
446                      '<DXE_DEPEX>',
447                      '<SMM_DEPEX>'
448                      ]
449
450PLATFORM_COMPONENT_TYPE_LIBRARY = 'LIBRARY'
451PLATFORM_COMPONENT_TYPE_LIBRARY_CLASS = 'LIBRARY_CLASS'
452PLATFORM_COMPONENT_TYPE_MODULE = 'MODULE'
453
454TAB_LIBRARIES = 'Libraries'
455
456TAB_SOURCE = 'Source'
457TAB_SOURCES = 'Sources'
458TAB_SOURCES_COMMON = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_COMMON
459TAB_SOURCES_IA32 = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_IA32
460TAB_SOURCES_X64 = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_X64
461TAB_SOURCES_IPF = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_IPF
462TAB_SOURCES_ARM = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_ARM
463TAB_SOURCES_EBC = TAB_SOURCES + TAB_SPLIT + TAB_ARCH_EBC
464
465TAB_BINARIES = 'Binaries'
466TAB_BINARIES_COMMON = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_COMMON
467TAB_BINARIES_IA32 = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_IA32
468TAB_BINARIES_X64 = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_X64
469TAB_BINARIES_IPF = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_IPF
470TAB_BINARIES_ARM = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_ARM
471TAB_BINARIES_EBC = TAB_BINARIES + TAB_SPLIT + TAB_ARCH_EBC
472
473TAB_INCLUDES = 'Includes'
474TAB_INCLUDES_COMMON = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_COMMON
475TAB_INCLUDES_IA32 = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_IA32
476TAB_INCLUDES_X64 = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_X64
477TAB_INCLUDES_IPF = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_IPF
478TAB_INCLUDES_ARM = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_ARM
479TAB_INCLUDES_EBC = TAB_INCLUDES + TAB_SPLIT + TAB_ARCH_EBC
480
481TAB_GUIDS = 'Guids'
482TAB_GUIDS_COMMON = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_COMMON
483TAB_GUIDS_IA32 = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_IA32
484TAB_GUIDS_X64 = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_X64
485TAB_GUIDS_IPF = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_IPF
486TAB_GUIDS_ARM = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_ARM
487TAB_GUIDS_EBC = TAB_GUIDS + TAB_SPLIT + TAB_ARCH_EBC
488
489TAB_PROTOCOLS = 'Protocols'
490TAB_PROTOCOLS_COMMON = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_COMMON
491TAB_PROTOCOLS_IA32 = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_IA32
492TAB_PROTOCOLS_X64 = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_X64
493TAB_PROTOCOLS_IPF = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_IPF
494TAB_PROTOCOLS_ARM = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_ARM
495TAB_PROTOCOLS_EBC = TAB_PROTOCOLS + TAB_SPLIT + TAB_ARCH_EBC
496
497TAB_PPIS = 'Ppis'
498TAB_PPIS_COMMON = TAB_PPIS + TAB_SPLIT + TAB_ARCH_COMMON
499TAB_PPIS_IA32 = TAB_PPIS + TAB_SPLIT + TAB_ARCH_IA32
500TAB_PPIS_X64 = TAB_PPIS + TAB_SPLIT + TAB_ARCH_X64
501TAB_PPIS_IPF = TAB_PPIS + TAB_SPLIT + TAB_ARCH_IPF
502TAB_PPIS_ARM = TAB_PPIS + TAB_SPLIT + TAB_ARCH_ARM
503TAB_PPIS_EBC = TAB_PPIS + TAB_SPLIT + TAB_ARCH_EBC
504
505TAB_LIBRARY_CLASSES = 'LibraryClasses'
506TAB_LIBRARY_CLASSES_COMMON = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_COMMON
507TAB_LIBRARY_CLASSES_IA32 = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_IA32
508TAB_LIBRARY_CLASSES_X64 = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_X64
509TAB_LIBRARY_CLASSES_IPF = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_IPF
510TAB_LIBRARY_CLASSES_ARM = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_ARM
511TAB_LIBRARY_CLASSES_EBC = TAB_LIBRARY_CLASSES + TAB_SPLIT + TAB_ARCH_EBC
512
513TAB_PACKAGES = 'Packages'
514TAB_PACKAGES_COMMON = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_COMMON
515TAB_PACKAGES_IA32 = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_IA32
516TAB_PACKAGES_X64 = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_X64
517TAB_PACKAGES_IPF = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_IPF
518TAB_PACKAGES_ARM = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_ARM
519TAB_PACKAGES_EBC = TAB_PACKAGES + TAB_SPLIT + TAB_ARCH_EBC
520
521TAB_PCDS = 'Pcds'
522TAB_PCDS_FIXED_AT_BUILD = 'FixedAtBuild'
523TAB_PCDS_PATCHABLE_IN_MODULE = 'PatchableInModule'
524TAB_PCDS_FEATURE_FLAG = 'FeatureFlag'
525TAB_PCDS_DYNAMIC_EX = 'DynamicEx'
526TAB_PCDS_DYNAMIC_EX_DEFAULT = 'DynamicExDefault'
527TAB_PCDS_DYNAMIC_EX_VPD = 'DynamicExVpd'
528TAB_PCDS_DYNAMIC_EX_HII = 'DynamicExHii'
529TAB_PCDS_DYNAMIC = 'Dynamic'
530TAB_PCDS_DYNAMIC_DEFAULT = 'DynamicDefault'
531TAB_PCDS_DYNAMIC_VPD = 'DynamicVpd'
532TAB_PCDS_DYNAMIC_HII = 'DynamicHii'
533
534TAB_PTR_TYPE_PCD = 'VOID*'
535
536PCD_DYNAMIC_TYPE_LIST = [TAB_PCDS_DYNAMIC, TAB_PCDS_DYNAMIC_DEFAULT, \
537                         TAB_PCDS_DYNAMIC_VPD, TAB_PCDS_DYNAMIC_HII]
538PCD_DYNAMIC_EX_TYPE_LIST = [TAB_PCDS_DYNAMIC_EX, TAB_PCDS_DYNAMIC_EX_DEFAULT, \
539                            TAB_PCDS_DYNAMIC_EX_VPD, TAB_PCDS_DYNAMIC_EX_HII]
540
541## Dynamic-ex PCD types
542#
543gDYNAMIC_EX_PCD = [TAB_PCDS_DYNAMIC_EX, TAB_PCDS_DYNAMIC_EX_DEFAULT, \
544                 TAB_PCDS_DYNAMIC_EX_VPD, TAB_PCDS_DYNAMIC_EX_HII]
545
546TAB_PCDS_FIXED_AT_BUILD_NULL = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD
547TAB_PCDS_FIXED_AT_BUILD_COMMON = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
548TAB_SPLIT + TAB_ARCH_COMMON
549TAB_PCDS_FIXED_AT_BUILD_IA32 = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
550TAB_SPLIT + TAB_ARCH_IA32
551TAB_PCDS_FIXED_AT_BUILD_X64 = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
552TAB_SPLIT + TAB_ARCH_X64
553TAB_PCDS_FIXED_AT_BUILD_IPF = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
554TAB_SPLIT + TAB_ARCH_IPF
555TAB_PCDS_FIXED_AT_BUILD_ARM = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
556TAB_SPLIT + TAB_ARCH_ARM
557TAB_PCDS_FIXED_AT_BUILD_EBC = TAB_PCDS + TAB_PCDS_FIXED_AT_BUILD + \
558TAB_SPLIT + TAB_ARCH_EBC
559
560TAB_PCDS_PATCHABLE_IN_MODULE_NULL = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE
561TAB_PCDS_PATCHABLE_IN_MODULE_COMMON = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE \
562+ TAB_SPLIT + TAB_ARCH_COMMON
563TAB_PCDS_PATCHABLE_IN_MODULE_IA32 = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE + \
564TAB_SPLIT + TAB_ARCH_IA32
565TAB_PCDS_PATCHABLE_IN_MODULE_X64 = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE + \
566TAB_SPLIT + TAB_ARCH_X64
567TAB_PCDS_PATCHABLE_IN_MODULE_IPF = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE + \
568TAB_SPLIT + TAB_ARCH_IPF
569TAB_PCDS_PATCHABLE_IN_MODULE_ARM = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE + \
570TAB_SPLIT + TAB_ARCH_ARM
571TAB_PCDS_PATCHABLE_IN_MODULE_EBC = TAB_PCDS + TAB_PCDS_PATCHABLE_IN_MODULE + \
572TAB_SPLIT + TAB_ARCH_EBC
573
574TAB_PCDS_FEATURE_FLAG_NULL = TAB_PCDS + TAB_PCDS_FEATURE_FLAG
575TAB_PCDS_FEATURE_FLAG_COMMON = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT \
576+ TAB_ARCH_COMMON
577TAB_PCDS_FEATURE_FLAG_IA32 = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT + \
578TAB_ARCH_IA32
579TAB_PCDS_FEATURE_FLAG_X64 = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT + \
580TAB_ARCH_X64
581TAB_PCDS_FEATURE_FLAG_IPF = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT + \
582TAB_ARCH_IPF
583TAB_PCDS_FEATURE_FLAG_ARM = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT + \
584TAB_ARCH_ARM
585TAB_PCDS_FEATURE_FLAG_EBC = TAB_PCDS + TAB_PCDS_FEATURE_FLAG + TAB_SPLIT + \
586TAB_ARCH_EBC
587
588TAB_PCDS_DYNAMIC_EX_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_EX
589TAB_PCDS_DYNAMIC_EX_DEFAULT_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_EX_DEFAULT
590TAB_PCDS_DYNAMIC_EX_HII_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_EX_HII
591TAB_PCDS_DYNAMIC_EX_VPD_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_EX_VPD
592TAB_PCDS_DYNAMIC_EX_COMMON = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
593TAB_ARCH_COMMON
594TAB_PCDS_DYNAMIC_EX_IA32 = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
595TAB_ARCH_IA32
596TAB_PCDS_DYNAMIC_EX_X64 = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
597TAB_ARCH_X64
598TAB_PCDS_DYNAMIC_EX_IPF = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
599TAB_ARCH_IPF
600TAB_PCDS_DYNAMIC_EX_ARM = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
601TAB_ARCH_ARM
602TAB_PCDS_DYNAMIC_EX_EBC = TAB_PCDS + TAB_PCDS_DYNAMIC_EX + TAB_SPLIT + \
603TAB_ARCH_EBC
604
605TAB_PCDS_DYNAMIC_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC
606TAB_PCDS_DYNAMIC_DEFAULT_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_DEFAULT
607TAB_PCDS_DYNAMIC_HII_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_HII
608TAB_PCDS_DYNAMIC_VPD_NULL = TAB_PCDS + TAB_PCDS_DYNAMIC_VPD
609TAB_PCDS_DYNAMIC_COMMON = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + \
610TAB_ARCH_COMMON
611TAB_PCDS_DYNAMIC_IA32 = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + TAB_ARCH_IA32
612TAB_PCDS_DYNAMIC_X64 = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + TAB_ARCH_X64
613TAB_PCDS_DYNAMIC_IPF = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + TAB_ARCH_IPF
614TAB_PCDS_DYNAMIC_ARM = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + TAB_ARCH_ARM
615TAB_PCDS_DYNAMIC_EBC = TAB_PCDS + TAB_PCDS_DYNAMIC + TAB_SPLIT + TAB_ARCH_EBC
616
617TAB_PCD_DYNAMIC_TYPE_LIST = [TAB_PCDS_DYNAMIC_DEFAULT_NULL, \
618                             TAB_PCDS_DYNAMIC_VPD_NULL, \
619                             TAB_PCDS_DYNAMIC_HII_NULL]
620TAB_PCD_DYNAMIC_EX_TYPE_LIST = [TAB_PCDS_DYNAMIC_EX_DEFAULT_NULL, \
621                                TAB_PCDS_DYNAMIC_EX_VPD_NULL, \
622                                TAB_PCDS_DYNAMIC_EX_HII_NULL]
623
624TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_PEI_PAGE_SIZE = \
625'PcdLoadFixAddressPeiCodePageNumber'
626TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_PEI_PAGE_SIZE_DATA_TYPE = 'UINT32'
627TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_DXE_PAGE_SIZE = \
628'PcdLoadFixAddressBootTimeCodePageNumber'
629TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_DXE_PAGE_SIZE_DATA_TYPE = 'UINT32'
630TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_RUNTIME_PAGE_SIZE = \
631'PcdLoadFixAddressRuntimeCodePageNumber'
632TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_RUNTIME_PAGE_SIZE_DATA_TYPE = 'UINT32'
633TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_SMM_PAGE_SIZE = \
634'PcdLoadFixAddressSmmCodePageNumber'
635TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_SMM_PAGE_SIZE_DATA_TYPE = 'UINT32'
636TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_LIST = \
637[TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_PEI_PAGE_SIZE, \
638TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_DXE_PAGE_SIZE, \
639TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_RUNTIME_PAGE_SIZE, \
640TAB_PCDS_PATCHABLE_LOAD_FIX_ADDRESS_SMM_PAGE_SIZE]
641PCD_SECTION_LIST = [TAB_PCDS_FIXED_AT_BUILD_NULL.upper(), \
642                    TAB_PCDS_PATCHABLE_IN_MODULE_NULL.upper(), \
643                    TAB_PCDS_FEATURE_FLAG_NULL.upper(), \
644                    TAB_PCDS_DYNAMIC_EX_NULL.upper(), \
645                    TAB_PCDS_DYNAMIC_NULL.upper()]
646INF_PCD_SECTION_LIST = ["FixedPcd".upper(), "FeaturePcd".upper(), \
647                        "PatchPcd".upper(), "Pcd".upper(), "PcdEx".upper()]
648
649TAB_DEPEX = 'Depex'
650TAB_DEPEX_COMMON = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_COMMON
651TAB_DEPEX_IA32 = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_IA32
652TAB_DEPEX_X64 = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_X64
653TAB_DEPEX_IPF = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_IPF
654TAB_DEPEX_ARM = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_ARM
655TAB_DEPEX_EBC = TAB_DEPEX + TAB_SPLIT + TAB_ARCH_EBC
656
657TAB_SKUIDS = 'SkuIds'
658
659TAB_LIBRARIES = 'Libraries'
660TAB_LIBRARIES_COMMON = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_COMMON
661TAB_LIBRARIES_IA32 = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_IA32
662TAB_LIBRARIES_X64 = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_X64
663TAB_LIBRARIES_IPF = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_IPF
664TAB_LIBRARIES_ARM = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_ARM
665TAB_LIBRARIES_EBC = TAB_LIBRARIES + TAB_SPLIT + TAB_ARCH_EBC
666
667TAB_COMPONENTS = 'Components'
668TAB_COMPONENTS_COMMON = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_COMMON
669TAB_COMPONENTS_IA32 = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_IA32
670TAB_COMPONENTS_X64 = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_X64
671TAB_COMPONENTS_IPF = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_IPF
672TAB_COMPONENTS_ARM = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_ARM
673TAB_COMPONENTS_EBC = TAB_COMPONENTS + TAB_SPLIT + TAB_ARCH_EBC
674
675TAB_COMPONENTS_SOURCE_OVERRIDE_PATH = 'SOURCE_OVERRIDE_PATH'
676
677TAB_BUILD_OPTIONS = 'BuildOptions'
678
679TAB_DEFINE = 'DEFINE'
680TAB_NMAKE = 'Nmake'
681TAB_USER_EXTENSIONS = 'UserExtensions'
682TAB_INCLUDE = '!include'
683
684#
685# Common Define
686#
687TAB_COMMON_DEFINES = 'Defines'
688
689#
690# Inf Definitions
691#
692TAB_INF_DEFINES = TAB_COMMON_DEFINES
693TAB_INF_DEFINES_INF_VERSION = 'INF_VERSION'
694TAB_INF_DEFINES_BASE_NAME = 'BASE_NAME'
695TAB_INF_DEFINES_FILE_GUID = 'FILE_GUID'
696TAB_INF_DEFINES_MODULE_TYPE = 'MODULE_TYPE'
697TAB_INF_DEFINES_EFI_SPECIFICATION_VERSION = 'EFI_SPECIFICATION_VERSION'
698TAB_INF_DEFINES_UEFI_SPECIFICATION_VERSION = 'UEFI_SPECIFICATION_VERSION'
699TAB_INF_DEFINES_PI_SPECIFICATION_VERSION = 'PI_SPECIFICATION_VERSION'
700TAB_INF_DEFINES_EDK_RELEASE_VERSION = 'EDK_RELEASE_VERSION'
701TAB_INF_DEFINES_MODULE_UNI_FILE    = 'MODULE_UNI_FILE'
702TAB_INF_DEFINES_BINARY_MODULE = 'BINARY_MODULE'
703TAB_INF_DEFINES_LIBRARY_CLASS = 'LIBRARY_CLASS'
704TAB_INF_DEFINES_COMPONENT_TYPE = 'COMPONENT_TYPE'
705TAB_INF_DEFINES_MAKEFILE_NAME = 'MAKEFILE_NAME'
706TAB_INF_DEFINES_BUILD_NUMBER = 'BUILD_NUMBER'
707TAB_INF_DEFINES_BUILD_TYPE = 'BUILD_TYPE'
708TAB_INF_DEFINES_FFS_EXT = 'FFS_EXT'
709TAB_INF_DEFINES_FV_EXT = 'FV_EXT'
710TAB_INF_DEFINES_SOURCE_FV = 'SOURCE_FV'
711TAB_INF_DEFINES_PACKAGE   = 'PACKAGE'
712TAB_INF_DEFINES_VERSION_NUMBER = 'VERSION_NUMBER'
713TAB_INF_DEFINES_VERSION = 'VERSION'
714TAB_INF_DEFINES_VERSION_STRING = 'VERSION_STRING'
715TAB_INF_DEFINES_PCD_IS_DRIVER = 'PCD_IS_DRIVER'
716TAB_INF_DEFINES_TIANO_EDK1_FLASHMAP_H = 'TIANO_EDK1_FLASHMAP_H'
717TAB_INF_DEFINES_ENTRY_POINT = 'ENTRY_POINT'
718TAB_INF_DEFINES_UNLOAD_IMAGE = 'UNLOAD_IMAGE'
719TAB_INF_DEFINES_CONSTRUCTOR = 'CONSTRUCTOR'
720TAB_INF_DEFINES_DESTRUCTOR = 'DESTRUCTOR'
721TAB_INF_DEFINES_PCI_VENDOR_ID  = 'PCI_VENDOR_ID'
722TAB_INF_DEFINES_PCI_DEVICE_ID  = 'PCI_DEVICE_ID'
723TAB_INF_DEFINES_PCI_CLASS_CODE = 'PCI_CLASS_CODE'
724TAB_INF_DEFINES_PCI_REVISION   = 'PCI_REVISION'
725TAB_INF_DEFINES_PCI_COMPRESS   = 'PCI_COMPRESS'
726TAB_INF_DEFINES_DEFINE = 'DEFINE'
727TAB_INF_DEFINES_SPEC = 'SPEC'
728TAB_INF_DEFINES_UEFI_HII_RESOURCE_SECTION = 'UEFI_HII_RESOURCE_SECTION'
729TAB_INF_DEFINES_CUSTOM_MAKEFILE = 'CUSTOM_MAKEFILE'
730TAB_INF_DEFINES_MACRO = '__MACROS__'
731TAB_INF_DEFINES_SHADOW = 'SHADOW'
732TAB_INF_DEFINES_DPX_SOURCE = 'DPX_SOURCE'
733TAB_INF_FIXED_PCD = 'FixedPcd'
734TAB_INF_FEATURE_PCD = 'FeaturePcd'
735TAB_INF_PATCH_PCD = 'PatchPcd'
736TAB_INF_PCD = 'Pcd'
737TAB_INF_PCD_EX = 'PcdEx'
738TAB_INF_GUIDTYPE_VAR = 'Variable'
739TAB_INF_ABSTRACT = 'STR_MODULE_ABSTRACT'
740TAB_INF_DESCRIPTION = 'STR_MODULE_DESCRIPTION'
741TAB_INF_LICENSE = 'STR_MODULE_LICENSE'
742TAB_INF_BINARY_ABSTRACT = 'STR_MODULE_BINARY_ABSTRACT'
743TAB_INF_BINARY_DESCRIPTION = 'STR_MODULE_BINARY_DESCRIPTION'
744TAB_INF_BINARY_LICENSE = 'STR_MODULE_BINARY_LICENSE'
745#
746# Dec Definitions
747#
748TAB_DEC_DEFINES = TAB_COMMON_DEFINES
749TAB_DEC_DEFINES_DEC_SPECIFICATION = 'DEC_SPECIFICATION'
750TAB_DEC_DEFINES_PACKAGE_NAME = 'PACKAGE_NAME'
751TAB_DEC_DEFINES_PACKAGE_GUID = 'PACKAGE_GUID'
752TAB_DEC_DEFINES_PACKAGE_VERSION = 'PACKAGE_VERSION'
753TAB_DEC_DEFINES_PKG_UNI_FILE    = 'PACKAGE_UNI_FILE'
754TAB_DEC_PACKAGE_ABSTRACT = 'STR_PACKAGE_ABSTRACT'
755TAB_DEC_PACKAGE_DESCRIPTION = 'STR_PACKAGE_DESCRIPTION'
756TAB_DEC_PACKAGE_LICENSE = 'STR_PACKAGE_LICENSE'
757TAB_DEC_BINARY_ABSTRACT = 'STR_PACKAGE_BINARY_ABSTRACT'
758TAB_DEC_BINARY_DESCRIPTION = 'STR_PACKAGE_BINARY_DESCRIPTION'
759TAB_DEC_BINARY_LICENSE = 'STR_PACKAGE_ASBUILT_LICENSE'
760#
761# Dsc Definitions
762#
763TAB_DSC_DEFINES = TAB_COMMON_DEFINES
764TAB_DSC_DEFINES_PLATFORM_NAME = 'PLATFORM_NAME'
765TAB_DSC_DEFINES_PLATFORM_GUID = 'PLATFORM_GUID'
766TAB_DSC_DEFINES_PLATFORM_VERSION = 'PLATFORM_VERSION'
767TAB_DSC_DEFINES_DSC_SPECIFICATION = 'DSC_SPECIFICATION'
768TAB_DSC_DEFINES_OUTPUT_DIRECTORY = 'OUTPUT_DIRECTORY'
769TAB_DSC_DEFINES_SUPPORTED_ARCHITECTURES = 'SUPPORTED_ARCHITECTURES'
770TAB_DSC_DEFINES_BUILD_TARGETS = 'BUILD_TARGETS'
771TAB_DSC_DEFINES_SKUID_IDENTIFIER = 'SKUID_IDENTIFIER'
772TAB_DSC_DEFINES_FLASH_DEFINITION = 'FLASH_DEFINITION'
773TAB_DSC_DEFINES_BUILD_NUMBER = 'BUILD_NUMBER'
774TAB_DSC_DEFINES_MAKEFILE_NAME = 'MAKEFILE_NAME'
775TAB_DSC_DEFINES_BS_BASE_ADDRESS = 'BsBaseAddress'
776TAB_DSC_DEFINES_RT_BASE_ADDRESS = 'RtBaseAddress'
777TAB_DSC_DEFINES_DEFINE = 'DEFINE'
778TAB_FIX_LOAD_TOP_MEMORY_ADDRESS = 'FIX_LOAD_TOP_MEMORY_ADDRESS'
779
780#
781# TargetTxt Definitions
782#
783TAB_TAT_DEFINES_ACTIVE_PLATFORM = 'ACTIVE_PLATFORM'
784TAB_TAT_DEFINES_ACTIVE_MODULE = 'ACTIVE_MODULE'
785TAB_TAT_DEFINES_TOOL_CHAIN_CONF = 'TOOL_CHAIN_CONF'
786TAB_TAT_DEFINES_MULTIPLE_THREAD = 'MULTIPLE_THREAD'
787TAB_TAT_DEFINES_MAX_CONCURRENT_THREAD_NUMBER = 'MAX_CONCURRENT_THREAD_NUMBER'
788TAB_TAT_DEFINES_TARGET = 'TARGET'
789TAB_TAT_DEFINES_TOOL_CHAIN_TAG = 'TOOL_CHAIN_TAG'
790TAB_TAT_DEFINES_TARGET_ARCH = 'TARGET_ARCH'
791TAB_TAT_DEFINES_BUILD_RULE_CONF = "BUILD_RULE_CONF"
792
793#
794# ToolDef Definitions
795#
796TAB_TOD_DEFINES_TARGET = 'TARGET'
797TAB_TOD_DEFINES_TOOL_CHAIN_TAG = 'TOOL_CHAIN_TAG'
798TAB_TOD_DEFINES_TARGET_ARCH = 'TARGET_ARCH'
799TAB_TOD_DEFINES_COMMAND_TYPE = 'COMMAND_TYPE'
800TAB_TOD_DEFINES_FAMILY = 'FAMILY'
801TAB_TOD_DEFINES_BUILDRULEFAMILY = 'BUILDRULEFAMILY'
802
803#
804# Conditional Statements
805#
806TAB_IF = '!if'
807TAB_END_IF = '!endif'
808TAB_ELSE_IF = '!elseif'
809TAB_ELSE = '!else'
810TAB_IF_DEF = '!ifdef'
811TAB_IF_N_DEF = '!ifndef'
812TAB_IF_EXIST = '!if exist'
813
814#
815# Unknown section
816#
817TAB_UNKNOWN = 'UNKNOWN'
818
819#
820# Header section (virtual section for abstract, description, copyright,
821# license)
822#
823TAB_HEADER = 'Header'
824TAB_HEADER_ABSTRACT = 'Abstract'
825TAB_HEADER_DESCRIPTION = 'Description'
826TAB_HEADER_COPYRIGHT = 'Copyright'
827TAB_HEADER_LICENSE = 'License'
828TAB_BINARY_HEADER_IDENTIFIER = 'BinaryHeader'
829TAB_BINARY_HEADER_USERID = 'TianoCore'
830
831#
832# Build database path
833#
834DATABASE_PATH = ":memory:"
835#
836# used by ECC
837#
838MODIFIER_LIST = ['IN', 'OUT', 'OPTIONAL', 'UNALIGNED', 'EFI_RUNTIMESERVICE', \
839                 'EFI_BOOTSERVICE', 'EFIAPI']
840#
841# Dependency Expression
842#
843DEPEX_SUPPORTED_OPCODE = ["BEFORE", "AFTER", "PUSH", "AND", "OR", "NOT", \
844                          "END", "SOR", "TRUE", "FALSE", '(', ')']
845
846TAB_STATIC_LIBRARY = "STATIC-LIBRARY-FILE"
847TAB_DYNAMIC_LIBRARY = "DYNAMIC-LIBRARY-FILE"
848TAB_FRAMEWORK_IMAGE = "EFI-IMAGE-FILE"
849TAB_C_CODE_FILE = "C-CODE-FILE"
850TAB_C_HEADER_FILE = "C-HEADER-FILE"
851TAB_UNICODE_FILE = "UNICODE-TEXT-FILE"
852TAB_DEPENDENCY_EXPRESSION_FILE = "DEPENDENCY-EXPRESSION-FILE"
853TAB_UNKNOWN_FILE = "UNKNOWN-TYPE-FILE"
854TAB_DEFAULT_BINARY_FILE = "_BINARY_FILE_"
855#
856# used to indicate the state of processing header comment section of dec,
857# inf files
858#
859HEADER_COMMENT_NOT_STARTED = -1
860HEADER_COMMENT_STARTED     = 0
861HEADER_COMMENT_FILE        = 1
862HEADER_COMMENT_ABSTRACT    = 2
863HEADER_COMMENT_DESCRIPTION = 3
864HEADER_COMMENT_COPYRIGHT   = 4
865HEADER_COMMENT_LICENSE     = 5
866HEADER_COMMENT_END         = 6
867
868#
869# Static values for data models
870#
871MODEL_UNKNOWN = 0
872
873MODEL_FILE_C = 1001
874MODEL_FILE_H = 1002
875MODEL_FILE_ASM = 1003
876MODEL_FILE_INF = 1011
877MODEL_FILE_DEC = 1012
878MODEL_FILE_DSC = 1013
879MODEL_FILE_FDF = 1014
880MODEL_FILE_INC = 1015
881MODEL_FILE_CIF = 1016
882
883MODEL_IDENTIFIER_FILE_HEADER = 2001
884MODEL_IDENTIFIER_FUNCTION_HEADER = 2002
885MODEL_IDENTIFIER_COMMENT = 2003
886MODEL_IDENTIFIER_PARAMETER = 2004
887MODEL_IDENTIFIER_STRUCTURE = 2005
888MODEL_IDENTIFIER_VARIABLE = 2006
889MODEL_IDENTIFIER_INCLUDE = 2007
890MODEL_IDENTIFIER_PREDICATE_EXPRESSION = 2008
891MODEL_IDENTIFIER_ENUMERATE = 2009
892MODEL_IDENTIFIER_PCD = 2010
893MODEL_IDENTIFIER_UNION = 2011
894MODEL_IDENTIFIER_MACRO_IFDEF = 2012
895MODEL_IDENTIFIER_MACRO_IFNDEF = 2013
896MODEL_IDENTIFIER_MACRO_DEFINE = 2014
897MODEL_IDENTIFIER_MACRO_ENDIF = 2015
898MODEL_IDENTIFIER_MACRO_PROGMA = 2016
899MODEL_IDENTIFIER_FUNCTION_CALLING = 2018
900MODEL_IDENTIFIER_TYPEDEF = 2017
901MODEL_IDENTIFIER_FUNCTION_DECLARATION = 2019
902MODEL_IDENTIFIER_ASSIGNMENT_EXPRESSION = 2020
903
904MODEL_EFI_PROTOCOL = 3001
905MODEL_EFI_PPI = 3002
906MODEL_EFI_GUID = 3003
907MODEL_EFI_LIBRARY_CLASS = 3004
908MODEL_EFI_LIBRARY_INSTANCE = 3005
909MODEL_EFI_PCD = 3006
910MODEL_EFI_SOURCE_FILE = 3007
911MODEL_EFI_BINARY_FILE = 3008
912MODEL_EFI_SKU_ID = 3009
913MODEL_EFI_INCLUDE = 3010
914MODEL_EFI_DEPEX = 3011
915
916MODEL_PCD = 4000
917MODEL_PCD_FIXED_AT_BUILD = 4001
918MODEL_PCD_PATCHABLE_IN_MODULE = 4002
919MODEL_PCD_FEATURE_FLAG = 4003
920MODEL_PCD_DYNAMIC_EX = 4004
921MODEL_PCD_DYNAMIC_EX_DEFAULT = 4005
922MODEL_PCD_DYNAMIC_EX_VPD = 4006
923MODEL_PCD_DYNAMIC_EX_HII = 4007
924MODEL_PCD_DYNAMIC = 4008
925MODEL_PCD_DYNAMIC_DEFAULT = 4009
926MODEL_PCD_DYNAMIC_VPD = 4010
927MODEL_PCD_DYNAMIC_HII = 4011
928
929MODEL_META_DATA_FILE_HEADER = 5000
930MODEL_META_DATA_HEADER = 5001
931MODEL_META_DATA_INCLUDE = 5002
932MODEL_META_DATA_DEFINE = 5003
933MODEL_META_DATA_CONDITIONAL_STATEMENT_IF = 5004
934MODEL_META_DATA_CONDITIONAL_STATEMENT_ELSE = 5005
935MODEL_META_DATA_CONDITIONAL_STATEMENT_IFDEF = 5006
936MODEL_META_DATA_CONDITIONAL_STATEMENT_IFNDEF = 5007
937MODEL_META_DATA_BUILD_OPTION = 5008
938MODEL_META_DATA_COMPONENT = 5009
939MODEL_META_DATA_USER_EXTENSION = 5010
940MODEL_META_DATA_PACKAGE = 5011
941MODEL_META_DATA_NMAKE = 5012
942MODEL_META_DATA_CONDITIONAL_STATEMENT_ELSEIF = 50013
943MODEL_META_DATA_CONDITIONAL_STATEMENT_ENDIF = 5014
944MODEL_META_DATA_COMPONENT_SOURCE_OVERRIDE_PATH = 5015
945
946TOOL_FAMILY_LIST = ["MSFT",
947                    "INTEL",
948                    "GCC",
949                    "RVCT"
950                    ]
951
952TYPE_HOB_SECTION = 'HOB'
953TYPE_EVENT_SECTION = 'EVENT'
954TYPE_BOOTMODE_SECTION = 'BOOTMODE'
955
956PCD_ERR_CODE_MAX_SIZE = 4294967295
957