aboutsummaryrefslogtreecommitdiff
path: root/elf/dl-reloc.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-02-03 00:31:37 +0000
committerUlrich Drepper <drepper@redhat.com>2002-02-03 00:31:37 +0000
commit7969407a01a108298ea506e0c37c1d6b7c9d424c (patch)
tree3c4f570e330a91ce712a574ee2d7ea1e9476c397 /elf/dl-reloc.c
parent88794e308552d6051453544f8790986314fd9e1c (diff)
downloadglibc-7969407a01a108298ea506e0c37c1d6b7c9d424c.tar
glibc-7969407a01a108298ea506e0c37c1d6b7c9d424c.tar.gz
glibc-7969407a01a108298ea506e0c37c1d6b7c9d424c.tar.bz2
glibc-7969407a01a108298ea506e0c37c1d6b7c9d424c.zip
Update.
Change ld.so to not use functions which are exported. One cannot interpose them anyway. Use INT() to mark uses, INTDEF() to mark definitions. * include/libc-symbols.h: Define INT and INTDEF. * sysdeps/generic/ldsodefs.h: Declare _dl_debug_printf_internal, _dl_signal_error_internal, _dl_map_object_internal, _dl_map_object_deps_internal, _dl_lookup_symbol_internal, _dl_lookup_versioned_symbol_internal, _dl_relocate_object_internal, _dl_debug_state_internal, _dl_start_profile_internal, and _dl_unload_cache_internal. * include/dlfcn.h: Declare _dl_catch_error_internal. * elf/rtld.c: Use INT for calls to any of the *_internal functions above. Add INTDEF to function definitions. * elf/dl-debug.c: Likewise. * elf/dl-deps.c: Likewise. * elf/dl-dst.h: Likewise. * elf/dl-error.c: Likewise. * elf/dl-fini.c: Likewise. * elf/dl-init.c: Likewise. * elf/dl-load.c: Likewise. * elf/dl-lookup.c: Likewise. * elf/dl-misc.c: Likewise. * elf/dl-open.c: Likewise. * elf/dl-profile.c: Likewise. * elf/dl-reloc.c: Likewise. * elf/dl-runtime.c: Likewise. * elf/dl-version.c: Likewise. * elf/do-lookup.h: Likewise. * sysdeps/generic/dl-cache.c: Likewise. * sysdeps/generic/dl-sysdep.c: Likewise. * sysdeps/alpha/dl-machine.h (RTLD_START): Call _dl_init_internal instead of _dl_init. * sysdeps/arm/dl-machine.h: Likewise. * sysdeps/cris/dl-machine.h: Likewise. * sysdeps/hppa/dl-machine.h: Likewise. * sysdeps/i386/dl-machine.h: Likewise. * sysdeps/ia64/dl-machine.h: Likewise. * sysdeps/m68k/dl-machine.h: Likewise. * sysdeps/mips/dl-machine.h: Likewise. * sysdeps/mips/mips64/dl-machine.h: Likewise. * sysdeps/s390/s390-32/dl-machine.h: Likewise. * sysdeps/s390/s390-64/dl-machine.h: Likewise. * sysdeps/sh/dl-machine.h: Likewise. * sysdeps/sparc/sparc32/dl-machine.h: Likewise. * sysdeps/sparc/sparc64/dl-machine.h: Likewise. * sysdeps/x86_64/dl-machine.h: Likewise. * sysdeps/powerpc/dl-start.S (_dl_start_user): Likewise. * elf/Versions: Don't export _dl_check_all_versions, _dl_sysdep_start, and _dl_debug_initialize.
Diffstat (limited to 'elf/dl-reloc.c')
-rw-r--r--elf/dl-reloc.c27
1 files changed, 15 insertions, 12 deletions
diff --git a/elf/dl-reloc.c b/elf/dl-reloc.c
index 8fea3fd778..67a47aa14a 100644
--- a/elf/dl-reloc.c
+++ b/elf/dl-reloc.c
@@ -87,7 +87,7 @@ _dl_relocate_object (struct link_map *l, struct r_scope_elem *scope[],
{
errstring = N_("cannot make segment writable for relocation");
call_error:
- _dl_signal_error (errno, l->l_name, NULL, errstring);
+ INT(_dl_signal_error) (errno, l->l_name, NULL, errstring);
}
#if (PF_R | PF_W | PF_X) == 7 && (PROT_READ | PROT_WRITE | PROT_EXEC) == 7
@@ -126,11 +126,12 @@ _dl_relocate_object (struct link_map *l, struct r_scope_elem *scope[],
l->l_lookup_cache.type_class = _tc; \
l->l_lookup_cache.sym = (*ref); \
_lr = ((version) != NULL && (version)->hash != 0 \
- ? _dl_lookup_versioned_symbol (strtab + (*ref)->st_name, \
- l, (ref), scope, \
- (version), _tc, 0) \
- : _dl_lookup_symbol (strtab + (*ref)->st_name, l, (ref), \
- scope, _tc, 0)); \
+ ? INT(_dl_lookup_versioned_symbol) (strtab \
+ + (*ref)->st_name, \
+ l, (ref), scope, \
+ (version), _tc, 0) \
+ : INT(_dl_lookup_symbol) (strtab + (*ref)->st_name, l, \
+ (ref), scope, _tc, 0)); \
l->l_lookup_cache.ret = (*ref); \
l->l_lookup_cache.value = _lr; })) \
: l)
@@ -146,11 +147,12 @@ _dl_relocate_object (struct link_map *l, struct r_scope_elem *scope[],
l->l_lookup_cache.type_class = _tc; \
l->l_lookup_cache.sym = (*ref); \
_lr = ((version) != NULL && (version)->hash != 0 \
- ? _dl_lookup_versioned_symbol (strtab + (*ref)->st_name, \
- l, (ref), scope, \
- (version), _tc, 0) \
- : _dl_lookup_symbol (strtab + (*ref)->st_name, l, (ref), \
- scope, _tc, 0)); \
+ ? INT(_dl_lookup_versioned_symbol) (strtab \
+ + (*ref)->st_name, \
+ l, (ref), scope, \
+ (version), _tc, 0) \
+ : INT(_dl_lookup_symbol) (strtab + (*ref)->st_name, l, \
+ (ref), scope, _tc, 0)); \
l->l_lookup_cache.ret = (*ref); \
l->l_lookup_cache.value = _lr; })) \
: l->l_addr)
@@ -201,6 +203,7 @@ _dl_relocate_object (struct link_map *l, struct r_scope_elem *scope[],
textrels = textrels->next;
}
}
+INTDEF (_dl_relocate_object)
void
@@ -220,5 +223,5 @@ _dl_reloc_bad_type (struct link_map *map, unsigned int type, int plt)
*cp++ = DIGIT (type >> 4);
*cp = DIGIT (type);
- _dl_signal_error (0, map->l_name, NULL, msgbuf);
+ INT(_dl_signal_error) (0, map->l_name, NULL, msgbuf);
}