BaseTools-Source: Update displayed version information

Standardize the --version and --help text command-line options

Updated tools to correctly display the Build number when using command-line
option --version and exit successfully after termination.
Ecc was also updated to print informational messages after the options are
parsed.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Larry Hauch <larry.hauch@intel.com>
Reviewed-by: Erik Bjorge <erik.c.bjorge@intel.com>
This commit is contained in:
edk2 dev
2016-02-16 10:47:30 +08:00
committed by Yonghong Zhu
parent d92eaabefb
commit fbf2338143
11 changed files with 65 additions and 59 deletions

View File

@ -2,7 +2,7 @@
#
# This file is the main entry for UPT
#
# Copyright (c) 2011 - 2015, Intel Corporation. All rights reserved.<BR>
# Copyright (c) 2011 - 2016, 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
@ -99,7 +99,7 @@ def SetLogLevel(Opt):
def Main():
Logger.Initialize()
Parser = OptionParser(version=(MSG_VERSION + ' ' + gBUILD_VERSION), description=MSG_DESCRIPTION,
Parser = OptionParser(version=(MSG_VERSION + ' Build ' + gBUILD_VERSION), description=MSG_DESCRIPTION,
prog="UPT.exe", usage=MSG_USAGE)
Parser.add_option("-d", "--debug", action="store", type="int", dest="debug_level", help=ST.HLP_PRINT_DEBUG_INFO)