This is the mail archive of the
mailing list for the binutils project.
Re: compatibility of (mips ELF) .o files between binutils versions?
- From: Nick Clifton <nickc at cambridge dot redhat dot com>
- To: cgd at broadcom dot com
- Cc: binutils at sources dot redhat dot com
- Date: 15 Jul 2002 14:41:03 +0100
- Subject: Re: compatibility of (mips ELF) .o files between binutils versions?
- References: <email@example.com>
> What's the expected ability of releases of binutils to deal with .o
> files generated by previous relases?
In general the binutils should be backwards compatible with earlier
releases. So a newer release definitely ought to be able to handle
binaries produced by an earlier release. There are exceptions to this
rule, but they are not common.
> I ran into a problem w/ compatibility of objects from 2.11.2 to 2.12.1
> with mips-elf target, with what i'd _expect_ to be very simple inputs:
> .word bar
> built like:
> ../inst-2.11.2/bin/mips-elf-as -o a.o foo.s
> ../inst-2.12.1/bin/mips-elf-ld -o b.o -r a.o
> the link crashes like:
> ../inst-2.12.1/bin/mips-elf-ld: BFD 2.12.1 assertion fail elflink.h:6287
> Segmentation fault (core dumped)
Well this is definitely a bug. The linker should never seg fault. At
the very least it should produce an intelligible error message and
> Should this be expected to work? Is it worth debugging, given that
> things work just fine if assembly and linking happens w/ the same
> version of the tools?
Well it might be a problem specific to the MIPS port, but even so the
linker should not seg fault. It is definitely worth investigating.
> (I'm not really sure where to even begin debugging this...)
It appears to be a problem with the relocs. What does 'objdump -r'
show for the 2.11.2 assembled binary vs the 2.12.1 assembled binary ?