BaseTools: Remove unused logic for EDKI
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1350 Remove EDK module type support from BaseTools python code. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Bob Feng <bob.c.feng@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
This commit is contained in:
@ -90,10 +90,7 @@ def GetDeclaredPcd(Platform, BuildDatabase, Arch, Target, Toolchain, additionalP
|
||||
# @retval: List of dependent libraries which are InfBuildData instances
|
||||
#
|
||||
def GetLiabraryInstances(Module, Platform, BuildDatabase, Arch, Target, Toolchain):
|
||||
if Module.AutoGenVersion >= 0x00010005:
|
||||
return GetModuleLibInstances(Module, Platform, BuildDatabase, Arch, Target, Toolchain)
|
||||
else:
|
||||
return _ResolveLibraryReference(Module, Platform)
|
||||
return GetModuleLibInstances(Module, Platform, BuildDatabase, Arch, Target, Toolchain)
|
||||
|
||||
def GetModuleLibInstances(Module, Platform, BuildDatabase, Arch, Target, Toolchain, FileName = '', EdkLogger = None):
|
||||
ModuleType = Module.ModuleType
|
||||
@ -255,27 +252,3 @@ def GetModuleLibInstances(Module, Platform, BuildDatabase, Arch, Target, Toolcha
|
||||
#
|
||||
SortedLibraryList.reverse()
|
||||
return SortedLibraryList
|
||||
|
||||
def _ResolveLibraryReference(Module, Platform):
|
||||
LibraryConsumerList = [Module]
|
||||
|
||||
# "CompilerStub" is a must for Edk modules
|
||||
if Module.Libraries:
|
||||
Module.Libraries.append("CompilerStub")
|
||||
LibraryList = []
|
||||
while len(LibraryConsumerList) > 0:
|
||||
M = LibraryConsumerList.pop()
|
||||
for LibraryName in M.Libraries:
|
||||
Library = Platform.LibraryClasses[LibraryName, ':dummy:']
|
||||
if Library is None:
|
||||
for Key in Platform.LibraryClasses.data:
|
||||
if LibraryName.upper() == Key.upper():
|
||||
Library = Platform.LibraryClasses[Key, ':dummy:']
|
||||
break
|
||||
if Library is None:
|
||||
continue
|
||||
|
||||
if Library not in LibraryList:
|
||||
LibraryList.append(Library)
|
||||
LibraryConsumerList.append(Library)
|
||||
return LibraryList
|
||||
|
Reference in New Issue
Block a user