From 645a51287e9519eb4c6d27b4e4f11d0556a624e8 Mon Sep 17 00:00:00 2001 From: Hess Chen Date: Fri, 29 Jul 2016 10:30:56 +0800 Subject: 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 Reviewed-by: Yonghong Zhu --- BaseTools/Source/Python/UPT/GenMetaFile/GenDecFile.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'BaseTools/Source/Python/UPT/GenMetaFile') diff --git a/BaseTools/Source/Python/UPT/GenMetaFile/GenDecFile.py b/BaseTools/Source/Python/UPT/GenMetaFile/GenDecFile.py index f22363b3b9..31abd23ccd 100644 --- a/BaseTools/Source/Python/UPT/GenMetaFile/GenDecFile.py +++ b/BaseTools/Source/Python/UPT/GenMetaFile/GenDecFile.py @@ -2,7 +2,7 @@ # # This file contained the logical of transfer package object to DEC files. # -# Copyright (c) 2011 - 2014, Intel Corporation. All rights reserved.
+# Copyright (c) 2011 - 2016, Intel Corporation. All rights reserved.
# # 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_PCD_ERROR from Library.DataType import TAB_SECTION_START from Library.DataType import TAB_SECTION_END from Library.DataType import TAB_SPLIT +import Library.DataType as DT from Library.UniClassObject import FormatUniEntry def GenPcd(Package, Content): @@ -487,6 +488,12 @@ def PackageToDec(Package, DistHeader = None): if UserExtension.GetUserID() == TAB_BINARY_HEADER_USERID and \ UserExtension.GetIdentifier() == TAB_BINARY_HEADER_IDENTIFIER: continue + + # Generate Private Section first + if UserExtension.GetUserID() == DT.TAB_INTEL and UserExtension.GetIdentifier() == DT.TAB_PRIVATE: + Content += '\n' + UserExtension.GetStatement() + continue + Statement = UserExtension.GetStatement() if not Statement: continue -- cgit v1.2.3