$ cat test.s .type foo,%gnu_indirect_function foo: .globl _start _start: .data .quad foo $ ./gas/as-new test.s -o test.o $ gdb --args ./ld/ld-new test.o -o test (gdb) r Starting program: /usr/local/gentoo/src/patchsets/binutils/binutils-2.23/build/ld/ld-new test.o -o test Program received signal SIGSEGV, Segmentation fault. s390_elf_create_ifunc_sections (abfd=0x0, info=info@entry=0x709ac0 <link_info>) at ../../bfd/elf-s390-common.c:41 41 const struct elf_backend_data *bed = get_elf_backend_data (abfd); this is vanilla binutils-2.23 built with `./configure --target=s390x-linux-gnu`
Created attachment 6716 [details] Proposed fix This fixes the problem for me. I'll commit it to mainline asap.
CVSROOT: /cvs/src Module name: src Changes by: krebbel@sourceware.org 2012-11-05 12:31:09 Modified files: bfd : ChangeLog elf32-s390.c elf64-s390.c Log message: 2012-11-05 Andreas Krebbel <Andreas.Krebbel@de.ibm.com> PR target/14788 * elf32-s390.c (elf_s390_relocate_section): Set elf.dynobj for local ifunc symbols. * elf64-s390.c (elf_s390_relocate_section): Likewise. Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/ChangeLog.diff?cvsroot=src&r1=1.5839&r2=1.5840 http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/elf32-s390.c.diff?cvsroot=src&r1=1.124&r2=1.125 http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/elf64-s390.c.diff?cvsroot=src&r1=1.123&r2=1.124
could you commit it to the 2.23 branch too ?
CVSROOT: /cvs/src Module name: src Branch: binutils-2_23-branch Changes by: gingold@sourceware.org 2012-11-12 09:04:13 Modified files: bfd : ChangeLog elf32-s390.c elf64-s390.c Log message: bfd/ 2012-11-05 Andreas Krebbel <Andreas.Krebbel@de.ibm.com> PR target/14788 * elf32-s390.c (elf_s390_relocate_section): Set elf.dynobj for local ifunc symbols. * elf64-s390.c (elf_s390_relocate_section): Likewise. Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/ChangeLog.diff?cvsroot=src&only_with_tag=binutils-2_23-branch&r1=1.5758.2.23&r2=1.5758.2.24 http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/elf32-s390.c.diff?cvsroot=src&only_with_tag=binutils-2_23-branch&r1=1.122&r2=1.122.4.1 http://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/elf64-s390.c.diff?cvsroot=src&only_with_tag=binutils-2_23-branch&r1=1.121&r2=1.121.4.1
Done. On Nov 10, 2012, at 6:54 AM, vapier at gentoo dot org wrote: > http://sourceware.org/bugzilla/show_bug.cgi?id=14788 > > Mike Frysinger <vapier at gentoo dot org> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > CC| |gingold at adacore dot com > > --- Comment #3 from Mike Frysinger <vapier at gentoo dot org> 2012-11-10 05:54:02 UTC --- > could you commit it to the 2.23 branch too ? > > -- > Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email > ------- You are receiving this mail because: ------- > You are on the CC list for the bug.
Fixed with comment 4.