BaseTools: Fix the bug that PcdValueFromComm is not set

the bug is PcdValueFromComm is not set, but the Pcd have been override
by the command line option.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
This commit is contained in:
Yonghong Zhu 2018-10-19 15:25:39 +08:00
parent e7ac09b957
commit c3d0f526c0
1 changed files with 1 additions and 0 deletions

View File

@ -1067,6 +1067,7 @@ class DscBuildData(PlatformBuildClassObject):
PcdItem = BuildData.Pcds[key]
if (TokenSpaceGuidCName, TokenCName) == (PcdItem.TokenSpaceGuidCName, PcdItem.TokenCName) and FieldName =="":
PcdItem.DefaultValue = pcdvalue
PcdItem.PcdValueFromComm = pcdvalue
#In command line, the latter full assign value in commandLine should override the former field assign value.
#For example, --pcd Token.pcd.field="" --pcd Token.pcd=H"{}"
delete_assign = []