From fbf2338143952da2c63241e51379504a15aa3ea9 Mon Sep 17 00:00:00 2001 From: edk2 dev Date: Tue, 16 Feb 2016 10:47:30 +0800 Subject: 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 Reviewed-by: Erik Bjorge --- BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c') diff --git a/BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c b/BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c index 31d697ec51..79618677f6 100644 --- a/BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c +++ b/BaseTools/Source/C/EfiLdrImage/EfiLdrImage.c @@ -6,7 +6,7 @@ FILE := EFILDR_HEADER + The order of EFILDR_IMAGE is same as the order of placing PeImageFileContent. -Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -51,8 +51,8 @@ typedef struct { // // Utility version information // -#define UTILITY_MAJOR_VERSION 0 -#define UTILITY_MINOR_VERSION 1 +#define UTILITY_MAJOR_VERSION 1 +#define UTILITY_MINOR_VERSION 0 void Version ( @@ -74,9 +74,8 @@ Returns: --*/ { - printf ("%s Version %d.%d %s\n", UTILITY_NAME, UTILITY_MAJOR_VERSION, UTILITY_MINOR_VERSION, __BUILD_VERSION); - printf ("Copyright (c) 1999-2014 Intel Corporation. All rights reserved.\n"); - printf ("\n The EfiLdrImage tool is used to combine PE files into EFILDR image with Efi loader header.\n"); + printf ("%s Version %d.%d Build %s\n", UTILITY_NAME, UTILITY_MAJOR_VERSION, UTILITY_MINOR_VERSION, __BUILD_VERSION); + exit (0); } VOID @@ -85,7 +84,9 @@ Usage ( ) { printf ("Usage: EfiLdrImage -o OutImage LoaderImage PeImage1 PeImage2 ... PeImageN\n"); - exit (1); + printf ("%s Version %d.%d Build %s\n", UTILITY_NAME, UTILITY_MAJOR_VERSION, UTILITY_MINOR_VERSION, __BUILD_VERSION); + printf ("Copyright (c) 1999-2016 Intel Corporation. All rights reserved.\n"); + printf ("\n The EfiLdrImage tool is used to combine PE files into EFILDR image with Efi loader header.\n"); } EFI_STATUS @@ -180,7 +181,7 @@ Returns: SetUtilityName (UTILITY_NAME); if (argc == 1) { - Usage(); + printf ("Usage: EfiLdrImage -o OutImage LoaderImage PeImage1 PeImage2 ... PeImageN\n"); return STATUS_ERROR; } -- cgit v1.2.3