diff options
author | Yonghong Zhu <yonghong.zhu@intel.com> | 2017-12-26 16:17:13 +0800 |
---|---|---|
committer | Yonghong Zhu <yonghong.zhu@intel.com> | 2017-12-27 14:43:27 +0800 |
commit | 726c501c2c9a1ef103fab7846e2d1a34506715d8 (patch) | |
tree | 51c6cb2ce0a1a49400d8ef2255327dd330b177f1 /BaseTools/Source/Python/AutoGen/GenC.py | |
parent | 68ba919f7858830cc764b46a00da7e7fdcd1f3ec (diff) | |
download | edk2-726c501c2c9a1ef103fab7846e2d1a34506715d8.tar.gz edk2-726c501c2c9a1ef103fab7846e2d1a34506715d8.tar.bz2 edk2-726c501c2c9a1ef103fab7846e2d1a34506715d8.zip |
BaseTools: Support PCD flexible values format
https://bugzilla.tianocore.org/show_bug.cgi?id=541
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com>
Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/AutoGen/GenC.py')
-rw-r--r-- | BaseTools/Source/Python/AutoGen/GenC.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/BaseTools/Source/Python/AutoGen/GenC.py b/BaseTools/Source/Python/AutoGen/GenC.py index 6b95cd47c2..3e98506cc8 100644 --- a/BaseTools/Source/Python/AutoGen/GenC.py +++ b/BaseTools/Source/Python/AutoGen/GenC.py @@ -1033,6 +1033,8 @@ def CreateModulePcdCode(Info, AutoGenC, AutoGenH, Pcd): if Pcd.DatumType in ['UINT64', 'UINT32', 'UINT16', 'UINT8']:
try:
+ if Value.upper().endswith('L'):
+ Value = Value[:-1]
if Value.upper().startswith('0X'):
ValueNumber = int (Value, 16)
else:
|