summaryrefslogtreecommitdiff
path: root/sysdeps/powerpc/powerpc64/dl-machine.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/powerpc/powerpc64/dl-machine.c')
-rw-r--r--sysdeps/powerpc/powerpc64/dl-machine.c31
1 files changed, 25 insertions, 6 deletions
diff --git a/sysdeps/powerpc/powerpc64/dl-machine.c b/sysdeps/powerpc/powerpc64/dl-machine.c
index 3b4ed65bc9..959907bf02 100644
--- a/sysdeps/powerpc/powerpc64/dl-machine.c
+++ b/sysdeps/powerpc/powerpc64/dl-machine.c
@@ -1,5 +1,5 @@
/* Machine-dependent ELF dynamic relocation functions. PowerPC64 version.
- Copyright (C) 1995-2016 Free Software Foundation, Inc.
+ Copyright (C) 1995-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -24,14 +24,17 @@
void
_dl_reloc_overflow (struct link_map *map,
- const char *name,
- Elf64_Addr *const reloc_addr,
- const Elf64_Sym *refsym)
+ const char *name,
+ Elf64_Addr *const reloc_addr,
+ const Elf64_Sym *refsym)
{
- char buffer[128];
+ char buffer[1024];
char *t;
t = stpcpy (buffer, name);
- t = stpcpy (t, " reloc at 0x");
+ /* Notice that _itoa_word() writes characters from the higher address to the
+ lower address, requiring the destination string to reserve all the
+ required size before the call. */
+ t = stpcpy (t, " reloc at 0x0000000000000000");
_itoa_word ((unsigned long) reloc_addr, t, 16, 0);
if (refsym)
{
@@ -45,3 +48,19 @@ _dl_reloc_overflow (struct link_map *map,
t = stpcpy (t, " out of range");
_dl_signal_error (0, map->l_name, NULL, buffer);
}
+
+#if _CALL_ELF == 2
+void
+_dl_error_localentry (struct link_map *map, const Elf64_Sym *refsym)
+{
+ char buffer[1024];
+ char *t;
+ const char *strtab;
+
+ strtab = (const void *) D_PTR (map, l_info[DT_STRTAB]);
+ t = stpcpy (buffer, "expected localentry:0 `");
+ t = stpcpy (t, strtab + refsym->st_name);
+ t = stpcpy (t, "'");
+ _dl_signal_error (0, map->l_name, NULL, buffer);
+}
+#endif