abrt 1.1.1 detected a crash. architecture: x86_64 Attached file: backtrace cmdline: /usr/bin/ld --no-add-needed --eh-frame-hdr --build-id -m elf_x86_64 --hash-style=gnu -shared -o fil_rgb.so /usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64/crti.o /usr/lib/gcc/x86_64-redhat-linux/4.4.4/crtbeginS.o -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4 -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4 -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../.. fil_rgb.o /home/agoode/diamond-git/snapfind/src/target/lib/libsfimage.a /opt/diamond-filter-kit/lib/libtiff.a /opt/diamond-filter-kit/lib/libjpeg.a /opt/diamond-filter-kit/lib/libz.a --gc-sections -lstdc++ -lm -lgcc_s -lc -lgcc_s /usr/lib/gcc/x86_64-redhat-linux/4.4.4/crtendS.o /usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64/crtn.o component: binutils crash_function: mempcpy executable: /usr/bin/ld.bfd global_uuid: c36bc5711331224d5e3988cde7c68f95223ebcf2 kernel: 2.6.33.6-147.fc13.x86_64 package: binutils-2.20.51.0.2-20.fc13 rating: 4 reason: Process /usr/bin/ld.bfd was killed by signal 11 (SIGSEGV) release: Fedora release 13 (Goddard) How to reproduce: 1. Try to incorrectly link 64-bit and 32-bit stuff together. comment ----- g++ -o fil_rgb.so fil_rgb.o -shared /home/agoode/diamond-git/snapfind/src/target/lib/libsfimage.a /opt/diamond-filter-kit/lib/libtiff.a /opt/diamond-filter-kit/lib/libjpeg.a /opt/diamond-filter-kit/lib/libz.a -Wl,--gc-sections collect2: ld terminated with signal 11 [Segmentation fault], core dumped /usr/bin/ld: i386 architecture of input file `/opt/diamond-filter-kit/lib/libtiff.a(tif_close.o)' is incompatible with i386:x86-64 output
Created attachment 438453 [details] File: backtrace
I have a reproducible testcase for something that looks very similar on rawhide $ cat > bug623876.l <<FLEXEOF %% a { ECHO; } b { REJECT; } c { yymore (); } d { yyless (1); } e { yyless (input () != 0); } f { unput (yytext[0]); } . { BEGIN INITIAL; } %% extern char *yytext; int main (void) { return ! yylex () + ! yywrap (); } FLEXEOF $ flex bug623876.l $ gcc -o bug623876 -g -O2 lex.yy.c ...kaboom...
The reproducible testcase really helped. I have now tracked down the bug and created a patch to fix it. Binutils rpms binutils-2.20.51.0.2-23.fc13 and binutils-2.20.51.0.10-2.fc15 now contain this fix. Cheers Nick
The fix may be incorrect. The real bug may be: http://www.sourceware.org/bugzilla/show_bug.cgi?id=11817 and it has been fixed in binutils 2.20.51.0.11.
(In reply to comment #2) > I have a reproducible testcase for something that looks very similar on rawhide > > $ cat > bug623876.l <<FLEXEOF > %% > a { ECHO; } > b { REJECT; } > c { yymore (); } > d { yyless (1); } > e { yyless (input () != 0); } > f { unput (yytext[0]); } > . { BEGIN INITIAL; } > %% > extern char *yytext; > int > main (void) > { > return ! yylex () + ! yywrap (); > } > FLEXEOF > $ flex bug623876.l > $ gcc -o bug623876 -g -O2 lex.yy.c > ...kaboom... I can't reproduce it with binutils-2.20.51.0.2-20.fc13.x86_64. I got [hjl@gnu-6 merge-3]$ cat bug623876.l %% a { ECHO; } b { REJECT; } c { yymore (); } d { yyless (1); } e { yyless (input () != 0); } f { unput (yytext[0]); } . { BEGIN INITIAL; } %% extern char *yytext; int main (void) { return ! yylex () + ! yywrap (); } [hjl@gnu-6 merge-3]$ flex bug623876.l [hjl@gnu-6 merge-3]$ PATH=/usr/bin:$PATH gcc -o bug623876 -g -O2 lex.yy.c /tmp/ccsABDME.o: In function `input': /export/home/hjl/bugs/binutils/merge-3/lex.yy.c:1168: undefined reference to `yywrap' /tmp/ccsABDME.o: In function `yylex': /export/home/hjl/bugs/binutils/merge-3/lex.yy.c:867: undefined reference to `yywrap' /tmp/ccsABDME.o: In function `main': /export/home/hjl/bugs/binutils/merge-3/bug623876.l:15: undefined reference to `yywrap' collect2: ld returned 1 exit status [hjl@gnu-6 merge-3]$
(In reply to comment #2) > I have a reproducible testcase for something that looks very similar on rawhide > > $ cat > bug623876.l <<FLEXEOF > %% > a { ECHO; } > b { REJECT; } > c { yymore (); } > d { yyless (1); } > e { yyless (input () != 0); } > f { unput (yytext[0]); } > . { BEGIN INITIAL; } > %% > extern char *yytext; > int > main (void) > { > return ! yylex () + ! yywrap (); > } > FLEXEOF > $ flex bug623876.l > $ gcc -o bug623876 -g -O2 lex.yy.c > ...kaboom... This bug is http://www.sourceware.org/bugzilla/show_bug.cgi?id=11817 and fixed in 2.20.51.0.11.
(In reply to comment #0) > abrt 1.1.1 detected a crash. > > architecture: x86_64 > Attached file: backtrace > cmdline: /usr/bin/ld --no-add-needed --eh-frame-hdr --build-id -m elf_x86_64 > --hash-style=gnu -shared -o fil_rgb.so > /usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64/crti.o > /usr/lib/gcc/x86_64-redhat-linux/4.4.4/crtbeginS.o > -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4 > -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4 > -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64 -L/lib/../lib64 > -L/usr/lib/../lib64 -L/usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../.. fil_rgb.o > /home/agoode/diamond-git/snapfind/src/target/lib/libsfimage.a > /opt/diamond-filter-kit/lib/libtiff.a /opt/diamond-filter-kit/lib/libjpeg.a > /opt/diamond-filter-kit/lib/libz.a --gc-sections -lstdc++ -lm -lgcc_s -lc > -lgcc_s /usr/lib/gcc/x86_64-redhat-linux/4.4.4/crtendS.o > /usr/lib/gcc/x86_64-redhat-linux/4.4.4/../../../../lib64/crtn.o > component: binutils > crash_function: mempcpy > executable: /usr/bin/ld.bfd > global_uuid: c36bc5711331224d5e3988cde7c68f95223ebcf2 > kernel: 2.6.33.6-147.fc13.x86_64 > package: binutils-2.20.51.0.2-20.fc13 > rating: 4 > reason: Process /usr/bin/ld.bfd was killed by signal 11 (SIGSEGV) > release: Fedora release 13 (Goddard) > How to reproduce: 1. Try to incorrectly link 64-bit and 32-bit stuff together. > > comment > ----- > g++ -o fil_rgb.so fil_rgb.o -shared > /home/agoode/diamond-git/snapfind/src/target/lib/libsfimage.a > /opt/diamond-filter-kit/lib/libtiff.a /opt/diamond-filter-kit/lib/libjpeg.a > /opt/diamond-filter-kit/lib/libz.a -Wl,--gc-sections > collect2: ld terminated with signal 11 [Segmentation fault], core dumped > /usr/bin/ld: i386 architecture of input file > `/opt/diamond-filter-kit/lib/libtiff.a(tif_close.o)' is incompatible with > i386:x86-64 output Can you provide a complete testcase? I only need linker inputs which aren't available on Fedora 13.
By linker inputs, you would like the .o and .a files?
(In reply to comment #8) > By linker inputs, you would like the .o and .a files? Yes.
Created attachment 440004 [details] testcase
Thanks for the testcase. The real bug is linker tries to generate a DSO even when inputs are incompatibles: /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_close.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_dir.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_dirinfo.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_dirread.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_error.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_flush.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_getimage.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_open.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_read.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_strip.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_swab.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_tile.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_unix.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_warning.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_write.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_aux.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_color.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_compress.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_dirwrite.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_codec.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_dumpmode.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_fax3.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_fax3sm.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_luv.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_lzw.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_next.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_packbits.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_pixarlog.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_predict.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_thunder.o)' is incompatible with i386:x86-64 output /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: i386 architecture of input file `libtiff.a(tif_zip.o)' is incompatible with i386:x86-64 output libtiff.a(tif_pixarlog.o): In function `.L108': (.text.PixarLogVSetField+0x108): undefined reference to `deflateParams' libtiff.a(tif_pixarlog.o): In function `PixarLogCleanup': (.text.PixarLogCleanup+0xfe): undefined reference to `inflateEnd' libtiff.a(tif_pixarlog.o): In function `PixarLogCleanup': (.text.PixarLogCleanup+0x10b): undefined reference to `deflateEnd' libtiff.a(tif_pixarlog.o): In function `PixarLogPostEncode': (.text.PixarLogPostEncode+0x3f): undefined reference to `deflate' libtiff.a(tif_pixarlog.o): In function `.L160': (.text.PixarLogEncode+0x62c): undefined reference to `deflate' libtiff.a(tif_pixarlog.o): In function `PixarLogPreEncode': (.text.PixarLogPreEncode+0x38): undefined reference to `deflateReset' libtiff.a(tif_pixarlog.o): In function `.L485': (.text.PixarLogDecode+0x101): undefined reference to `inflate' libtiff.a(tif_pixarlog.o): In function `.L485': (.text.PixarLogDecode+0x159): undefined reference to `inflateSync' libtiff.a(tif_pixarlog.o): In function `PixarLogPreDecode': (.text.PixarLogPreDecode+0x38): undefined reference to `inflateReset' libtiff.a(tif_pixarlog.o): In function `PixarLogSetupDecode': (.text.PixarLogSetupDecode+0xf0): undefined reference to `inflateInit_' libtiff.a(tif_pixarlog.o): In function `PixarLogSetupEncode': (.text.PixarLogSetupEncode+0xee): undefined reference to `deflateInit_' libtiff.a(tif_zip.o): In function `ZIPCleanup': (.text.ZIPCleanup+0x87): undefined reference to `inflateEnd' libtiff.a(tif_zip.o): In function `ZIPCleanup': (.text.ZIPCleanup+0x9b): undefined reference to `deflateEnd' libtiff.a(tif_zip.o): In function `ZIPPostEncode': (.text.ZIPPostEncode+0x3f): undefined reference to `deflate' libtiff.a(tif_zip.o): In function `ZIPEncode': (.text.ZIPEncode+0x59): undefined reference to `deflate' libtiff.a(tif_zip.o): In function `ZIPPreEncode': (.text.ZIPPreEncode+0x4f): undefined reference to `deflateReset' libtiff.a(tif_zip.o): In function `ZIPSetupEncode': (.text.ZIPSetupEncode+0x51): undefined reference to `deflateInit_' libtiff.a(tif_zip.o): In function `ZIPSetupEncode': (.text.ZIPSetupEncode+0x74): undefined reference to `inflateEnd' libtiff.a(tif_zip.o): In function `ZIPDecode': (.text.ZIPDecode+0x5b): undefined reference to `inflate' libtiff.a(tif_zip.o): In function `ZIPDecode': (.text.ZIPDecode+0xa9): undefined reference to `inflateSync' libtiff.a(tif_zip.o): In function `ZIPPreDecode': (.text.ZIPPreDecode+0x4f): undefined reference to `inflateReset' libtiff.a(tif_zip.o): In function `ZIPSetupDecode': (.text.ZIPSetupDecode+0x4a): undefined reference to `inflateInit_' libtiff.a(tif_zip.o): In function `ZIPSetupDecode': (.text.ZIPSetupDecode+0x6c): undefined reference to `deflateEnd' libtiff.a(tif_zip.o): In function `ZIPVSetField': (.text.ZIPVSetField+0x75): undefined reference to `deflateParams' /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 /export/home/hjl/bugs/binutils/merge-3/bz623687/ld: BFD version 2.20.51.0.2-22.0.f13 20091009 assertion fail elf64-x86-64.c:3914 Program received signal SIGSEGV, Segmentation fault. 0x0000003e132834d2 in __mempcpy_sse2 () from /lib64/libc.so.6 (gdb) bt #0 0x0000003e132834d2 in __mempcpy_sse2 () from /lib64/libc.so.6 #1 0x0000003e13273e7e in _IO_default_xsputn_internal () from /lib64/libc.so.6 #2 0x0000003e13270fc2 in _IO_new_file_xsputn () from /lib64/libc.so.6 #3 0x0000003e132673bd in fwrite () from /lib64/libc.so.6 #4 0x00000000004367cf in cache_bwrite (abfd=0x7aa6b0, where=0x0, nbytes=336) at cache.c:352 #5 0x0000000000435bd3 in bfd_bwrite (ptr=0x0, size=336, abfd=0x7aa6b0) at bfdio.c:252 #6 0x00000000004756ab in _bfd_elf_set_section_contents (abfd=0x7aa6b0, section=0x10368c8, location=0x0, offset=0, count=336) at elf.c:7402 #7 0x0000000000441775 in bfd_set_section_contents (abfd=0x7aa6b0, section=0x10368c8, location=0x0, offset=0, count=336) at section.c:1445 #8 0x0000000000492080 in bfd_elf_final_link (abfd=0x7aa6b0, info=0x796580) at elflink.c:11179 #9 0x000000000041cf53 in ldwrite () at ldwrite.c:568 #10 0x000000000041a3bf in main (argc=30, argv=0x7fffffffdc28) at ./ldmain.c:490 (gdb)
This patch http://sourceware.org/ml/binutils-cvs/2010-02/msg00018.html fixed the crash. Now we get libtiff.a: could not read symbols: File in wrong format I am not sure if it is the correct behavior.
If take a look at http://sourceware.org/ml/binutils/2010-02/msg00062.html it seems to fix exactly the original problem.
Yes, I think this is the correct behavior. Or at least, what I would expect.
This message is a reminder that Fedora 13 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 13. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '13'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 13's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 13 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping
This is probably fixed now?
Fedora 13 changed to end-of-life (EOL) status on 2011-06-25. Fedora 13 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. Thank you for reporting this bug and we are sorry it could not be fixed.