objcopy --redefine-sym(s) segfaults on mach-o-i386

Michael Opitz opitz.michael@gmail.com
Tue Apr 1 10:29:00 GMT 2014


Hello,

objcopy crashes very often when renaming symbols in mach-o-i386 object files.
I've uploaded a coredump http://176.28.14.46/core.24966  and a small
object file with which the crash happened.
The coredump was generated on linux x86_64
The binutils version is:

x86_64-apple-darwin-objcopy --version
GNU objcopy (GNU Binutils) 2.24.51.20140331
Copyright (C) 2014 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.

The binary was compiled on Mountain Lion with gcc -m32 -c test.c -o test.o
where gcc is really a link on clang:
gcc --version
Apple LLVM version 5.1 (clang-503.0.38) (based on LLVM 3.4svn)
Target: x86_64-apple-darwin12.5.0
Thread model: posix

The problem is reproducible with recent binutils compiled on OSX.
I've also attached a valgrind logmessage.

Kind Regards,
Michael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: valgrind.log
Type: text/x-log
Size: 9476 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20140401/9ee7fdb1/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test (2).o
Type: application/x-object
Size: 747 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20140401/9ee7fdb1/attachment-0001.bin>


More information about the Binutils mailing list