gold patch committed: Initialize first .got.plt entry
Ian Lance Taylor
iant@google.com
Fri Jul 15 21:43:00 GMT 2011
I somehow managed to overlook the x86/x86_64 ELF ABI requirement that
the first entry in the .got.plt section hold the unrelocated address of
the .dynamic section. I got away with it because the only program which
cares is the dynamic linker itself. This patch fixes the problem.
Committed to mainline.
Ian
2011-07-15 Ian Lance Taylor <iant@google.com>
* i386.cc (class Output_data_plt_i386): Add layout_ field.
(Output_data_plt_i386::Output_data_plt_i386): Initialize layout_.
(Output_data_plt_i386::do_write): Write address of .dynamic
section to first entry in .got.plt section.
* x86_64.cc (class Output_data_plt_x86_64): Add layout_ field.
(Output_data_plt_x86_64::Output_data_plt_x86_64) [both versions]:
Initialize layout_.
(Output_data_plt_x86_64::do_write): Write address of .dynamic
section to first entry in .got.plt section.
* layout.h (Layout::dynamic_section): New function.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: foo.patch
Type: text/x-diff
Size: 5494 bytes
Desc: patch
URL: <https://sourceware.org/pipermail/binutils/attachments/20110715/3ec9fc78/attachment.bin>
More information about the Binutils
mailing list