diff options
author | Hess Chen <hesheng.chen@intel.com> | 2016-07-29 10:30:56 +0800 |
---|---|---|
committer | Yonghong Zhu <yonghong.zhu@intel.com> | 2016-08-03 10:49:31 +0800 |
commit | 645a51287e9519eb4c6d27b4e4f11d0556a624e8 (patch) | |
tree | c45139eb17cd0bc7ce985ebd4aa40aa28d9c3258 /BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py | |
parent | 6cf9903481f07859cb0013598d2d13309d4e4644 (diff) | |
download | edk2-platforms-645a51287e9519eb4c6d27b4e4f11d0556a624e8.tar.xz |
BaseTool/Upt: Add support for Private
Support new syntax in package DEC file as below:
[Includes.Common.Private]
[Ppis.Common.Private]
[Guids.Common.Private]
[Protocols.Common.Private]
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hess Chen <hesheng.chen@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py')
-rw-r--r-- | BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py b/BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py index 11b0359176..436dc90e6d 100644 --- a/BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py +++ b/BaseTools/Source/Python/UPT/PomAdapter/DecPomAlignment.py @@ -1,7 +1,7 @@ ## @file DecPomAlignment.py
# This file contained the adapter for convert INF parser object to POM Object
#
-# Copyright (c) 2011 - 2014, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2011 - 2016, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials are licensed and made available
# under the terms and conditions of the BSD License which accompanies this
@@ -63,6 +63,7 @@ from Library.DataType import TAB_STR_TOKENHELP from Library.DataType import TAB_STR_TOKENERR
from Library.DataType import TAB_HEX_START
from Library.DataType import TAB_SPLIT
+import Library.DataType as DT
from Library.CommentParsing import ParseHeaderCommentSection
from Library.CommentParsing import ParseGenericComment
from Library.CommentParsing import ParseDecPcdGenericComment
@@ -221,6 +222,14 @@ class DecPomAlignment(PackageObject): self.SetUserExtensionList(
self.GetUserExtensionList() + [UserExtension]
)
+
+ # Add Private sections to UserExtension
+ if self.DecParser.GetPrivateSections():
+ PrivateUserExtension = UserExtensionObject()
+ PrivateUserExtension.SetStatement(self.DecParser.GetPrivateSections())
+ PrivateUserExtension.SetIdentifier(DT.TAB_PRIVATE)
+ PrivateUserExtension.SetUserID(DT.TAB_INTEL)
+ self.SetUserExtensionList(self.GetUserExtensionList() + [PrivateUserExtension])
## Generate miscellaneous files on DEC file
#
|