aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@codesourcery.com>2008-04-21 17:54:25 +0000
committerNathan Sidwell <nathan@codesourcery.com>2008-04-21 17:54:25 +0000
commit131eb6b75e45eec24860ff6972f23b0e723db75c (patch)
treef8f82ef6d68275987a3b6466a2dc37ef2ff4be8b /bfd
parent550512b831f018f3c1ceec7abb42f7123b03d77c (diff)
downloadgdb-131eb6b75e45eec24860ff6972f23b0e723db75c.zip
gdb-131eb6b75e45eec24860ff6972f23b0e723db75c.tar.gz
gdb-131eb6b75e45eec24860ff6972f23b0e723db75c.tar.bz2
bfd/
* elfxx-mips.c (_bfd_mips_vxworks_adjust_dynamic_symbol): Don't set the value of undefined symbols in shared objects. (_bfd_mips_vxworks_finish_dynamic_symbol): Clear value for undefined symbols unless pointer equality is needed. ld/testsuite/ * ld-vxworks/plt-mips1.s: New. * ld-vxworks/plt-mips1.d: New.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog7
-rw-r--r--bfd/elfxx-mips.c11
2 files changed, 12 insertions, 6 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 1ac4be9..7171a0c 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,10 @@
+2008-04-21 Nathan Sidwell <nathan@codesourcery.com>
+
+ * elfxx-mips.c (_bfd_mips_vxworks_adjust_dynamic_symbol): Don't
+ set the value of undefined symbols in shared objects.
+ (_bfd_mips_vxworks_finish_dynamic_symbol): Clear value for
+ undefined symbols unless pointer equality is needed.
+
2008-04-18 Dennis Roberts <dennis.roberts@sunquestinfo.com>
* aix5ppc-core.c: Define macros for the default architecture and
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c
index 396e578..5173c0a 100644
--- a/bfd/elfxx-mips.c
+++ b/bfd/elfxx-mips.c
@@ -7466,15 +7466,14 @@ _bfd_mips_vxworks_adjust_dynamic_symbol (struct bfd_link_info *info,
htab->splt->size += htab->plt_entry_size;
/* If the output file has no definition of the symbol, set the
- symbol's value to the address of the stub. For executables,
- point at the PLT load stub rather than the lazy resolution stub;
- this stub will become the canonical function address. */
- if (!h->def_regular)
+ symbol's value to the address of the stub. Point at the PLT
+ load stub rather than the lazy resolution stub; this stub
+ will become the canonical function address. */
+ if (!info->shared && !h->def_regular)
{
h->root.u.def.section = htab->splt;
h->root.u.def.value = h->plt.offset;
- if (!info->shared)
- h->root.u.def.value += 8;
+ h->root.u.def.value += 8;
}
/* Make room for the .got.plt entry and the R_JUMP_SLOT relocation. */