]> git.proxmox.com Git - mirror_edk2.git/blobdiff - EdkCompatibilityPkg/Sample/Tools/Source/EfiRom/EfiRom.c
Sync all bug fixes between EDK1.04 and EDK1.06 into EdkCompatibilityPkg.
[mirror_edk2.git] / EdkCompatibilityPkg / Sample / Tools / Source / EfiRom / EfiRom.c
index f5ab9ff234af3858e490081d9bc9f4c6e1bf0ac9..cf8efc86e1b4855b9e64416a7f4daec2d3f67afa 100644 (file)
@@ -1,7 +1,7 @@
 /*++\r
 \r
-Copyright (c) 2007, Intel Corporation                                                         \r
-All rights reserved. This program and the accompanying materials                          \r
+Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials                          \r
 are licensed and made available under the terms and conditions of the BSD License         \r
 which accompanies this distribution.  The full text of the license may be found at        \r
 http://opensource.org/licenses/bsd-license.php                                            \r
@@ -45,7 +45,8 @@ Abstract:
 //\r
 // Version of this utility\r
 //\r
-#define UTILITY_VERSION "v2.6"\r
+#define UTILITY_NAME    "EfiRom"\r
+#define UTILITY_VERSION "v2.7"\r
 \r
 //\r
 // Define some status return values\r
@@ -1311,39 +1312,42 @@ Returns:
 \r
 --*/\r
 {\r
-  int               Index;\r
-  static const char *Msg[] = {\r
-    "EfiRom "UTILITY_VERSION" - Intel EFI Make Option ROM utility",\r
-    "  Copyright (C), 1999 - 2002 Intel Coproration\n",\r
-    "  Create an option ROM image from a list of input files",\r
-    "  Usage: efirom {-p} [-v VendorId] [-d DeviceId] {-o OutFileName} ",\r
-    "                [-e|-b] [FileName(s)]",\r
-    "    where:",\r
-    "      VendorId       - required hex PCI Vendor ID for the device",\r
-    "      DeviceId       - required hex PCI Device ID for the device",\r
-    "      OutFileName    - optional output file name. Default is the first input",\r
-    "                       file name with a "DEFAULT_OUTPUT_EXTENSION" file extension",\r
-    "      FileNames      - input PE32 or binary file name(s)",\r
-    "      BinFileName    - input binary file name(s)",\r
-    "      -p             - for verbose output",\r
-    "      -l             - to not automatically set the LAST bit on the last file",\r
-    "      -b             - following FileNames are binary files",\r
-    "      -e             - following FileNames are EFI PE32 image files",\r
-    "      -ec            - following FileNames are EFI PE32 image files, and should",\r
-    "                       be compressed by this utility",\r
-    "      -cc ClassCode  - to use hex ClassCode in the PCI data structure header for",\r
-    "                       the following FileName",\r
-    "      -rev Revision  - to use hex Revision in the PCI data structure header for",\r
-    "                       the following FileName",\r
-    "      -dump          - to dump the headers of an existing option ROM image",\r
-    "",\r
-    "Example usage: EfiRom -v 0xABCD -d 0x1234 -b File1.bin File2.bin -e File1.efi File2.efi",\r
+  int        Index;\r
+  const char *Str[] = {\r
+    UTILITY_NAME" "UTILITY_VERSION" - Intel EFI Make Option ROM Utility",\r
+    "  Copyright (C), 1999 - 2008 Intel Coproration",\r
+\r
+#if ( defined(UTILITY_BUILD) && defined(UTILITY_VENDOR) )\r
+    "  Built from "UTILITY_BUILD", project of "UTILITY_VENDOR,\r
+#endif\r
+\r
     "",\r
+    "Usage:",\r
+    "  "UTILITY_NAME" [OPTION]... SOURCE ...",\r
+    "Description:",\r
+    "  Create an option ROM image from a list of input files",\r
+    "Options:",\r
+    "  -v  VendorId      - required hex PCI Vendor ID for the device",\r
+    "  -d  DeviceId      - required hex PCI Device ID for the device",\r
+    "  -o  OutFileName   - optional output file name. Default is the first input",\r
+    "                      file name with a "DEFAULT_OUTPUT_EXTENSION" file extension",\r
+    "  -e  SOURCE ...    - input are EFI PE32 image file(s)",\r
+    "  -b  SOURCE ...    - input are Legacy binary file(s)",\r
+    "  -ec SOURCE ...    - input are EFI PE32 image file(s) and should be compressed",\r
+    "  -p                - for verbose output",\r
+    "  -l                - to not automatically set the LAST bit on the last file",\r
+    "  -cc ClassCode     - to use hex ClassCode in the PCI data structure header for",\r
+    "                      the following SOURCE(s)",\r
+    "  -rev Revision     - to use hex Revision in the PCI data structure header for",\r
+    "                      the following one SOURCE",\r
+    "  -dump             - to dump the headers of an existing option ROM image",\r
+    "Example Usage:",\r
+    "  EfiRom -v 0xABCD -d 0x1234 -b File1.bin File2.bin -e File1.efi File2.efi",\r
     NULL\r
   };\r
 \r
-  for (Index = 0; Msg[Index] != NULL; Index++) {\r
-    fprintf (stdout, "%s\n", Msg[Index]);\r
+  for (Index = 0; Str[Index] != NULL; Index++) {\r
+    fprintf (stdout, "%s\n", Str[Index]);\r
   }\r
 }\r
 \r