|
From: <qh...@us...> - 2010-02-22 02:46:00
|
Revision: 1881
http://edk2-buildtools.svn.sourceforge.net/edk2-buildtools/?rev=1881&view=rev
Author: qhuang8
Date: 2010-02-22 02:45:51 +0000 (Mon, 22 Feb 2010)
Log Message:
-----------
Add debug logic to print trace entries for major logic of build report.
Modified Paths:
--------------
trunk/BaseTools/Source/Python/build/BuildReport.py
Modified: trunk/BaseTools/Source/Python/build/BuildReport.py
===================================================================
--- trunk/BaseTools/Source/Python/build/BuildReport.py 2010-02-21 10:42:23 UTC (rev 1880)
+++ trunk/BaseTools/Source/Python/build/BuildReport.py 2010-02-22 02:45:51 UTC (rev 1881)
@@ -20,6 +20,8 @@
import re
import platform
import textwrap
+import traceback
+import sys
from datetime import datetime
from Common import EdkLogger
from Common.Misc import GuidStructureByteArrayToGuidString
@@ -27,6 +29,7 @@
from Common.InfClassObject import gComponentType2ModuleType
from Common.BuildToolError import FILE_OPEN_FAILURE
from Common.BuildToolError import FILE_WRITE_FAILURE
+from Common.BuildToolError import CODE_ERROR
## Pattern to extract contents in EDK DXS files
@@ -1414,9 +1417,12 @@
try:
for Wa in self.ReportList:
PlatformReport(Wa, self.ReportType).GenerateReport(File, BuildDuration, self.ReportType)
- EdkLogger.info("Report successfully saved to %s" % os.path.abspath(self.ReportFile))
+ EdkLogger.quiet("Report successfully saved to %s" % os.path.abspath(self.ReportFile))
except IOError:
EdkLogger.error(None, FILE_WRITE_FAILURE, ExtraData=self.ReportFile)
+ except:
+ EdkLogger.error("BuildReport", CODE_ERROR, "Unknown fatal error when generating build report", ExtraData=self.ReportFile)
+ EdkLogger.quiet("(Python %s on %s\n%s)" % (platform.python_version(), sys.platform, traceback.format_exc()))
File.close()
# This acts like the main() function for the script, unless it is 'import'ed into another script.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|