From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.2.1) Gecko/20010901 Description of problem: ld crashes with SIGSEGV when linking eCos test programs. This happens with gcc-2.96-98.i386.rpm using binutils-2.11.90.0.8-9.i386.rpm as well as binutils-2.11.93.0.2-3.i386.rpm (from PowerTools). Version-Release number of selected component (if applicable): binutils-2.11.90.0.8-9.i386.rpm binutils-2.11.93.0.2-3.i386.rpm How reproducible: Always Steps to Reproduce: 1.Unpack ld-bug.tar.bz2 2.make Actual Results: GNU ld version 2.11.90.0.8 (with BFD 2.11.90.0.8) Segmentation fault Expected Results: no segfault Additional info: Here is some relevant gdb output using a ld compiled with debugging from binutils-2.11.93.0.2-3.i386.rpm: Program received signal SIGSEGV, Segmentation fault. 0x080b95f1 in merge_strings (sinfo=0x812b614) at merge.c:731 731 secinfo = sinfo->htab->first->secinfo; (gdb) bt #0 0x080b95f1 in merge_strings (sinfo=0x812b614) at merge.c:731 #1 0x080b981b in _bfd_merge_sections (abfd=0x8109b20, xsinfo=0x812b614, remove_hook=0x808a020 <merge_sections_remove_hook>) at merge.c:808 #2 0x0808a0a1 in _bfd_elf_merge_sections (abfd=0x8109b20, info=0x8102880) at elf.c:796 #3 0x08055a8b in lang_process () at ldlang.c:4169 #4 0x08058a15 in main (argc=13, argv=0xbffffb44) at ./ldmain.c:422 #5 0x40049507 in __libc_start_main (main=0x8058298 <main>, argc=13, ubp_av=0xbffffb44, init=0x80491f4 <_init>, fini=0x80cb880 <_fini>, rtld_fini=0x4000dc14 <_dl_fini>, stack_end=0xbffffb3c) at ../sysdeps/generic/libc-start.c:129 (gdb) print *sinfo->htab $1 = {table = {table = 0x812cac0, size = 4051, newfunc = 0x80b8544 <sec_merge_hash_newfunc>, memory = 0x8118cd8}, size = 0, first = 0x0, last = 0x0, entsize = 1, strings = 1073741824}
Created attachment 46720 [details] Archive of files to reproduce ld bug
Should be fixed with http://sources.redhat.com/ml/binutils/2002-03/msg00088.html
Verified that the proposed fix stops the seg fault when applied to binutils-2.11.93.0.2-3.i386.rpm.
Should be fixed in binutils-2.11.93.0.2-6 then.