|
From: <gi...@us...> - 2010-09-10 01:42:07
|
Revision: 2045
http://edk2-buildtools.svn.sourceforge.net/edk2-buildtools/?rev=2045&view=rev
Author: gikidy
Date: 2010-09-10 01:42:01 +0000 (Fri, 10 Sep 2010)
Log Message:
-----------
Fixed signature PCD value override in DSC file and give a warning message while signature pcd been used.
Modified Paths:
--------------
trunk/BaseTools/Source/Python/AutoGen/AutoGen.py
Modified: trunk/BaseTools/Source/Python/AutoGen/AutoGen.py
===================================================================
--- trunk/BaseTools/Source/Python/AutoGen/AutoGen.py 2010-09-08 03:30:30 UTC (rev 2044)
+++ trunk/BaseTools/Source/Python/AutoGen/AutoGen.py 2010-09-10 01:42:01 UTC (rev 2045)
@@ -544,9 +544,18 @@
DecPcdEntry = eachDec.Pcds[DecPcd]
if (DecPcdEntry.TokenSpaceGuidCName == DscPcdEntry.TokenSpaceGuidCName) and \
(DecPcdEntry.TokenCName == DscPcdEntry.TokenCName):
+ # Print warning message to let the developer make a determine.
+ EdkLogger.warn("build", "Unreferenced vpd pcd used!",
+ File=self.MetaFile, \
+ ExtraData = "PCD: %s.%s used in the DSC file %s is unreferenced." \
+ %(DscPcdEntry.TokenSpaceGuidCName, DscPcdEntry.TokenCName, self.Platform.MetaFile.Path))
+
DscPcdEntry.DatumType = DecPcdEntry.DatumType
DscPcdEntry.DefaultValue = DecPcdEntry.DefaultValue
- Sku.DefaultValue = DecPcdEntry.DefaultValue
+ # Only fix the value while no value provided in DSC file.
+ if (Sku.DefaultValue == "" or Sku.DefaultValue==None):
+ DscPcdEntry.SkuInfoList[DscPcdEntry.SkuInfoList.keys()[0]].DefaultValue = DecPcdEntry.DefaultValue
+
VpdFile.Add(DscPcdEntry, Sku.VpdOffset)
# if the offset of a VPD is *, then it need to be fixed up by third party tool.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|