ld is broken on ia64
H . J . Lu
hjl@lucon.org
Thu Nov 8 13:41:00 GMT 2001
On Sat, Nov 17, 2001 at 09:43:00AM -0800, H . J . Lu wrote:
> Bootstrap gcc 3.0.3 20011116, I got
>
> .libs/string-inst.o:/home/hjl/build/tools/build-ia64-linux/ia64-unknown-linux/libstdc++-v3/include/bits/basic_string.h:238:
> unsupported reloc
> .libs/string-inst.o:/home/hjl/build/tools/build-ia64-linux/ia64-unknown-linux/libstdc++-v3/include/bits/basic_string.h:238:
> unsupported reloc
> collect2: ld returned 1 exit status
>
> It may be caused by those ELF linker changes.
I believe this patch
http://sources.redhat.com/ml/binutils/2001-11/msg00212.html
breaks ia64, specifically
http://sources.redhat.com/cgi-bin/cvsweb.cgi/src/bfd/elflink.h.diff?cvsroot=src&r1=1.122&r2=1.123
The problem is around line 3864 in elfxx-ia64.c:
{
/* If the input section was discarded from the output, then
do nothing. */
if (bfd_is_abs_section (sym_sec->output_section))
r = bfd_reloc_ok;
else
r = bfd_reloc_notsupported;
}
since we are no longer clearing the relocation type. The relocations
against the discarded sections remains, R_IA64_SEGREL64LSB in an unwind
section. I think we should do something like
http://sources.redhat.com/ml/binutils/2001-10/msg00589.html
That is we have a default and allow each backend to decide what to do
with relocations against the discarded sections.
H.J.
More information about the Binutils
mailing list