/** @file\r
-\r
-Copyright 2006 - 2008, Intel Corporation \r
-All rights reserved. This program and the accompanying materials \r
+Creates and EFILDR image.\r
+This tool combines several PE Image files together using following format denoted as EBNF:\r
+FILE := EFILDR_HEADER\r
+ EFILDR_IMAGE +\r
+ <PeImageFileContent> +\r
+The order of EFILDR_IMAGE is same as the order of placing PeImageFileContent.\r
+ \r
+Copyright (c) 2006 - 2014, 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
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
\r
-Module Name:\r
-\r
- efildrimage.c\r
-\r
-Abstract:\r
-\r
- Creates and EFILDR image.\r
- This tool combines several PE Image files together using following format denoted as EBNF:\r
- FILE := EFILDR_HEADER\r
- EFILDR_IMAGE +\r
- <PeImageFileContent> +\r
- The order of EFILDR_IMAGE is same as the order of placing PeImageFileContent.\r
-\r
-Revision History\r
-\r
**/\r
\r
\r
\r
--*/\r
{\r
- printf ("%s v%d.%d -Utility to break a file into two pieces at the request offset.\n", UTILITY_NAME, UTILITY_MAJOR_VERSION, UTILITY_MINOR_VERSION);\r
- printf ("Copyright (c) 1999-2007 Intel Corporation. All rights reserved.\n");\r
+ printf ("%s Version %d.%d %s\n", UTILITY_NAME, UTILITY_MAJOR_VERSION, UTILITY_MINOR_VERSION, __BUILD_VERSION);\r
+ printf ("Copyright (c) 1999-2014 Intel Corporation. All rights reserved.\n");\r
+ printf ("\n The EfiLdrImage tool is used to combine PE files into EFILDR image with Efi loader header.\n");\r
}\r
\r
VOID\r
CHAR8* OutputFileName = NULL;\r
CHAR8* InputFileNames[MAX_PE_IMAGES + 1];\r
UINT8 InputFileCount = 0;\r
- BOOLEAN QuietFlag = FALSE;\r
UINT64 DebugLevel = 0;\r
UINT64 VerboseLevel = 0;\r
EFI_STATUS Status = EFI_SUCCESS;\r
}\r
\r
if ((stricmp (argv[0], "-q") == 0) || (stricmp (argv[0], "--quiet") == 0)) {\r
- QuietFlag = TRUE;\r
argc --;\r
argv ++;\r
continue; \r
return STATUS_ERROR;\r
}\r
\r
- fpOut = fopen(OutputFileName, "w+b");\r
+ fpOut = fopen (LongFilePath (OutputFileName), "w+b");\r
if (!fpOut) {\r
Error (NULL, 0, 0001, "Could not open output file", OutputFileName);\r
return STATUS_ERROR;\r
//\r
// Copy the content of PeImage file to output file\r
//\r
- fpIn = fopen (InputFileNames[i], "rb");\r
+ fpIn = fopen (LongFilePath (InputFileNames[i]), "rb");\r
if (!fpIn) {\r
Error (NULL, 0, 0001, "Could not open input file", InputFileNames[i]);\r
fclose (fpOut);\r