# This module contains the functionality to generate build report after\r
# build all target completes successfully.\r
#\r
-# Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
## Tags for MaxLength of line in report\r
gLineMaxLength = 120\r
\r
+## Tags for end of line in report\r
+gEndOfLine = "\r\n"\r
+\r
## Tags for section start, end and separator\r
gSectionStart = ">" + "=" * (gLineMaxLength-2) + "<"\r
gSectionEnd = "<" + "=" * (gLineMaxLength-2) + ">" + "\n"\r
'Dynamic' : ('DYN', 'Dynamic'),\r
'DynamicHii' : ('DYNHII', 'Dynamic'),\r
'DynamicVpd' : ('DYNVPD', 'Dynamic'),\r
- 'DynamicEx' : ('DEX', 'Dynamic'),\r
- 'DynamicExHii' : ('DEXHII', 'Dynamic'),\r
- 'DynamicExVpd' : ('DEXVPD', 'Dynamic'),\r
+ 'DynamicEx' : ('DEX', 'DynamicEx'),\r
+ 'DynamicExHii' : ('DEXHII', 'DynamicEx'),\r
+ 'DynamicExVpd' : ('DEXVPD', 'DynamicEx'),\r
}\r
\r
## The look up table to map module type to driver type\r
def FileWrite(File, String, Wrapper=False):\r
if Wrapper:\r
String = textwrap.fill(String, 120)\r
- File.write(String + "\r\n")\r
+ File.write(String + gEndOfLine)\r
\r
##\r
# Find all the header file that the module source directly includes.\r
NewContentList.append(Line)\r
for NewLine in NewContentList:\r
NewContent += NewLine + TAB_LINE_BREAK\r
+ \r
+ NewContent = NewContent.replace(TAB_LINE_BREAK, gEndOfLine).replace('\r\r\n', gEndOfLine)\r
return NewContent\r
\r
\r
Statement = gOpCodeList[struct.unpack("B", OpCode)[0]]\r
if Statement in ["BEFORE", "AFTER", "PUSH"]:\r
GuidValue = "%08X-%04X-%04X-%02X%02X-%02X%02X%02X%02X%02X%02X" % \\r
- struct.unpack("LHHBBBBBBBB", DepexFile.read(16))\r
+ struct.unpack("=LHHBBBBBBBB", DepexFile.read(16))\r
GuidString = self._GuidDb.get(GuidValue, GuidValue)\r
Statement = "%s %s" % (Statement, GuidString)\r
DepexStatement.append(Statement)\r
# Collect PCDs defined in DSC common section\r
#\r
self.DscPcdDefault = {}\r
- for Platform in Wa.BuildDatabase.WorkspaceDb.PlatformList:\r
+ for Arch in Wa.ArchList:\r
+ Platform = Wa.BuildDatabase[Wa.MetaFile, Arch, Wa.BuildTarget, Wa.ToolChain]\r
for (TokenCName, TokenSpaceGuidCName) in Platform.Pcds:\r
DscDefaultValue = Platform.Pcds[(TokenCName, TokenSpaceGuidCName)].DefaultValue\r
if DscDefaultValue:\r