X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=BaseTools%2FSource%2FPython%2FGenFds%2FDepexSection.py;h=8f78c0fad474fb38829160b94cd3331c4127dea1;hp=8650a73eb590fb96c5895f3bdf8b666f718692e8;hb=97fa0ee9b1cffbb4b97ee35365afa7afcf50e174;hpb=52302d4dee589a5df43a464420c9fe68ba83937d diff --git a/BaseTools/Source/Python/GenFds/DepexSection.py b/BaseTools/Source/Python/GenFds/DepexSection.py index 8650a73eb5..8f78c0fad4 100644 --- a/BaseTools/Source/Python/GenFds/DepexSection.py +++ b/BaseTools/Source/Python/GenFds/DepexSection.py @@ -1,9 +1,9 @@ ## @file # process depex section generation # -# Copyright (c) 2007, Intel Corporation +# Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.
# -# All rights reserved. This program and the accompanying materials +# This program and the accompanying materials # are licensed and made available under the terms and conditions of the BSD License # which accompanies this distribution. The full text of the license may be found at # http://opensource.org/licenses/bsd-license.php @@ -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: