]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Place copy relocations in .dynbss when target is read-only.
authorCary Coutant <ccoutant@gmail.com>
Wed, 28 Dec 2016 04:50:47 +0000 (20:50 -0800)
committerCary Coutant <ccoutant@gmail.com>
Wed, 28 Dec 2016 04:56:37 +0000 (20:56 -0800)
commita08db921c967484bbd4fb66ca2648548866cba59
tree61c6bd91486703c699d8192f6cf363c14fb5a49a
parent17026142ef35b62ac88bfe517b4160614902cb28
Place copy relocations in .dynbss when target is read-only.

gold/
PR ld/20995
* copy-relocs.cc (Copy_relocs::make_copy_reloc): Use .dynbss for
read-only data when linking with -z relro.
* copy-relocs.h (Copy_relocs::dynrelro_): New data member.
* testsuite/Makefile.am (copy_test_relro): New test case.
* testsuite/Makefile.in: Regenerate.
* testsuite/copy_test_relro.cc: New source file.
* testsuite/copy_test_relro_1.cc: New source file.
gold/ChangeLog
gold/copy-relocs.cc
gold/copy-relocs.h
gold/testsuite/Makefile.am
gold/testsuite/Makefile.in
gold/testsuite/copy_test_relro.cc [new file with mode: 0644]
gold/testsuite/copy_test_relro_1.cc [new file with mode: 0644]