diff options
author | Yonghong Zhu <yonghong.zhu@intel.com> | 2017-07-27 11:20:26 +0800 |
---|---|---|
committer | Yonghong Zhu <yonghong.zhu@intel.com> | 2017-08-01 10:44:55 +0800 |
commit | c65df5d9a14331d2b6d583359f1cf88c3b710d34 (patch) | |
tree | 9d618d5957b89a808fd8004411d663c4059ae1cb /BaseTools/Source/Python/build | |
parent | fff2623cc2a5e3d85db201a4cf1ca8c595e20075 (diff) | |
download | edk2-c65df5d9a14331d2b6d583359f1cf88c3b710d34.tar.gz edk2-c65df5d9a14331d2b6d583359f1cf88c3b710d34.tar.bz2 edk2-c65df5d9a14331d2b6d583359f1cf88c3b710d34.zip |
BaseTools: Fix the bug to correctly check Pcd type that in FDF file
We set Pcd value in FDF and used this Pcd as PatchableInModule type in
module, it cause build report generate failure. because we incorrectly
set the Pcd type during check whether the Pcd is used.
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/build')
-rw-r--r-- | BaseTools/Source/Python/build/BuildReport.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/BaseTools/Source/Python/build/BuildReport.py b/BaseTools/Source/Python/build/BuildReport.py index a1ee43aa26..a7cbb6a98c 100644 --- a/BaseTools/Source/Python/build/BuildReport.py +++ b/BaseTools/Source/Python/build/BuildReport.py @@ -738,6 +738,13 @@ class PcdReport(object): for item in Pa.Platform.Pcds:
Pcd = Pa.Platform.Pcds[item]
if not Pcd.Type:
+ # check the Pcd in FDF file, whether it is used in module first
+ for T in ["FixedAtBuild", "PatchableInModule", "FeatureFlag", "Dynamic", "DynamicEx"]:
+ PcdList = self.AllPcds.setdefault(Pcd.TokenSpaceGuidCName, {}).setdefault(T, [])
+ if Pcd in PcdList:
+ Pcd.Type = T
+ break
+ if not Pcd.Type:
PcdTypeFlag = False
for package in Pa.PackageList:
for T in ["FixedAtBuild", "PatchableInModule", "FeatureFlag", "Dynamic", "DynamicEx"]:
|