This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: elf bfd_set_arch_mach does not save m68k machine
On Thu, Sep 10, 2009 at 11:22:29AM +0930, Alan Modra wrote:
> On Thu, Sep 10, 2009 at 01:57:46AM +0200, Philippe De Muyter wrote:
> > should we fix that in bfd_set_arch_mach, or define a elf-m68k specific
> > elf_backend_final_write_processing ?
>
> objcopy probably ought to call bfd_merge_private_bfd_data.
I have examined your proposal, but that won't work as is : here is the
beginning of
static bfd_boolean
elf32_m68k_merge_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
{
flagword out_flags;
flagword in_flags;
flagword out_isa;
flagword in_isa;
const bfd_arch_info_type *arch_info;
if ( bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
return FALSE;
That works only for elf input :(
is there a generic bfd function for conversion from bfd machine to output
format machine ?
I suggested `elf_backend_final_write_processing' because I had found
`elf_hppa_final_write_processing' that does precisely that, for hppa of course.
Philippe