http://sourceware.org/bugzilla/show_bug.cgi?id=15430

             Bug #: 15430
           Summary: objcopy -R makes shared objects unusable
           Product: binutils
           Version: 2.23
            Status: NEW
          Severity: normal
          Priority: P2
         Component: binutils
        AssignedTo: unassig...@sourceware.org
        ReportedBy: oma...@redhat.com
    Classification: Unclassified


Created attachment 7012
  --> http://sourceware.org/bugzilla/attachment.cgi?id=7012
readelf -t on the so file before and after running objcopy -R

When I try to remove the build id note from a shared library using "objcopy -R
.note.gnu.build-id lib.so", the library becomes unusable.

$ objdump -T libjvm.so | grep jio_vfprint
00000000005715a0 g    DF .text    0000000000000026  SUNWprivate_1.1
jio_vfprintf

$ objcopy -R .note.gnu.build-id libjvm.so

$ objdump -T libjvm.so | grep jio_vfprint
00000000005715a0 g    DF .fini    0000000000000026  SUNWprivate_1.1
jio_vfprintf

The function is "moved" from the .text to the .fini section, which makes this
shared object unusable (I get errors when linking this .so).

-- 
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.

_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to