]> git.proxmox.com Git - mirror_edk2.git/blob - BaseTools/Source/Python/Eot/EotGlobalData.py
BaseTools: use built in OrderedDict instead of custom version.
[mirror_edk2.git] / BaseTools / Source / Python / Eot / EotGlobalData.py
1 ## @file
2 # This file is used to save global datas
3 #
4 # Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>
5 # This program and the accompanying materials
6 # are licensed and made available under the terms and conditions of the BSD License
7 # which accompanies this distribution. The full text of the license may be found at
8 # http://opensource.org/licenses/bsd-license.php
9 #
10 # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12 #
13
14 from collections import OrderedDict
15 from Common.LongFilePathSupport import OpenLongFilePath as open
16
17 gEFI_SOURCE = ''
18 gEDK_SOURCE = ''
19 gWORKSPACE = ''
20 gSHELL_INF = 'Application\Shell'
21 gMAKE_FILE = ''
22 gDSC_FILE = ''
23 gFV_FILE = []
24 gFV = []
25 gMAP_FILE = []
26 gMap = {}
27
28
29 gDb = ''
30 gIdentifierTableList = []
31
32 # Global macro
33 gMACRO = {}
34 gMACRO['EFI_SOURCE'] = gEFI_SOURCE
35 gMACRO['EDK_SOURCE'] = gEDK_SOURCE
36 gMACRO['SHELL_INF'] = gSHELL_INF
37 gMACRO['CAPSULE_INF'] = ''
38
39 gNOT_FOUND_FILES = []
40 gSOURCE_FILES = []
41 gINF_FILES = {}
42 gDEC_FILES = []
43
44 # Log file for unmatched variables
45 gUN_MATCHED_LOG = 'Log_UnMatched.log'
46 gOP_UN_MATCHED = open(gUN_MATCHED_LOG, 'w+')
47
48 # Log file for all INF files
49 gINF_FILES = 'Log_Inf_File.log'
50 gOP_INF = open(gINF_FILES, 'w+')
51
52 # Log file for not dispatched PEIM/DRIVER
53 gUN_DISPATCHED_LOG = 'Log_UnDispatched.log'
54 gOP_UN_DISPATCHED = open(gUN_DISPATCHED_LOG, 'w+')
55
56 # Log file for unmatched variables in function calling
57 gUN_MATCHED_IN_LIBRARY_CALLING_LOG = 'Log_UnMatchedInLibraryCalling.log'
58 gOP_UN_MATCHED_IN_LIBRARY_CALLING = open(gUN_MATCHED_IN_LIBRARY_CALLING_LOG, 'w+')
59
60 # Log file for order of dispatched PEIM/DRIVER
61 gDISPATCH_ORDER_LOG = 'Log_DispatchOrder.log'
62 gOP_DISPATCH_ORDER = open(gDISPATCH_ORDER_LOG, 'w+')
63
64 # Log file for source files not found
65 gUN_FOUND_FILES = 'Log_UnFoundSourceFiles.log'
66 gOP_UN_FOUND_FILES = open(gUN_FOUND_FILES, 'w+')
67
68 # Log file for found source files
69 gSOURCE_FILES = 'Log_SourceFiles.log'
70 gOP_SOURCE_FILES = open(gSOURCE_FILES, 'w+')
71
72 # Dict for GUID found in DEC files
73 gGuidDict = dict()
74
75 # Dict for PPI
76 gPpiList = {}
77
78 # Dict for PROTOCOL
79 gProtocolList = {}
80
81 # Dict for consumed PPI function calling
82 gConsumedPpiLibrary = OrderedDict()
83 gConsumedPpiLibrary['EfiCommonLocateInterface'] = 0
84 gConsumedPpiLibrary['PeiServicesLocatePpi'] = 0
85
86 # Dict for produced PROTOCOL function calling
87 gProducedProtocolLibrary = OrderedDict()
88 gProducedProtocolLibrary['RegisterEsalClass'] = 0
89 gProducedProtocolLibrary['CoreInstallProtocolInterface'] = 1
90 gProducedProtocolLibrary['CoreInstallMultipleProtocolInterfaces'] = -1
91 gProducedProtocolLibrary['EfiInstallProtocolInterface'] = 1
92 gProducedProtocolLibrary['EfiReinstallProtocolInterface'] = 1
93 gProducedProtocolLibrary['EfiLibNamedEventSignal'] = 0
94 gProducedProtocolLibrary['LibInstallProtocolInterfaces'] = 1
95 gProducedProtocolLibrary['LibReinstallProtocolInterfaces'] = 1
96
97 # Dict for consumed PROTOCOL function calling
98 gConsumedProtocolLibrary = OrderedDict()
99 gConsumedProtocolLibrary['EfiHandleProtocol'] = 0
100 gConsumedProtocolLibrary['EfiLocateProtocolHandleBuffers'] = 0
101 gConsumedProtocolLibrary['EfiLocateProtocolInterface'] = 0
102 gConsumedProtocolLibrary['EfiHandleProtocol'] = 1
103
104 # Dict for callback PROTOCOL function callling
105 gCallbackProtocolLibrary = OrderedDict()
106 gCallbackProtocolLibrary['EfiRegisterProtocolCallback'] = 2
107
108 # Dict for ARCH PROTOCOL
109 gArchProtocols = ['gEfiBdsArchProtocolGuid',
110 'gEfiCapsuleArchProtocolGuid',
111 'gEfiCpuArchProtocolGuid', #5053697e-2cbc-4819-90d9-0580deee5754
112 'gEfiMetronomeArchProtocolGuid',
113 'gEfiMonotonicCounterArchProtocolGuid',
114 'gEfiRealTimeClockArchProtocolGuid',
115 'gEfiResetArchProtocolGuid',
116 'gEfiRuntimeArchProtocolGuid',
117 'gEfiSecurityArchProtocolGuid',
118 'gEfiStatusCodeRuntimeProtocolGuid',
119 'gEfiTimerArchProtocolGuid',
120 'gEfiVariableArchProtocolGuid',
121 'gEfiVariableWriteArchProtocolGuid',
122 'gEfiWatchdogTimerArchProtocolGuid']
123 gArchProtocolGuids = ['665e3ff6-46cc-11d4-9a38-0090273fc14d',
124 '26baccb1-6f42-11d4-bce7-0080c73c8881',
125 '26baccb2-6f42-11d4-bce7-0080c73c8881',
126 '1da97072-bddc-4b30-99f1-72a0b56fff2a',
127 '27cfac87-46cc-11d4-9a38-0090273fc14d',
128 '27cfac88-46cc-11d4-9a38-0090273fc14d',
129 'b7dfb4e1-052f-449f-87be-9818fc91b733',
130 'a46423e3-4617-49f1-b9ff-d1bfa9115839',
131 'd2b2b828-0826-48a7-b3df-983c006024f0',
132 '26baccb3-6f42-11d4-bce7-0080c73c8881',
133 '1e5668e2-8481-11d4-bcf1-0080c73c8881',
134 '6441f818-6362-4e44-b570-7dba31dd2453',
135 '665e3ff5-46cc-11d4-9a38-0090273fc14d']