summaryrefslogtreecommitdiff
path: root/bfd/elf32-xtensa.c
diff options
context:
space:
mode:
authorBob Wilson <bob.wilson@acm.org>2006-10-10 20:57:36 +0000
committerBob Wilson <bob.wilson@acm.org>2006-10-10 20:57:36 +0000
commit7432f2fb0279f22eb636ebee1fc34886d9d675a8 (patch)
tree826525435e0866db5352f17e6497e961800dd43d /bfd/elf32-xtensa.c
parent8b05b71ea7e890c54aa7e91fddafeec2c3b2fabd (diff)
downloadgdb-7432f2fb0279f22eb636ebee1fc34886d9d675a8.tar.gz
bfd/
* elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Add DT_DEBUG for PIE executables. ld/ * emulparams/elf32xtensa.sh (GENERATE_PIE_SCRIPT): Enable.
Diffstat (limited to 'bfd/elf32-xtensa.c')
-rw-r--r--bfd/elf32-xtensa.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/bfd/elf32-xtensa.c b/bfd/elf32-xtensa.c
index d8b9d1ecf00..c93f84d8c76 100644
--- a/bfd/elf32-xtensa.c
+++ b/bfd/elf32-xtensa.c
@@ -1123,8 +1123,7 @@ add_extra_plt_sections (bfd *dynobj, int count)
sname = (char *) bfd_malloc (10);
sprintf (sname, ".plt.%u", chunk);
- s = bfd_make_section_with_flags (dynobj, sname,
- flags | SEC_CODE);
+ s = bfd_make_section_with_flags (dynobj, sname, flags | SEC_CODE);
if (s == NULL
|| ! bfd_set_section_alignment (dynobj, s, 2))
return FALSE;
@@ -1471,7 +1470,7 @@ elf_xtensa_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
#define add_dynamic_entry(TAG, VAL) \
_bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (! info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
return FALSE;