BaseTools: Refactor python raise statement

Make "raise" to be compatible with python3.

Contributed-under: TianoCore Contribution Agreement 1.1
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Signed-off-by: Gary Lin <glin@suse.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
This commit is contained in:
Gary Lin 2018-06-25 18:31:32 +08:00 committed by Yonghong Zhu
parent aaa4c651bf
commit df29fd130a
1 changed files with 2 additions and 2 deletions

View File

@ -507,8 +507,8 @@ class Builder:
f = open(logFile, "w")
f.write(output)
f.close()
raise Exception, 'Failed to %s %s\n' % (stage, module) + \
'See output log at %s' % self.config.Relative(logFile)
raise Exception('Failed to %s %s\n' % (stage, module) + \
'See output log at %s' % self.config.Relative(logFile))
else:
print('[done]')