X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=BaseTools%2FSource%2FPython%2FGenFds%2FDepexSection.py;h=8f78c0fad474fb38829160b94cd3331c4127dea1;hp=39678b23e96df52752caeedb2aa0e5cddcc036aa;hb=97fa0ee9b1cffbb4b97ee35365afa7afcf50e174;hpb=40d841f6a8f84e75409178e19e69b95e01bada0f
diff --git a/BaseTools/Source/Python/GenFds/DepexSection.py b/BaseTools/Source/Python/GenFds/DepexSection.py
index 39678b23e9..8f78c0fad4 100644
--- a/BaseTools/Source/Python/GenFds/DepexSection.py
+++ b/BaseTools/Source/Python/GenFds/DepexSection.py
@@ -1,7 +1,7 @@
## @file
# process depex section generation
#
-# Copyright (c) 2007, Intel Corporation. All rights reserved.
+# Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -19,12 +19,12 @@ import Section
from GenFdsGlobalVariable import GenFdsGlobalVariable
import subprocess
from Ffs import Ffs
-import os
+import Common.LongFilePathOs as os
from CommonDataClass.FdfClass import DepexSectionClassObject
from AutoGen.GenDepex import DependencyExpression
-import shutil
from Common import EdkLogger
from Common.BuildToolError import *
+from Common.Misc import PathClass
## generate data section
#
@@ -39,7 +39,22 @@ class DepexSection (DepexSectionClassObject):
def __FindGuidValue(self, CName):
for Arch in GenFdsGlobalVariable.ArchList:
- for PkgDb in GenFdsGlobalVariable.WorkSpace.PackageList:
+ PkgList = GenFdsGlobalVariable.WorkSpace.GetPackageList(GenFdsGlobalVariable.ActivePlatform,
+ Arch,
+ GenFdsGlobalVariable.TargetName,
+ GenFdsGlobalVariable.ToolChainTag)
+ for Inf in GenFdsGlobalVariable.FdfParser.Profile.InfList:
+ ModuleFile = PathClass(Inf, GenFdsGlobalVariable.WorkSpaceDir)
+ ModuleData = GenFdsGlobalVariable.WorkSpace.BuildObject[
+ ModuleFile,
+ Arch,
+ GenFdsGlobalVariable.TargetName,
+ GenFdsGlobalVariable.ToolChainTag
+ ]
+ for Pkg in ModuleData.Packages:
+ if Pkg not in PkgList:
+ PkgList.append(Pkg)
+ for PkgDb in PkgList:
if CName in PkgDb.Ppis:
return PkgDb.Ppis[CName]
if CName in PkgDb.Protocols: