diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2021-06-19 16:33:24 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2021-06-19 16:33:35 -0700 |
commit | 83b1d8f4a69ab5803ae33e05dcf14d8f26848ff2 (patch) | |
tree | 83071abd40e1659806b18fb4ac93829a13695be1 /bfd | |
parent | ce3ec98acd2f344ae911de3f41dd2e3c6c68b141 (diff) | |
download | gdb-83b1d8f4a69ab5803ae33e05dcf14d8f26848ff2.zip gdb-83b1d8f4a69ab5803ae33e05dcf14d8f26848ff2.tar.gz gdb-83b1d8f4a69ab5803ae33e05dcf14d8f26848ff2.tar.bz2 |
elf: Correct DT_TEXTREL warning in PDE
Change
ld: warning: creating DT_TEXTREL in a PIE
to
ld: warning: creating DT_TEXTREL in a PDE
on PDE.
bfd/
* elflink.c (bfd_elf_final_link): Correct DT_TEXTREL warning in
PDE.
ld/
* testsuite/ld-x86-64/textrel-1.err: New file.
* testsuite/ld-x86-64/textrel-1a.s: Likewise.
* testsuite/ld-x86-64/textrel-1b.s: Likewise.
* testsuite/ld-x86-64/x86-64.exp: Run textrel-1 tests.
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 5 | ||||
-rw-r--r-- | bfd/elflink.c | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 29e41a3..5211e98 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2021-06-19 H.J. Lu <hongjiu.lu@intel.com> + + * elflink.c (bfd_elf_final_link): Correct DT_TEXTREL warning in + PDE. + 2021-06-18 H.J. Lu <hongjiu.lu@intel.com> * elf-properties.c (_bfd_elf_parse_gnu_properties): Handle diff --git a/bfd/elflink.c b/bfd/elflink.c index c9a6e78..9a05208 100644 --- a/bfd/elflink.c +++ b/bfd/elflink.c @@ -13138,6 +13138,9 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info) else if (bfd_link_dll (info)) info->callbacks->einfo (_("%P: warning: creating DT_TEXTREL in a shared object\n")); + else if (bfd_link_pde (info)) + info->callbacks->einfo + (_("%P: warning: creating DT_TEXTREL in a PDE\n")); else info->callbacks->einfo (_("%P: warning: creating DT_TEXTREL in a PIE\n")); |