PATCH: PR binutils/5307: objcopy PE<->EFI doesn't work when both PE/EFI are enabled
Pedro Alves
pedro_alves@portugalmail.pt
Mon Nov 12 23:03:00 GMT 2007
Hi,
H.J. Lu wrote:
> objcopy sets pe_opthdr.Subsystem in _bfd_XXi_swap_aouthdr_out if it is
> IMAGE_SUBSYSTEM_UNKNOWN. But _bfd_XX_bfd_copy_private_bfd_data_common
> copies pe_opthdr.Subsystem from input to output so that
> pe_opthdr.Subsystem is never changed. This patch sets
> pe_opthdr.Subsystem to IMAGE_SUBSYSTEM_UNKNOWN if output is different
> from input.
>
Wouldn't you normally want the default subsystem of the
output? Isn't it IMAGE_SUBSYSTEM_EFI_APPLICATION for efi-app-* ?
Wouldn't a more general objcopy flag to change the subsystem
to the one you want be more useful (like ld's --subsystem) ?
Cheers,
Pedro Alves
More information about the Binutils
mailing list