]> git.proxmox.com Git - mirror_edk2.git/blob - EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Include/Common/EdkIIGlueDependencies.h
Add in the 1st version of ECP.
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Library / EdkIIGlueLib / Include / Common / EdkIIGlueDependencies.h
1 /*++
2
3 Copyright (c) 2004 - 2006, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12
13 Module Name:
14
15 EdkIIGlueDepedencies.h
16
17 Abstract:
18
19 Header file that lists dependency relations among library instances
20
21 --*/
22
23 #ifndef __EDKII_GLUE_DEPENDENCIES_H__
24 #define __EDKII_GLUE_DEPENDENCIES_H__
25
26 #include "EdkIIGlueProcessorBind.h"
27
28 //
29 // Declarations of dependencies among EdkII Glue Library instances and R8 Libraries
30 // Pay attention to the order of following #define structures
31 //
32
33
34 //
35 // PeiDxeDebugLibReportStatusCode
36 // Actually almost every module and GlueLib instance needs this library, but GlueLib
37 // instances don't have to list this library in their own inf files. Module inf
38 // does this.
39 //
40 #ifdef __EDKII_GLUE_PEI_DXE_DEBUG_LIB_REPORT_STATUS_CODE__
41 #ifndef __EDKII_GLUE_BASE_LIB__
42 #define __EDKII_GLUE_BASE_LIB__
43 #endif
44 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
45 #define __EDKII_GLUE_BASE_MEMORY_LIB__
46 #endif
47 #endif
48
49 //
50 // BaseDebugLibNull
51 //
52 #ifdef __EDKII_GLUE_BASE_DEBUG_LIB_NULL__
53 #ifndef __EDKII_GLUE_BASE_LIB__
54 #define __EDKII_GLUE_BASE_LIB__
55 #endif
56 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
57 #define __EDKII_GLUE_BASE_MEMORY_LIB__
58 #endif
59 #ifndef __EDKII_GLUE_BASE_PRINT_LIB__
60 #define __EDKII_GLUE_BASE_PRINT_LIB__
61 #endif
62 #endif
63
64 //
65 // EdkDxeRuntimeDriverLib
66 //
67 #ifdef __EDKII_GLUE_EDK_DXE_RUNTIME_DRIVER_LIB__
68 #ifndef __EDKII_GLUE_UEFI_LIB__
69 #define __EDKII_GLUE_UEFI_LIB__
70 #endif
71 #ifndef __EDKII_GLUE_BASE_LIB__
72 #define __EDKII_GLUE_BASE_LIB__
73 #endif
74 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
75 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
76 #endif
77 #ifdef MDE_CPU_IPF // IPF
78 #ifndef __EDKII_GLUE_EDK_DXE_SAL_LIB__
79 #define __EDKII_GLUE_EDK_DXE_SAL_LIB__
80 #endif
81 #endif // IPF
82 #endif
83
84 //
85 // EdkDxeSalLib
86 //
87 #ifdef __EDKII_GLUE_EDK_DXE_SAL_LIB__
88 #ifndef __EDKII_GLUE_BASE_LIB__
89 #define __EDKII_GLUE_BASE_LIB__
90 #endif
91 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
92 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
93 #endif
94 #endif
95
96 //
97 // BasePciLibCf8
98 //
99 #ifdef __EDKII_GLUE_BASE_PCI_LIB_CF8__
100 #ifndef __EDKII_GLUE_BASE_PCI_CF8_LIB__
101 #define __EDKII_GLUE_BASE_PCI_CF8_LIB__
102 #endif
103 #endif
104
105 //
106 // BasePciLibPciExpress
107 //
108 #ifdef __EDKII_GLUE_BASE_PCI_LIB_PCI_EXPRESS__
109 #ifndef __EDKII_GLUE_BASE_PCI_EXPRESS_LIB__
110 #define __EDKII_GLUE_BASE_PCI_EXPRESS_LIB__
111 #endif
112 #endif
113
114 //
115 // BasePciCf8Lib
116 //
117 #ifdef __EDKII_GLUE_BASE_PCI_CF8_LIB__
118 #ifndef MDE_CPU_EBC
119 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
120 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
121 #endif
122 #else
123 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
124 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
125 #endif
126 #endif
127 #endif
128
129 //
130 // BasePciExpressLib
131 //
132 #ifdef __EDKII_GLUE_BASE_PCI_EXPRESS_LIB__
133 #ifndef MDE_CPU_EBC
134 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
135 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
136 #endif
137 #else
138 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
139 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
140 #endif
141 #endif
142 #endif
143
144 //
145 // BaseTimerLibLocalApic
146 //
147 #ifdef __EDKII_GLUE_BASE_TIMER_LIB_LOCAL_APIC__
148 #ifndef __EDKII_GLUE_BASE_LIB__
149 #define __EDKII_GLUE_BASE_LIB__
150 #endif
151 #ifndef MDE_CPU_EBC
152 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
153 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
154 #endif
155 #else
156 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
157 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
158 #endif
159 #endif
160 #endif
161
162 //
163 // DxeReportStatusCodeLib
164 //
165 #ifdef __EDKII_GLUE_DXE_REPORT_STATUS_CODE_LIB__
166 #ifndef __EDKII_GLUE_BASE_LIB__
167 #define __EDKII_GLUE_BASE_LIB__
168 #endif
169 #ifndef MDE_CPU_EBC
170 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
171 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
172 #endif
173 #else
174 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
175 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
176 #endif
177 #endif
178 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
179 #define __EDKII_GLUE_BASE_MEMORY_LIB__
180 #endif
181 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
182 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
183 #endif
184 #ifndef __EDKII_GLUE_UEFI_RUNTIME_SERVICES_TABLE_LIB__
185 #define __EDKII_GLUE_UEFI_RUNTIME_SERVICES_TABLE_LIB__
186 #endif
187 #endif
188
189 //
190 // PeiReportStatusCodeLib
191 //
192 #ifdef __EDKII_GLUE_PEI_REPORT_STATUS_CODE_LIB__
193 #ifndef __EDKII_GLUE_BASE_LIB__
194 #define __EDKII_GLUE_BASE_LIB__
195 #endif
196 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
197 #define __EDKII_GLUE_BASE_MEMORY_LIB__
198 #endif
199 #ifndef MDE_CPU_EBC
200 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
201 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
202 #endif
203 #else
204 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
205 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
206 #endif
207 #endif
208 #if defined(MDE_CPU_IA32) || defined(MDE_CPU_X64)
209 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
210 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
211 #endif
212 #elif defined(MDE_CPU_IPF)
213 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
214 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
215 #endif
216 #endif
217 //
218 // If necessary, __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__ or
219 // __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__ can be
220 // replaced with __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
221 //
222 #endif
223
224 //
225 // BasePeCoffLib
226 //
227 #ifdef __EDKII_GLUE_BASE_PE_COFF_LIB__
228 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
229 #define __EDKII_GLUE_BASE_MEMORY_LIB__
230 #endif
231 #endif
232
233 //
234 // BaseUefiDecompressLib
235 //
236 #ifdef __EDKII_GLUE_BASE_UEFI_DECOMPRESS_LIB__
237 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
238 #define __EDKII_GLUE_BASE_MEMORY_LIB__
239 #endif
240 #endif
241
242 //
243 // DxeHobLib
244 //
245 #ifdef __EDKII_GLUE_DXE_HOB_LIB__
246 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
247 #define __EDKII_GLUE_BASE_MEMORY_LIB__
248 #endif
249 #ifndef __EDKII_GLUE_UEFI_LIB__
250 #define __EDKII_GLUE_UEFI_LIB__
251 #endif
252 #endif
253
254 //
255 // HiiLib
256 //
257 #ifdef __EDKII_GLUE_HII_LIB__
258 #ifndef __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
259 #define __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
260 #endif
261 #endif
262
263 //
264 // UefiDevicePathLib
265 //
266 #ifdef __EDKII_GLUE_UEFI_DEVICE_PATH_LIB__
267 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
268 #define __EDKII_GLUE_BASE_MEMORY_LIB__
269 #endif
270 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
271 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
272 #endif
273 #ifndef __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
274 #define __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
275 #endif
276 #endif
277
278 //
279 // UefiLib
280 //
281 #ifdef __EDKII_GLUE_UEFI_LIB__
282 #ifndef __EDKII_GLUE_BASE_LIB__
283 #define __EDKII_GLUE_BASE_LIB__
284 #endif
285 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
286 #define __EDKII_GLUE_BASE_MEMORY_LIB__
287 #endif
288 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
289 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
290 #endif
291 #ifndef __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
292 #define __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
293 #endif
294 #endif
295
296 //
297 // DxeMemoryAllocationLib
298 //
299 #ifdef __EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__
300 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
301 #define __EDKII_GLUE_BASE_MEMORY_LIB__
302 #endif
303 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
304 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
305 #endif
306 #endif
307
308 //
309 // DxeSmbusLib
310 //
311 #ifdef __EDKII_GLUE_DXE_SMBUS_LIB__
312 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
313 #define __EDKII_GLUE_BASE_MEMORY_LIB__
314 #endif
315 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
316 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
317 #endif
318 #endif
319
320 //
321 // PeiHobLib
322 //
323 #ifdef __EDKII_GLUE_PEI_HOB_LIB__
324 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
325 #define __EDKII_GLUE_BASE_MEMORY_LIB__
326 #endif
327 #ifndef __EDKII_GLUE_PEI_SERVICES_LIB__
328 #define __EDKII_GLUE_PEI_SERVICES_LIB__
329 #endif
330 #endif
331
332 //
333 // PeiMemoryAllocationLib
334 //
335 #ifdef __EDKII_GLUE_PEI_MEMORY_ALLOCATION_LIB__
336 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
337 #define __EDKII_GLUE_BASE_MEMORY_LIB__
338 #endif
339 #if defined(MDE_CPU_IA32) || defined(MDE_CPU_X64)
340 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
341 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
342 #endif
343 #elif defined(MDE_CPU_IPF)
344 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
345 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
346 #endif
347 #endif
348 //
349 // If necessary, __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__ or
350 // __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__ can be
351 // replaced with __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
352 //
353 #endif
354
355 //
356 // PeiResourcePublicationLib
357 //
358 #ifdef __EDKII_GLUE_PEI_RESOURCE_PUBLICATION_LIB__
359 #ifndef __EDKII_GLUE_PEI_SERVICES_LIB__
360 #define __EDKII_GLUE_PEI_SERVICES_LIB__
361 #endif
362 #endif
363
364 //
365 // PeiServicesLib
366 //
367 #ifdef __EDKII_GLUE_PEI_SERVICES_LIB__
368 #if defined(MDE_CPU_IA32) || defined(MDE_CPU_X64)
369 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
370 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
371 #endif
372 #elif defined(MDE_CPU_IPF)
373 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
374 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
375 #endif
376 #endif
377 //
378 // If necessary, __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__ or
379 // __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__ can be
380 // replaced with __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
381 //
382 #endif
383
384 //
385 // PeiSmbusLib
386 //
387 #ifdef __EDKII_GLUE_PEI_SMBUS_LIB__
388 #ifndef __EDKII_GLUE_BASE_MEMORY_LIB__
389 #define __EDKII_GLUE_BASE_MEMORY_LIB__
390 #endif
391 #if defined(MDE_CPU_IA32) || defined(MDE_CPU_X64)
392 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
393 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
394 #endif
395 #elif defined(MDE_CPU_IPF)
396 #ifndef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
397 #define __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
398 #endif
399 #endif
400 //
401 // If necessary, __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__ or
402 // __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__ can be
403 // replaced with __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
404 //
405 #endif
406
407 //
408 // PeiServicesTablePointerLibMm7
409 //
410 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
411 #ifndef __EDKII_GLUE_BASE_LIB__
412 #define __EDKII_GLUE_BASE_LIB__
413 #endif
414 #endif
415
416 //
417 // PeiServicesTablePointerLibKr1
418 //
419 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
420 #ifndef __EDKII_GLUE_BASE_LIB__
421 #define __EDKII_GLUE_BASE_LIB__
422 #endif
423 #endif
424
425
426 //
427 // UefiDriverModelLib
428 //
429 #ifdef __EDKII_GLUE_UEFI_DRIVER_MODEL_LIB__
430 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
431 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
432 #endif
433 #endif
434
435 //
436 // DxeServicesTableLib
437 //
438 #ifdef __EDKII_GLUE_DXE_SERVICES_TABLE_LIB__
439 #ifndef __EDKII_GLUE_UEFI_LIB__
440 #define __EDKII_GLUE_UEFI_LIB__
441 #endif
442 #endif
443
444 //
445 // BasePrintLib
446 //
447 #ifdef __EDKII_GLUE_BASE_PRINT_LIB__
448 #ifndef __EDKII_GLUE_BASE_LIB__
449 #define __EDKII_GLUE_BASE_LIB__
450 #endif
451 #endif
452
453 //
454 // BaseMemoryLib
455 //
456 #ifdef __EDKII_GLUE_BASE_MEMORY_LIB__
457 #ifndef __EDKII_GLUE_BASE_LIB__
458 #define __EDKII_GLUE_BASE_LIB__
459 #endif
460 #endif
461
462 //
463 // BasePostCodeLibPort80
464 //
465 #ifdef __EDKII_GLUE_BASE_POST_CODE_LIB_PORT_80__
466 #ifndef MDE_CPU_EBC
467 #ifndef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
468 #define __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
469 #endif
470 #else
471 #ifndef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
472 #define __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
473 #endif
474 #endif
475 #endif
476
477 //
478 // BaseIoLibIntrinsic
479 //
480 #ifdef __EDKII_GLUE_BASE_IO_LIB_INTRINSIC__
481 #ifndef __EDKII_GLUE_BASE_LIB__
482 #define __EDKII_GLUE_BASE_LIB__
483 #endif
484 #endif
485
486 //
487 // DxeIoLibCpuIo
488 //
489 #ifdef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
490 #ifndef __EDKII_GLUE_BASE_LIB__
491 #define __EDKII_GLUE_BASE_LIB__
492 #endif
493 #ifndef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
494 #define __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
495 #endif
496 #endif
497
498 //
499 // UefiBootServicesTableLib
500 //
501 #ifdef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
502 #endif
503
504 //
505 // BaseCacheMaintenanceLib
506 //
507 #ifdef __EDKII_GLUE_BASE_CACHE_MAINTENANCE_LIB__
508 #ifndef __EDKII_GLUE_BASE_LIB__
509 #define __EDKII_GLUE_BASE_LIB__
510 #endif
511 #endif
512
513 //
514 // BaseLib
515 //
516 #ifdef __EDKII_GLUE_BASE_LIB__
517 #endif
518
519 //
520 // UefiRuntimeServicesTableLib
521 //
522 #ifdef __EDKII_GLUE_UEFI_RUNTIME_SERVICES_TABLE_LIB__
523 #endif
524
525 //
526 // BasePeCoffGetEntryPointLib
527 //
528 #ifdef __EDKII_GLUE_BASE_PE_COFF_GET_ENTRY_POINT_LIB__
529 #endif
530
531 //
532 // PeiServicesTablePointerLib
533 //
534 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
535 #endif
536
537 //
538 // BasePostCodeLibDebug
539 //
540 #ifdef __EDKII_GLUE_BASE_POST_CODE_LIB_DEBUG__
541 //
542 // A DebugLib instance
543 // Usually EdkIIGluePeiDxeDebugLibReportStatusCodeLib is listed in module inf
544 //
545 #endif
546
547 //
548 // PeiDxePostCodeLibReportStatusCode
549 //
550 #ifdef __EDKII_GLUE_PEI_DXE_POST_CODE_LIB_REPORT_STATUS_CODE__
551 //
552 // PEI or DXE ReportStatusCodeLib instance
553 // Usually EdkIIGluePei/DxeReportStatusCodeLib is listed in module inf
554 //
555 #endif
556
557
558 //
559 // Check against multiple instances of same library class being used
560 //
561 #if defined(__EDKII_GLUE_PEI_DXE_DEBUG_LIB_REPORT_STATUS_CODE__) && defined(__EDKII_GLUE_BASE_DEBUG_LIB_NULL__)
562 #error EdkIIGluePeiDxeDebugLibReportStatusCode and EdkIIGlueBaseDebugLibNull: can only be mutual exclusively used.
563 #endif
564
565 #if defined(__EDKII_GLUE_BASE_PCI_LIB_PCI_EXPRESS__) && defined(__EDKII_GLUE_BASE_PCI_LIB_CF8__)
566 #error EdkIIGluePciLibPciExpress and EdkIIGluePciLibCf8: can only be mutual exclusively used.
567 #endif
568
569 #if defined (__EDKII_GLUE_DXE_HOB_LIB__) && (__EDKII_GLUE_PEI_HOB_LIB__)
570 #error EdkIIGlueDxeHobLib and EdkIIGluePeiHobLib: can only be mutual exclusively used.
571 #endif
572
573 #if defined(__EDKII_GLUE_BASE_POST_CODE_LIB_PORT_80__) && defined(__EDKII_GLUE_BASE_POST_CODE_LIB_DEBUG__)
574 #error EdkIIGlueBasePostCodeLibPort80 and EdkIIGlueBasePostCodeLibDebug: can only be mutual exclusively used.
575 #endif
576
577 #if defined(__EDKII_GLUE_BASE_POST_CODE_LIB_PORT_80__) && defined(__EDKII_GLUE_PEI_DXE_POST_CODE_LIB_REPORT_STATUS_CODE__)
578 #error EdkIIGlueBasePostCodeLibPort80 and EdkIIGluePeiDxePostCodeLibReportStatusCode: can only be mutual exclusively used.
579 #endif
580
581 #if defined(__EDKII_GLUE_BASE_POST_CODE_LIB_DEBUG__) && defined(__EDKII_GLUE_PEI_DXE_POST_CODE_LIB_REPORT_STATUS_CODE__)
582 #error EdkIIGlueBasePostCodeLibDebug and EdkIIGluePeiDxePostCodeLibReportStatusCode: can only be mutual exclusively used.
583 #endif
584
585 #if defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__) && defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__)
586 #error EdkIIGluePeiServicesTablePointerLib and EdkIIGluePeiServicesTablePointerLibMm7: can only be mutual exclusively used.
587 #endif
588
589 #if defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__) && defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__)
590 #error EdkIIGluePeiServicesTablePointerLib and EdkIIGluePeiServicesTablePointerLibKr1: can only be mutual exclusively used.
591 #endif
592
593 #if defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__) && defined(__EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__)
594 #error EdkIIGluePeiServicesTablePointerLibMm7 and EdkIIGluePeiServicesTablePointerLibKr1: can only be mutual exclusively used.
595 #endif
596
597 #if defined(__EDKII_GLUE_DXE_REPORT_STATUS_CODE_LIB__) && defined(__EDKII_GLUE_PEI_REPORT_STATUS_CODE_LIB__)
598 #error EdkIIGlueDxeReportStatusCodeLib and EdkIIGluePeiReportStatusCodeLib: can only be mutual exclusively used.
599 #endif
600
601 #if defined(__EDKII_GLUE_DXE_MEMORY_ALLOCATION_LIB__) && defined(__EDKII_GLUE_PEI_MEMORY_ALLOCATION_LIB__)
602 #error EdkIIGlueDxeMemoryAllocationLib and EdkIIGluePeiMemoryAllocationLib: can only be mutual exclusively used.
603 #endif
604
605 #if defined(__EDKII_GLUE_DXE_SMBUS_LIB__) && defined(__EDKII_GLUE_PEI_SMBUS_LIB__)
606 #error EdkIIGlueDxeSmbusLib and EdkIIGluePeiSmbusLib: can only be mutual exclusively used.
607 #endif
608
609 #if defined(__EDKII_GLUE_BASE_IO_LIB_INTRINSIC__) && defined(__EDKII_GLUE_DXE_IO_LIB_CPU_IO__)
610 #error EdkIIGlueBaseIoLibIntrinsic and EdkIIGlueDxeIoLibCpuIo: can only be mutual exclusively used.
611 #endif
612
613 //
614 // Some instances must be supplied
615 //
616 #ifdef __EDKII_GLUE_PEI_DXE_DEBUG_LIB_REPORT_STATUS_CODE__
617 #if !defined(__EDKII_GLUE_DXE_REPORT_STATUS_CODE_LIB__) && !defined(__EDKII_GLUE_PEI_REPORT_STATUS_CODE_LIB__)
618 #error You use EdkIIGluePeiDxeDebugLibReportStatusCode, so either EdkIIGlueDxeReportStatusCodeLib or EdkIIGluePeiReportStatusCodeLib must be supplied
619 #endif
620 #endif
621
622 #ifdef __EDKII_GLUE_BASE_POST_CODE_LIB_DEBUG__
623 #if !defined(__EDKII_GLUE_PEI_DXE_DEBUG_LIB_REPORT_STATUS_CODE__) && !defined(__EDKII_GLUE_BASE_DEBUG_LIB_NULL__)
624 #error You use EdkIIGlueBasePostCodeLibDebug, so either EdkIIGluePeiDxeDebugLibReportStatusCode or EdkIIGlueBaseDebugLibNull must be supplied
625 #endif
626 #endif
627
628 //
629 // EdkIIGlueUefiDriverModelLib used, but no Driver Binding Protocol defined
630 //
631 #ifdef __EDKII_GLUE_UEFI_DRIVER_MODEL_LIB__
632 #ifndef __EDKII_GLUE_DRIVER_BINDING_PROTOCOL_INSTANCE__
633 #error "EdkIIGlueUefiDriverModelLib used, but no Driver Binding Protocol defined. Please define __EDKII_GLUE_DRIVER_BINDING_PROTOCOL_INSTANCE__."
634 #endif
635 #endif
636
637 //
638 // EdkII Glue Library Constructors:
639 // NOTE: the constructors must be called according to dependency order
640 //
641 // UefiBootServicesTableLib UefiBootServicesTableLibConstructor()
642 // DxeIoLibCpuIo IoLibConstructor()
643 // UefiRuntimeServicesTableLib UefiRuntimeServicesTableLibConstructor()
644 // EdkDxeRuntimeDriverLib RuntimeDriverLibConstruct()
645 // DxeHobLib HobLibConstructor()
646 // UefiDriverModelLib UefiDriverModelLibConstructor()
647 // PeiServicesTablePointerLib PeiServicesTablePointerLibConstructor()
648 // PeiServicesTablePointerLibMm7 PeiServicesTablePointerLibConstructor()
649 // PeiServicesTablePointerLibKr1 PeiServicesTablePointerLibConstructor()
650 // DxeSmbusLib SmbusLibConstructor()
651 // DxeServicesTableLib DxeServicesTableLibConstructor()
652 // DxeSalLib DxeSalLibConstructor()
653 //
654
655 #ifdef __EDKII_GLUE_UEFI_BOOT_SERVICES_TABLE_LIB__
656 EFI_STATUS
657 UefiBootServicesTableLibConstructor (
658 IN EFI_HANDLE ImageHandle,
659 IN EFI_SYSTEM_TABLE *SystemTable
660 );
661 #endif
662
663 #ifdef __EDKII_GLUE_DXE_IO_LIB_CPU_IO__
664 EFI_STATUS
665 EFIAPI
666 IoLibConstructor (
667 IN EFI_HANDLE ImageHandle,
668 IN EFI_SYSTEM_TABLE *SystemTable
669 );
670 #endif
671
672 #ifdef __EDKII_GLUE_UEFI_RUNTIME_SERVICES_TABLE_LIB__
673 EFI_STATUS
674 UefiRuntimeServicesTableLibConstructor (
675 IN EFI_HANDLE ImageHandle,
676 IN EFI_SYSTEM_TABLE *SystemTable
677 );
678 #endif
679
680 #ifdef __EDKII_GLUE_EDK_DXE_RUNTIME_DRIVER_LIB__
681 EFI_STATUS
682 RuntimeDriverLibConstruct (
683 IN EFI_HANDLE ImageHandle,
684 IN EFI_SYSTEM_TABLE *SystemTable
685 );
686 #endif
687
688 #ifdef __EDKII_GLUE_DXE_HOB_LIB__
689 EFI_STATUS
690 HobLibConstructor (
691 IN EFI_HANDLE ImageHandle,
692 IN EFI_SYSTEM_TABLE *SystemTable
693 );
694 #endif
695
696 #ifdef __EDKII_GLUE_UEFI_DRIVER_MODEL_LIB__
697 EFI_STATUS
698 UefiDriverModelLibConstructor (
699 IN EFI_HANDLE ImageHandle,
700 IN EFI_SYSTEM_TABLE *SystemTable
701 );
702 #endif
703
704 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB__
705 EFI_STATUS
706 PeiServicesTablePointerLibConstructor (
707 IN EFI_FFS_FILE_HEADER *FfsHeader,
708 IN EFI_PEI_SERVICES **PeiServices
709 );
710 #endif
711
712 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_MM7__
713 EFI_STATUS
714 PeiServicesTablePointerLibConstructor (
715 IN EFI_FFS_FILE_HEADER *FfsHeader,
716 IN EFI_PEI_SERVICES **PeiServices
717 );
718 #endif
719
720 #ifdef __EDKII_GLUE_PEI_SERVICES_TABLE_POINTER_LIB_KR1__
721 EFI_STATUS
722 PeiServicesTablePointerLibConstructor (
723 IN EFI_FFS_FILE_HEADER *FfsHeader,
724 IN EFI_PEI_SERVICES **PeiServices
725 );
726 #endif
727
728 #ifdef __EDKII_GLUE_DXE_SMBUS_LIB__
729 EFI_STATUS
730 EFIAPI
731 SmbusLibConstructor (
732 IN EFI_HANDLE ImageHandle,
733 IN EFI_SYSTEM_TABLE *SystemTable
734 );
735 #endif
736
737 #ifdef __EDKII_GLUE_DXE_SERVICES_TABLE_LIB__
738 EFI_STATUS
739 DxeServicesTableLibConstructor (
740 IN EFI_HANDLE ImageHandle,
741 IN EFI_SYSTEM_TABLE *SystemTable
742 );
743 #endif
744
745 #ifdef __EDKII_GLUE_EDK_DXE_SAL_LIB__
746 EFI_STATUS
747 EFIAPI
748 DxeSalLibConstructor (
749 IN EFI_HANDLE ImageHandle,
750 IN EFI_SYSTEM_TABLE *SystemTable
751 );
752 #endif
753
754 //
755 // EdkII Glue Library Destructors:
756 // NOTE: the destructors must be called according to dependency order
757 //
758 // UefiDriverModelLibDestructor UefiDriverModelLibDestructor()
759 // EdkDxeRuntimeDriverLib RuntimeDriverLibDeconstruct()
760 //
761 #ifdef __EDKII_GLUE_UEFI_DRIVER_MODEL_LIB__
762 EFI_STATUS
763 UefiDriverModelLibDestructor (
764 IN EFI_HANDLE ImageHandle,
765 IN EFI_SYSTEM_TABLE *SystemTable
766 );
767 #endif
768
769 #ifdef __EDKII_GLUE_EDK_DXE_RUNTIME_DRIVER_LIB__
770 EFI_STATUS
771 RuntimeDriverLibDeconstruct (
772 IN EFI_HANDLE ImageHandle,
773 IN EFI_SYSTEM_TABLE *SystemTable
774 );
775 #endif
776
777 #endif