From nobody Sun May 19 20:13:05 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+46536+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+46536+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1566983845; cv=none; d=zoho.com; s=zohoarc; b=BacqnEd+jSTvCUQS6pdiGHce0BYExwSE0b55K072Umvt9Dx2UxxOqpf02k4buq/KY3N6FDxgdLHpdzgCv5dGRxSKKN7AfXVYOCbJ2KtyozCM5xyOn3I/enFdpuAoKPByHSVWRiPLUl7QOyYZpTeS4u1KiXApIPIHhhb6jmnkAGY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1566983845; h=Content-Transfer-Encoding:Cc:Date:From:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Sender:Subject:To:ARC-Authentication-Results; bh=jY4SxPnBw/vth+A8ykY0mLr8GQfG+8/GTbfl9JmJJZU=; b=fKzBv1jdoFf1XlS7cRI2itgM/bHioKM0LwOGTzB4xs0p3VRM0LSiwF7swezTvgVeO78YE1IipZRnWQMT/Q2gmbt28kt5WM/2I3wFTKFLr6ghmiEA3xHU4S7QOS87z1x/TLgTQkPV9M/CScTkrXzJoKlOK2znULY39TfcBCVKXRw= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+46536+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1566983845195228.92585469780533; Wed, 28 Aug 2019 02:17:25 -0700 (PDT) Return-Path: X-Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by groups.io with SMTP; Wed, 28 Aug 2019 02:17:23 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Aug 2019 02:17:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,440,1559545200"; d="scan'208";a="185564375" X-Received: from shwdepsi1121.ccr.corp.intel.com ([10.239.158.47]) by orsmga006.jf.intel.com with ESMTP; 28 Aug 2019 02:17:22 -0700 From: "Bob Feng" To: devel@edk2.groups.io Cc: Liming Gao , Bob Feng Subject: [edk2-devel] [Patch][edk2-stable201908] BaseTools: Fixed regression issue for building !x86 builds Date: Wed, 28 Aug 2019 17:17:10 +0800 Message-Id: <20190828091710.22372-1-bob.c.feng@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,bob.c.feng@intel.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1566983844; bh=P5Xflwa0LgGQKI3tKKcHxDUykcWCFFcEG4WUYVDhevE=; h=Cc:Date:From:Reply-To:Subject:To; b=nLOMgldCiJUWigDKZ8d1ZrP92MYVACNNHMRy1mPsYDCa2HorR8leaAmklY4hoChKZf7 s7HVClQbYAOuT7uddx8UQEGDcQ7k1TGVSUZSNQD9qQvDoMnBMUS44QMuN0A5JBqUj6m9X vrkg3V0hcBJHnbL56tvfq9mk1kwiHsPXiWg= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2134 This patch is to fix a build tool regression issue which was introduced by commit e8449e1d8e. In commit e8449e1d8e, build tool check the pcd before filter out the irrelevant library instance. The logic of evaluating the priority of the library class resolutions was not changed. Cc: Liming Gao Signed-off-by: Bob Feng Acked-by: Leif Lindholm Acked-by: Michael D Kinney Tested-by: Leif Lindholm Tested-by: Michael D Kinney --- .../Source/Python/Workspace/InfBuildData.py | 29 ++++++++++--------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/BaseTools/Source/Python/Workspace/InfBuildData.py b/BaseTools/= Source/Python/Workspace/InfBuildData.py index e63246b03b..7675b0ea00 100644 --- a/BaseTools/Source/Python/Workspace/InfBuildData.py +++ b/BaseTools/Source/Python/Workspace/InfBuildData.py @@ -154,12 +154,11 @@ class InfBuildData(ModuleBuildClassObject): self._PcdComments =3D None self._BuildOptions =3D None self._DependencyFileList =3D None self.LibInstances =3D [] self.ReferenceModules =3D set() - self.Guids - self.Pcds + def SetReferenceModule(self,Module): self.ReferenceModules.add(Module) return self =20 ## XXX[key] =3D value @@ -654,10 +653,24 @@ class InfBuildData(ModuleBuildClassObject): "Value of Guid [%s] is not found under [Gu= ids] section in" % CName, ExtraData=3DPackageList, File=3Dself.MetaF= ile, Line=3DRecord[-1]) RetVal[CName] =3D Value CommentRecords =3D self._RawData[MODEL_META_DATA_COMMENT, self= ._Arch, self._Platform, Record[5]] self._GuidComments[CName] =3D [a[0] for a in CommentRecords] + + for Type in [MODEL_PCD_FIXED_AT_BUILD,MODEL_PCD_PATCHABLE_IN_MODUL= E,MODEL_PCD_FEATURE_FLAG,MODEL_PCD_DYNAMIC,MODEL_PCD_DYNAMIC_EX]: + RecordList =3D self._RawData[Type, self._Arch, self._Platform] + for TokenSpaceGuid, _, _, _, _, _, LineNo in RecordList: + # get the guid value + if TokenSpaceGuid not in RetVal: + Value =3D GuidValue(TokenSpaceGuid, self.Packages, sel= f.MetaFile.Path) + if Value is None: + PackageList =3D "\n\t".join(str(P) for P in self.P= ackages) + EdkLogger.error('build', RESOURCE_NOT_AVAILABLE, + "Value of Guid [%s] is not found u= nder [Guids] section in" % TokenSpaceGuid, + ExtraData=3DPackageList, File=3Dse= lf.MetaFile, Line=3DLineNo) + RetVal[TokenSpaceGuid] =3D Value + self._GuidsUsedByPcd[TokenSpaceGuid] =3D Value return RetVal =20 ## Retrieve include paths necessary for this module (for Edk.x style o= f modules) @cached_property def Includes(self): @@ -856,11 +869,11 @@ class InfBuildData(ModuleBuildClassObject): if file_name.upper().endswith("DEC"): pkg =3D os.path.join(TopDir,file_name) return pkg @cached_class_function def GetGuidsUsedByPcd(self): - self.Pcds + self.Guid return self._GuidsUsedByPcd =20 ## Retrieve PCD for given type def _GetPcd(self, Type): Pcds =3D OrderedDict() @@ -868,20 +881,10 @@ class InfBuildData(ModuleBuildClassObject): PcdList =3D [] RecordList =3D self._RawData[Type, self._Arch, self._Platform] for TokenSpaceGuid, PcdCName, Setting, Arch, Platform, Id, LineNo = in RecordList: PcdDict[Arch, Platform, PcdCName, TokenSpaceGuid] =3D (Setting= , LineNo) PcdList.append((PcdCName, TokenSpaceGuid)) - # get the guid value - if TokenSpaceGuid not in self.Guids: - Value =3D GuidValue(TokenSpaceGuid, self.Packages, self.Me= taFile.Path) - if Value is None: - PackageList =3D "\n\t".join(str(P) for P in self.Packa= ges) - EdkLogger.error('build', RESOURCE_NOT_AVAILABLE, - "Value of Guid [%s] is not found under= [Guids] section in" % TokenSpaceGuid, - ExtraData=3DPackageList, File=3Dself.M= etaFile, Line=3DLineNo) - self.Guids[TokenSpaceGuid] =3D Value - self._GuidsUsedByPcd[TokenSpaceGuid] =3D Value CommentRecords =3D self._RawData[MODEL_META_DATA_COMMENT, self= ._Arch, self._Platform, Id] Comments =3D [] for CmtRec in CommentRecords: Comments.append(CmtRec[0]) self._PcdComments[TokenSpaceGuid, PcdCName] =3D Comments --=20 2.20.1.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#46536): https://edk2.groups.io/g/devel/message/46536 Mute This Topic: https://groups.io/mt/33055286/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-