]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/AutoGen/AutoGen.py
BaseTools: Fix a bug for BOOLEAN type value in Asbuilt inf
[mirror_edk2.git] / BaseTools / Source / Python / AutoGen / AutoGen.py
index e1bdef09ca32dec12738da647e4747f5d963b0ea..8075afc91d643c1ce1d3fe9dabc2924e244124b8 100644 (file)
@@ -3925,6 +3925,13 @@ class ModuleAutoGen(AutoGen):
                 else:\r
                     continue\r
                 PcdValue = ''\r
                 else:\r
                     continue\r
                 PcdValue = ''\r
+                if Pcd.DatumType == 'BOOLEAN':\r
+                    BoolValue = Pcd.DefaultValue.upper()\r
+                    if BoolValue == 'TRUE':\r
+                        Pcd.DefaultValue = '1'\r
+                    elif BoolValue == 'FALSE':\r
+                        Pcd.DefaultValue = '0'\r
+\r
                 if Pcd.DatumType != 'VOID*':\r
                     HexFormat = '0x%02x'\r
                     if Pcd.DatumType == 'UINT16':\r
                 if Pcd.DatumType != 'VOID*':\r
                     HexFormat = '0x%02x'\r
                     if Pcd.DatumType == 'UINT16':\r