mirror of
https://sourceware.org/git/glibc.git
synced 2025-12-24 17:51:17 +03:00
* elf/dl-reloc.c: Include "dynamic-link.h" at file scope.
* elf/rtld.c: Include <string.h>. * elf/dynamic-link.h (ELF_DYNAMIC_DO_REL, ELF_DYNAMIC_DO_RELA, ELF_DYNAMIC_RELOCATE): No longer take RESOLVE argument. Conditionalize defns on [RESOLVE]. * elf/do-rel.h (elf_dynamic_do_rel): Likewise. * sysdeps/i386/dl-machine.h (elf_machine_rel): Likewise. Instead use RESOLVE macro with same args. (elf_machine_rel): Conditionalize defn on [RESOLVE]. * elf/dl-reloc.c (RESOLVE): New macro, define before including "dynamic-link.h". It replaces `resolve' local function. * elf/dl-runtime.c: Likewise. * elf/rtld.c: Likewise.
This commit is contained in:
@@ -20,6 +20,7 @@ Cambridge, MA 02139, USA. */
|
||||
#include <link.h>
|
||||
#include <stddef.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <sys/mman.h> /* Check if MAP_ANON is defined. */
|
||||
#include "../stdio-common/_itoa.h"
|
||||
@@ -28,6 +29,7 @@ Cambridge, MA 02139, USA. */
|
||||
/* This #define produces dynamic linking inline functions for
|
||||
bootstrap relocation instead of general-purpose relocation. */
|
||||
#define RTLD_BOOTSTRAP
|
||||
#define RESOLVE(sym, reloc_addr, noplt) 0
|
||||
#include "dynamic-link.h"
|
||||
|
||||
|
||||
@@ -79,7 +81,7 @@ _dl_start (void *arg)
|
||||
/* Relocate ourselves so we can do normal function calls and
|
||||
data access using the global offset table. */
|
||||
|
||||
ELF_DYNAMIC_RELOCATE (&bootstrap_map, 0, NULL);
|
||||
ELF_DYNAMIC_RELOCATE (&bootstrap_map, 0);
|
||||
|
||||
|
||||
/* Now life is sane; we can call functions and access global data.
|
||||
|
||||
Reference in New Issue
Block a user