## @file
# This file contained the parser for [Binaries] sections in INF file
#
# Copyright (c) 2011, 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
# distribution. The full text of the license may be found at
#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
'''
InfBinarySectionParser
'''
##
# Import Modules
#
## InfBinaryParser
#
#
#
# Macro defined in this section
#
SectionMacros = {}
ValueList = []
#
# For UI (UI, SEC_UI, UNI_UI) binaries
# One and only one UI section can be included
#
UiBinaryList = []
#
# For Version (VER, SEC_VER, UNI_VER).
# One and only one VER section on be included
#
VerBinaryList = []
#
# For other common type binaries
#
ComBinaryList = []
HeaderComments = []
LineComment = None
AllSectionContent = ''
#
# Parse section content
#
for Line in SectionString:
continue
#
# Found Header Comments
#
#
# Last line is comments, and this line go on.
#
if StillCommentFalg:
continue
#
# First time encounter comment
#
else:
#
# Clear original data
#
HeaderComments = []
continue
else:
LineCommentContent = ''
for Item in HeaderComments:
#
# Find Tail comment.
#
if LineComment == None:
#
# Find Macro
#
if MacroDef[0] != None:
LineComment = None
HeaderComments = []
continue
#
# Replace with Local section Macro and [Defines] section Macro.
#
#
#
2)
NewValueList = []
#
#
2)
NewValueList = []
else:
4)
NewValueList = []
ValueList = []
LineComment = None
TailComments = ''
HeaderComments = []
continue
#
# Current section archs
#
ArchList = []
ArchList):