Indicate if the executable was compiled to create 32- or 64-bit EFI files. Enumerate EFI subsystems. Treat -? like -h.
Signed-off-by: Heinrich Schuchardt <xypron.g...@gmx.de> --- src/util/elf2efi.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/src/util/elf2efi.c b/src/util/elf2efi.c index 27f37d98..a0f3c67c 100644 --- a/src/util/elf2efi.c +++ b/src/util/elf2efi.c @@ -953,8 +953,17 @@ static void elf2pe ( const char *elf_name, const char *pe_name, * @v program_name Program name */ static void print_help ( const char *program_name ) { - eprintf ( "Syntax: %s [--subsystem=<number>] infile outfile\n", - program_name ); + eprintf ( "Usage: %s [--subsystem=<number>] infile outfile\n", + program_name ); +#ifdef EFI_TARGET32 + eprintf ( "Create 32-bit EFI binary.\n" ); +#elif defined(EFI_TARGET64) + eprintf ( "Create 64-bit EFI binary.\n" ); +#endif + eprintf ( "\nSubsystem:\n" + "\t10\tEFI application, default\n" + "\t11\tEFI boot service driver\n" + "\t12\tEFI runtime driver\n" ); } /** @@ -993,10 +1002,11 @@ static int parse_options ( const int argc, char **argv, } break; case 'h': + case '?': print_help ( argv[0] ); exit ( 0 ); - case '?': default: + print_help ( argv[0] ); exit ( 2 ); } } -- 2.11.0 _______________________________________________ ipxe-devel mailing list ipxe-devel@lists.ipxe.org https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel