Sync EDKII BaseTools to BaseTools project r1971

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10502 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
lgao4
2010-05-18 05:04:32 +00:00
parent 3dc8585e0a
commit 40d841f6a8
417 changed files with 3829 additions and 2563 deletions

View File

@ -1,8 +1,8 @@
## @file
# Generate AutoGen.h, AutoGen.c and *.depex files
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -1953,8 +1953,10 @@ class ModuleAutoGen(AutoGen):
return
for ModuleType in self.DepexList:
if len(self.DepexList[ModuleType]) == 0:
# Ignore empty [depex] section or [depex] section for "USER_DEFINED" module
if len(self.DepexList[ModuleType]) == 0 or ModuleType == "USER_DEFINED":
continue
Dpx = GenDepex.DependencyExpression(self.DepexList[ModuleType], ModuleType, True)
DpxFile = gAutoGenDepexFileName % {"module_name" : self.Name}

View File

@ -1,8 +1,8 @@
## @file
# The engine for building files
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Routines for generating AutoGen.h and AutoGen.c
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to generate DEPEX file for module's dependency expression
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Create makefile for MS nmake and GNU make
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,5 +1,5 @@
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,5 +1,5 @@
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -15,6 +15,7 @@
# Import Modules
#
import os, codecs, re
import distutils.util
import Common.EdkLogger as EdkLogger
from Common.BuildToolError import *
from Common.String import GetLineNo
@ -125,6 +126,8 @@ def GetLanguageCode(LangName, IsCompatibleMode, File):
else:
EdkLogger.error("Unicode File Parser", FORMAT_INVALID, "Invalid ISO 639-2 language code : %s" % LangName, File)
if (LangName[0] == 'X' or LangName[0] == 'x') and LangName[1] == '-':
return LangName
if length == 2:
if LangName.isalpha():
return LangName
@ -193,20 +196,20 @@ class UniFileClassObject(object):
# Get Language definition
#
def GetLangDef(self, File, Line):
Lang = Line.split(u"//")[0].split()
Lang = distutils.util.split_quoted((Line.split(u"//")[0]))
if len(Lang) != 3:
try:
FileIn = codecs.open(File, mode='rb', encoding='utf-16').read()
FileIn = codecs.open(File.Path, mode='rb', encoding='utf-16').read()
except UnicodeError, X:
EdkLogger.error("build", FILE_READ_FAILURE, "File read failure: %s" % str(X), ExtraData=File);
except:
EdkLogger.error("build", FILE_OPEN_FAILURE, ExtraData=File);
LineNo = GetLineNo(FileIn, Line, False)
EdkLogger.error("Unicode File Parser", PARSER_ERROR, "Wrong language definition",
ExtraData="""%s\n\t*Correct format is like '#langdef eng "English"'""" % Line, File = File, Line = LineNo)
ExtraData="""%s\n\t*Correct format is like '#langdef en-US "English"'""" % Line, File = File, Line = LineNo)
else:
LangName = GetLanguageCode(Lang[1], self.IsCompatibleMode, self.File)
LangPrintName = Lang[2][1:-1]
LangPrintName = Lang[2]
IsLangInDef = False
for Item in self.LanguageDef:

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Standardized Error Hanlding infrastructures.
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common static strings used by INF/DEC/DSC files
#
# Copyright (c) 2007 ~ 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to create a database used by ECC tool
#
# Copyright (c) 2007 ~ 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of DEC file
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of DEC file in light mode
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Define a dictionary structure
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of DSC file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This is the base class for applications that operate on an EDK II Workspace
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of the build database
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file implements the log mechanism for Python tools.
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of FDF file
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# parse FDF file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common static strings used by INF/DEC/DSC files
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define the identification of INF/DEC/DSC files
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of INF file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of INF file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Contains several utilitities shared by migration tools.
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Common routines used by all tools
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php
@ -1322,7 +1322,12 @@ class PathClass(object):
RealFile, RealRoot = RealPath2(self.File, self.Root, self.AlterRoot)
if not RealRoot and not RealFile:
return FILE_NOT_FOUND, self.File
RealFile = self.File
if self.AlterRoot:
RealFile = os.path.join(self.AlterRoot, self.File)
elif self.Root:
RealFile = os.path.join(self.Root, self.File)
return FILE_NOT_FOUND, os.path.join(self.AlterRoot, RealFile)
ErrorCode = 0
ErrorInfo = ''

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common parsing related functions used in parsing INF/DEC/DSC process
#
# Copyright (c) 2008 ~ 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common string related functions used in parsing process
#
# Copyright (c) 2007 ~ 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of Target.txt file
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define each component of tools_def.txt file
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to parse a xml file of .PKG file
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -2,8 +2,8 @@
# This is an XML API that uses a syntax similar to XPath, but it is written in
# standard python so that no extra python packages are required to use it.
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common items of class object
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define class for data sturcture used in ECC
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define a class object to describe a distribution package
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# classes represent data in FDF
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define a class object to describe a module
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define a class object to describe a package
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define a class object to describe a platform
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
/* @file
This file is used to be the grammar file of ECC tool
Copyright (c) 2009 - 2010, Intel Corporation
All rights reserved. This program and the accompanying materials
Copyright (c) 2009 - 2010, 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
http://opensource.org/licenses/bsd-license.php

View File

@ -10,7 +10,7 @@ from antlr3.compat import set, frozenset
# This file is generated by running:
# java org.antlr.Tool C.g
#
# Copyright (c) 2009 - 2010, Intel Corporation All rights reserved.
# Copyright (c) 2009 - 2010, 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

View File

@ -10,7 +10,7 @@ from antlr3.compat import set, frozenset
# This file is generated by running:
# java org.antlr.Tool C.g
#
# Copyright (c) 2009 - 2010, Intel Corporation All rights reserved.
# Copyright (c) 2009 - 2010, 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

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define checkpoints used by ECC tool
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -341,9 +341,19 @@ class Check(object):
for Dirpath, Dirnames, Filenames in self.WalkTree():
for F in Filenames:
if os.path.splitext(F)[1] in ('.h', '.c'):
Ext = os.path.splitext(F)[1]
if Ext in ('.h', '.c'):
FullName = os.path.join(Dirpath, F)
MsgList = c.CheckFileHeaderDoxygenComments(FullName)
elif Ext in ('.inf', '.dec', '.dsc', '.fdf'):
FullName = os.path.join(Dirpath, F)
if not open(FullName).read().startswith('## @file'):
SqlStatement = """ select ID from File where FullPath like '%s'""" % FullName
ResultSet = EccGlobalData.gDb.TblFile.Exec(SqlStatement)
for Result in ResultSet:
Msg = 'INF/DEC/DSC/FDF file header comment should begin with ""## @file""'
EccGlobalData.gDb.TblReport.Insert(ERROR_DOXYGEN_CHECK_FILE_HEADER, Msg, "File", Result[0])
# Check whether the function headers are followed Doxygen special documentation blocks in section 2.3.5
def DoxygenCheckFunctionHeader(self):
@ -399,6 +409,7 @@ class Check(object):
self.MetaDataFileCheckGuidDuplicate()
self.MetaDataFileCheckModuleFileNoUse()
self.MetaDataFileCheckPcdType()
self.MetaDataFileCheckModuleFileGuidDuplication()
# Check whether each file defined in meta-data exists
def MetaDataFileCheckPathName(self):
@ -692,6 +703,38 @@ class Check(object):
#ERROR_META_DATA_FILE_CHECK_PCD_TYPE
pass
# Internal worker function to get the INF workspace relative path from FileID
def GetInfFilePathFromID(self, FileID):
Table = EccGlobalData.gDb.TblFile
SqlCommand = """select A.FullPath from %s as A where A.ID = %s""" % (Table.Table, FileID)
RecordSet = Table.Exec(SqlCommand)
Path = ""
for Record in RecordSet:
Path = Record[0].replace(EccGlobalData.gWorkspace, '')
if Path.startswith('\\') or Path.startswith('/'):
Path = Path[1:]
return Path
# Check whether two module INFs under one workspace has the same FILE_GUID value
def MetaDataFileCheckModuleFileGuidDuplication(self):
if EccGlobalData.gConfig.MetaDataFileCheckModuleFileGuidDuplication == '1' or EccGlobalData.gConfig.MetaDataFileCheckAll == '1' or EccGlobalData.gConfig.CheckAll == '1':
EdkLogger.quiet("Checking for pcd type in c code function usage ...")
Table = EccGlobalData.gDb.TblInf
SqlCommand = """
select A.ID, A.Value2, A.BelongsToFile, B.BelongsToFile from %s as A, %s as B
where A.Value1 = 'FILE_GUID' and B.Value1 = 'FILE_GUID' and
A.Value2 = B.Value2 and A.ID <> B.ID group by A.ID
""" % (Table.Table, Table.Table)
RecordSet = Table.Exec(SqlCommand)
for Record in RecordSet:
InfPath1 = self.GetInfFilePathFromID(Record[2])
InfPath2 = self.GetInfFilePathFromID(Record[3])
if InfPath1 and InfPath2:
if not EccGlobalData.gException.IsException(ERROR_META_DATA_FILE_CHECK_MODULE_FILE_GUID_DUPLICATION, InfPath1):
Msg = "The FILE_GUID of INF file [%s] is duplicated with that of %s" % (InfPath1, InfPath2)
EccGlobalData.gDb.TblReport.Insert(ERROR_META_DATA_FILE_CHECK_MODULE_FILE_GUID_DUPLICATION, OtherMsg = Msg, BelongsToTable = Table.Table, BelongsToItem = Record[0])
# Check whether these is duplicate Guid/Ppi/Protocol name
def CheckGuidProtocolPpi(self, ErrorID, Model, Table):
Name = ''

View File

@ -1,9 +1,9 @@
## @file
# fragments of source file
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# preprocess source file
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define class Configuration
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php
@ -222,7 +222,9 @@ class Configuration(object):
self.MetaDataFileCheckModuleFileNoUse = 1
# Check whether the PCD is correctly used in C function via its type
self.MetaDataFileCheckPcdType = 1
# Check whether there are FILE_GUID duplication among different INF files
self.MetaDataFileCheckModuleFileGuidDuplication = 1
#
# The check points in this section are reserved
#

View File

@ -1,8 +1,8 @@
## @file
# This file is used to create a database used by ECC tool
#
# Copyright (c) 2007 ~ 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to be the main entrance of ECC tool
#
# Copyright (c) 2009 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2009 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to save global datas used by ECC tool
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Standardized Error Hanlding infrastructures.
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -92,6 +92,7 @@ ERROR_META_DATA_FILE_CHECK_DUPLICATE_PROTOCOL = 10012
ERROR_META_DATA_FILE_CHECK_DUPLICATE_PPI = 10013
ERROR_META_DATA_FILE_CHECK_MODULE_FILE_NO_USE = 10014
ERROR_META_DATA_FILE_CHECK_PCD_TYPE = 10015
ERROR_META_DATA_FILE_CHECK_MODULE_FILE_GUID_DUPLICATION = 10016
ERROR_SPELLING_CHECK_ALL = 11000
@ -177,7 +178,7 @@ gEccErrorMessage = {
ERROR_META_DATA_FILE_CHECK_DUPLICATE_PPI : "Duplicate PPI found",
ERROR_META_DATA_FILE_CHECK_MODULE_FILE_NO_USE : "No used module files found",
ERROR_META_DATA_FILE_CHECK_PCD_TYPE : "Wrong C code function used for this kind of PCD",
ERROR_META_DATA_FILE_CHECK_MODULE_FILE_GUID_DUPLICATION : "Module file has FILE_GUID collision with other module file",
ERROR_SPELLING_CHECK_ALL : "",
}

View File

@ -1,8 +1,8 @@
## @file
# This file is used to parse exception items found by ECC tool
#
# Copyright (c) 2009, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2009, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# fragments of source file
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to define common parser functions for meta-data
#
# Copyright (c) 2008, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to be the warning class of ECC tool
#
# Copyright (c) 2009 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2009 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to be the c coding style checking of ECC tool
#
# Copyright (c) 2009 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2009 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -2,8 +2,8 @@
# This file is used to set configuration of ECC tool
# For the items listed below, 1 means valid, 0 means invalid
#
# Copyright (c) 2007, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -233,6 +233,8 @@ MetaDataFileCheckGuidDuplicate = 1
MetaDataFileCheckModuleFileNoUse = 1
# Check whether the PCD is correctly used in C function via its type
MetaDataFileCheckPcdType = 1
# Check whether there are FILE_GUID duplication among different INF files
MetaDataFileCheckModuleFileGuidDuplication = 1
#
# The check points in this section are reserved

View File

@ -1,8 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<ExceptionList xmlns="http://www.uefi.org/2008/2.1" xmlns:xsi="http:/www.w3.org/2001/XMLSchema-instance">
<Copyright>Copyright (c) 2009 - 2010, Intel Corporation.</Copyright>
<Copyright>Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.</Copyright>
<License>
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 distribution.
The full text of the license may be found at http://opensource.org/licenses/bsd-license.php

View File

@ -10,7 +10,7 @@ from antlr3.compat import set, frozenset
# This file is generated by running:
# java org.antlr.Tool C.g
#
# Copyright (c) 2009 - 2010, Intel Corporation All rights reserved.
# Copyright (c) 2009 - 2010, 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

View File

@ -10,7 +10,7 @@ from antlr3.compat import set, frozenset
# This file is generated by running:
# java org.antlr.Tool C.g
#
# Copyright (c) 2009 - 2010, Intel Corporation All rights reserved.
# Copyright (c) 2009 - 2010, 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

View File

@ -1,9 +1,9 @@
## @file
# fragments of source file
#
# Copyright (c) 2007 ~ 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# preprocess source file
#
# Copyright (c) 2007 ~ 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to create a database used by EOT tool
#
# Copyright (c) 2007 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to be the main entrance of EOT tool
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to save global datas
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Standardized Error Handling infrastructures.
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# fragments of source file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Parse FV image
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to parse INF file of EDK project
#
# Copyright (c) 2008 - 2010 Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -2,8 +2,8 @@
# This file is used to define common parsing related functions used in parsing
# Inf/Dsc/Makefile process
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php
@ -453,8 +453,7 @@ def SearchPpiCallFunction(Identifier, SourceFileID, SourceFileFullPath, ItemMode
if NewRecordSet:
NewRecord = NewRecordSet[0][0]
VariableValueList = NewRecord.split('},')
if len(VariableValueList) > Index:
VariableValue = VariableValueList[Index]
for VariableValue in VariableValueList[Index:]:
NewVariableValueList = VariableValue.split(',')
if len(NewVariableValueList) > 1:
NewVariableValue = NewVariableValueList[1].strip()

View File

@ -1,9 +1,9 @@
## @file
# Warning information of Eot
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# This file is used to create report for Eot tool
#
# Copyright (c) 2008 - 2010, Intel Corporation
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2008 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# preprocess source file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php
@ -353,9 +353,12 @@ def GetFunctionList():
def CreateCCodeDB(FileNameList):
FileObjList = []
ParseErrorFileList = []
ParsedFiles = {}
for FullName in FileNameList:
if os.path.splitext(FullName)[1] in ('.h', '.c'):
if FullName.lower() in ParsedFiles:
continue
ParsedFiles[FullName.lower()] = 1
EdkLogger.info("Parsing " + FullName)
model = FullName.endswith('c') and DataClass.MODEL_FILE_C or DataClass.MODEL_FILE_H
collector = CodeFragmentCollector.CodeFragmentCollector(FullName)

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -4,8 +4,8 @@
# This file is required to make Python interpreter treat the directory
# as containing package.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,8 +1,8 @@
## @file
# Windows makefile for Python tools build.
#
# Copyright (c) 2007 - 2010, Intel Corporation<BR>
# All rights reserved. This program and the accompanying materials
# Copyright (c) 2007 - 2010, 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process APRIORI file data and generate PEI/DXE APRIORI file
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# name value pair
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# generate capsule
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# generate capsule
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# VTF components
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process compress section generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process data section generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process depex section generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process rule section generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FD generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# parse FDF file
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FFS generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FFS generation from FILE statement
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FFS generation from INF statement
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FV generation
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process FV image section generation
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# generate flash image
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php
@ -35,6 +35,7 @@ import Common.GlobalData as GlobalData
from Common import EdkLogger
from Common.String import *
from Common.Misc import DirCache,PathClass
from Common.Misc import SaveFileOnChange
## Version and Copyright
versionNumber = "1.0"
@ -486,14 +487,15 @@ class GenFds :
def GenerateGuidXRefFile(BuildDb, ArchList):
GuidXRefFileName = os.path.join(GenFdsGlobalVariable.FvDir, "Guid.xref")
GuidXRefFile = open(GuidXRefFileName, "w+")
GuidXRefFile = StringIO.StringIO('')
for Arch in ArchList:
PlatformDataBase = BuildDb.BuildObject[GenFdsGlobalVariable.ActivePlatform, Arch]
for ModuleFile in PlatformDataBase.Modules:
Module = BuildDb.BuildObject[ModuleFile, Arch]
GuidXRefFile.write("%s %s\n" % (Module.Guid, Module.BaseName))
SaveFileOnChange(GuidXRefFileName, GuidXRefFile.getvalue(), False)
GuidXRefFile.close()
GenFdsGlobalVariable.InfLogger("\nGUID cross reference file saved to %s" % GuidXRefFileName)
GenFdsGlobalVariable.InfLogger("\nGUID cross reference file can be found at %s" % GuidXRefFileName)
##Define GenFd as static function
GenFd = staticmethod(GenFd)

View File

@ -1,9 +1,9 @@
## @file
# Global variables for GenFds
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process GUIDed section generation
#
# Copyright (c) 2007 - 2010, Intel Corporation
# Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process OptionROM generation from FILE statement
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

View File

@ -1,9 +1,9 @@
## @file
# process OptionROM generation from INF statement
#
# Copyright (c) 2007, Intel Corporation
# Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
#
# All rights reserved. This program and the accompanying materials
# 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
# http://opensource.org/licenses/bsd-license.php

Some files were not shown because too many files have changed in this diff Show More