OpenCore  1.0.4
OpenCore Bootloader
Loading...
Searching...
No Matches
EfiLdrImage.c File Reference
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>

Go to the source code of this file.

Data Structures

struct  EFILDR_IMAGE
 
struct  EFILDR_HEADER
 

Macros

#define MAX_PE_IMAGES   63
 
#define FILE_TYPE_FIXED_LOADER   0
 
#define FILE_TYPE_RELOCATABLE_PE_IMAGE   1
 
#define UTILITY_NAME   "EfiLdrImage"
 
#define UTILITY_MAJOR_VERSION   1
 
#define UTILITY_MINOR_VERSION   0
 

Functions

void Error (char *FileName, uint32_t LineNumber, uint32_t ErrorCode, char *OffendingText, char *MsgFmt,...)
 
void Version (void)
 
void Usage (void)
 
int CountVerboseLevel (const char *VerboseLevelString, const uint64_t Length, uint64_t *ReturnValue)
 
uint64_t FCopyFile (FILE *in, FILE *out)
 
int main (int argc, char *argv[])
 

Detailed Description

Creates and EFILDR image. This tool combines several PE Image files together using following format denoted as EBNF: FILE := EFILDR_HEADER EFILDR_IMAGE + <PeImageFileContent> + The order of EFILDR_IMAGE is same as the order of placing PeImageFileContent.

Copyright (c) 2006 - 2018, 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 http://opensource.org/licenses/bsd-license.php

THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHWARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.

Definition in file EfiLdrImage.c.

Macro Definition Documentation

◆ FILE_TYPE_FIXED_LOADER

#define FILE_TYPE_FIXED_LOADER   0

Definition at line 28 of file EfiLdrImage.c.

◆ FILE_TYPE_RELOCATABLE_PE_IMAGE

#define FILE_TYPE_RELOCATABLE_PE_IMAGE   1

Definition at line 29 of file EfiLdrImage.c.

◆ MAX_PE_IMAGES

#define MAX_PE_IMAGES   63

Definition at line 27 of file EfiLdrImage.c.

◆ UTILITY_MAJOR_VERSION

#define UTILITY_MAJOR_VERSION   1

Definition at line 53 of file EfiLdrImage.c.

◆ UTILITY_MINOR_VERSION

#define UTILITY_MINOR_VERSION   0

Definition at line 54 of file EfiLdrImage.c.

◆ UTILITY_NAME

#define UTILITY_NAME   "EfiLdrImage"

Definition at line 48 of file EfiLdrImage.c.

Function Documentation

◆ CountVerboseLevel()

int CountVerboseLevel ( const char * VerboseLevelString,
const uint64_t Length,
uint64_t * ReturnValue )

Definition at line 108 of file EfiLdrImage.c.

◆ Error()

void Error ( char * FileName,
uint32_t LineNumber,
uint32_t ErrorCode,
char * OffendingText,
char * MsgFmt,
... )

Definition at line 57 of file EfiLdrImage.c.

◆ FCopyFile()

uint64_t FCopyFile ( FILE * in,
FILE * out )

Definition at line 126 of file EfiLdrImage.c.

◆ main()

int main ( int argc,
char * argv[] )

Definition at line 170 of file EfiLdrImage.c.

◆ Usage()

void Usage ( void )

Definition at line 97 of file EfiLdrImage.c.

◆ Version()

void Version ( void )

Definition at line 74 of file EfiLdrImage.c.