1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-30 22:43:12 +03:00
1999-07-25  Jakub Jelinek  <jj@ultra.linux.cz>

	* elf/link.h (struct link_map): Use Elf_Symndx instead of ElfXX_Symndx.
	* elf/dl-lookup.c (_dl_setup_hash): Likewise.
	* elf/dl-load.c (_dl_map_object): Likewise.
	* elf/do-lookup.h (do_lookup*): Likewise.
	* sysdeps/generic/bits/elfclass.h: Define Elf_Symndx as uint32_t.
	* sysdeps/unix/sysv/linux/alpha/bits/elfclass.h: Define Elf_symndx
	as uint64_t.
	* elf/elf.h: Remove Elf32_Symndx and Elf64_Symndx.
This commit is contained in:
Ulrich Drepper
1999-07-27 05:53:25 +00:00
parent 650364fa29
commit a1eca9f329
9 changed files with 37 additions and 10 deletions

View File

@ -1,3 +1,14 @@
1999-07-25 Jakub Jelinek <jj@ultra.linux.cz>
* elf/link.h (struct link_map): Use Elf_Symndx instead of ElfXX_Symndx.
* elf/dl-lookup.c (_dl_setup_hash): Likewise.
* elf/dl-load.c (_dl_map_object): Likewise.
* elf/do-lookup.h (do_lookup*): Likewise.
* sysdeps/generic/bits/elfclass.h: Define Elf_Symndx as uint32_t.
* sysdeps/unix/sysv/linux/alpha/bits/elfclass.h: Define Elf_symndx
as uint64_t.
* elf/elf.h: Remove Elf32_Symndx and Elf64_Symndx.
1999-07-26 Ulrich Drepper <drepper@cygnus.com> 1999-07-26 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/sysv4/setsid.c: Correct types. * sysdeps/unix/sysv/sysv4/setsid.c: Correct types.

View File

@ -9,3 +9,6 @@
#include <bits/wordsize.h> #include <bits/wordsize.h>
#define __ELF_NATIVE_CLASS __WORDSIZE #define __ELF_NATIVE_CLASS __WORDSIZE
/* The entries in the .hash table always have a size of 32 bits. */
typedef uint32_t Elf_Symndx;

View File

@ -1416,7 +1416,7 @@ _dl_map_object (struct link_map *loader, const char *name, int preloaded,
are only interested in the list of libraries this isn't are only interested in the list of libraries this isn't
so severe. Fake an entry with all the information we so severe. Fake an entry with all the information we
have. */ have. */
static const ElfW(Symndx) dummy_bucket = STN_UNDEF; static const Elf_Symndx dummy_bucket = STN_UNDEF;
/* Enter the new object in the list of loaded objects. */ /* Enter the new object in the list of loaded objects. */
if ((name_copy = local_strdup (name)) == NULL if ((name_copy = local_strdup (name)) == NULL

View File

@ -320,8 +320,8 @@ void
internal_function internal_function
_dl_setup_hash (struct link_map *map) _dl_setup_hash (struct link_map *map)
{ {
ElfW(Symndx) *hash; Elf_Symndx *hash;
ElfW(Symndx) nchain; Elf_Symndx nchain;
if (!map->l_info[DT_HASH]) if (!map->l_info[DT_HASH])
return; return;

View File

@ -43,7 +43,7 @@ FCT (const char *undef_name, struct link_map *undef_map,
const ElfW(Sym) *symtab; const ElfW(Sym) *symtab;
const char *strtab; const char *strtab;
const ElfW(Half) *verstab; const ElfW(Half) *verstab;
ElfW(Symndx) symidx; Elf_Symndx symidx;
const ElfW(Sym) *sym; const ElfW(Sym) *sym;
#if ! VERSIONED #if ! VERSIONED
int num_versions = 0; int num_versions = 0;

View File

@ -56,10 +56,6 @@ typedef uint64_t Elf64_Off;
typedef uint16_t Elf32_Section; typedef uint16_t Elf32_Section;
typedef uint16_t Elf64_Section; typedef uint16_t Elf64_Section;
/* Type of symbol indices. */
typedef uint32_t Elf32_Symndx;
typedef uint64_t Elf64_Symndx;
/* The ELF file header. This appears at the start of every ELF file. */ /* The ELF file header. This appears at the start of every ELF file. */

View File

@ -151,8 +151,8 @@ struct link_map
struct link_map *l_loader; struct link_map *l_loader;
/* Symbol hash table. */ /* Symbol hash table. */
ElfW(Symndx) l_nbuckets; Elf_Symndx l_nbuckets;
const ElfW(Symndx) *l_buckets, *l_chain; const Elf_Symndx *l_buckets, *l_chain;
unsigned int l_opencount; /* Reference count for dlopen/dlclose. */ unsigned int l_opencount; /* Reference count for dlopen/dlclose. */
enum /* Where this object came from. */ enum /* Where this object came from. */

View File

@ -9,3 +9,6 @@
#include <bits/wordsize.h> #include <bits/wordsize.h>
#define __ELF_NATIVE_CLASS __WORDSIZE #define __ELF_NATIVE_CLASS __WORDSIZE
/* The entries in the .hash table always have a size of 32 bits. */
typedef uint32_t Elf_Symndx;

View File

@ -0,0 +1,14 @@
/* This file specifies the native word size of the machine, which indicates
the ELF file class used for executables and shared objects on this
machine. */
#ifndef _LINK_H
# error "Never use <bits/elfclass.h> directly; include <link.h> instead."
#endif
#include <bits/wordsize.h>
#define __ELF_NATIVE_CLASS __WORDSIZE
/* Linux/Alpha is exceptional as it has .hash section with 64 bit entries. */
typedef uint64_t Elf_Symndx;