mirror of https://github.com/acidanthera/audk.git
BaseTools: Build report should not be generated if build failed.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yingke Liu <yingke.d.liu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17679 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
a3251d8446
commit
09ae0f1113
|
@ -1965,6 +1965,7 @@ def Main():
|
||||||
EdkLogger.quiet(time.strftime("Build start time: %H:%M:%S, %b.%d %Y\n", time.localtime()));
|
EdkLogger.quiet(time.strftime("Build start time: %H:%M:%S, %b.%d %Y\n", time.localtime()));
|
||||||
ReturnCode = 0
|
ReturnCode = 0
|
||||||
MyBuild = None
|
MyBuild = None
|
||||||
|
BuildError = True
|
||||||
try:
|
try:
|
||||||
if len(Target) == 0:
|
if len(Target) == 0:
|
||||||
Target = "all"
|
Target = "all"
|
||||||
|
@ -2035,6 +2036,10 @@ def Main():
|
||||||
SqlCommand = """drop table IF EXISTS %s""" % TmpTableName
|
SqlCommand = """drop table IF EXISTS %s""" % TmpTableName
|
||||||
TmpTableDict[TmpTableName].execute(SqlCommand)
|
TmpTableDict[TmpTableName].execute(SqlCommand)
|
||||||
#MyBuild.DumpBuildData()
|
#MyBuild.DumpBuildData()
|
||||||
|
#
|
||||||
|
# All job done, no error found and no exception raised
|
||||||
|
#
|
||||||
|
BuildError = False
|
||||||
except FatalError, X:
|
except FatalError, X:
|
||||||
if MyBuild != None:
|
if MyBuild != None:
|
||||||
# for multi-thread build exits safely
|
# for multi-thread build exits safely
|
||||||
|
@ -2095,7 +2100,8 @@ def Main():
|
||||||
else:
|
else:
|
||||||
BuildDurationStr = time.strftime("%H:%M:%S", BuildDuration)
|
BuildDurationStr = time.strftime("%H:%M:%S", BuildDuration)
|
||||||
if MyBuild != None:
|
if MyBuild != None:
|
||||||
MyBuild.BuildReport.GenerateReport(BuildDurationStr)
|
if not BuildError:
|
||||||
|
MyBuild.BuildReport.GenerateReport(BuildDurationStr)
|
||||||
MyBuild.Db.Close()
|
MyBuild.Db.Close()
|
||||||
EdkLogger.SetLevel(EdkLogger.QUIET)
|
EdkLogger.SetLevel(EdkLogger.QUIET)
|
||||||
EdkLogger.quiet("\n- %s -" % Conclusion)
|
EdkLogger.quiet("\n- %s -" % Conclusion)
|
||||||
|
|
Loading…
Reference in New Issue