Changeset 8a1fb09 in mainline


Ignore:
Timestamp:
2011-05-01T12:10:47Z (14 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9fb1397
Parents:
d2a6a04b
Message:

Integrate rest of rtld/ into C library.

Location:
uspace
Files:
1 added
1 deleted
17 edited
11 moved

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/Makefile

    rd2a6a04b r8a1fb09  
    5959-include arch/$(UARCH)/Makefile.inc
    6060
    61 EXTRA_CFLAGS += -Irtld/include -I../../srv/loader/include
     61EXTRA_CFLAGS += -I../../srv/loader/include
    6262
    6363GENERIC_SOURCES = \
     
    130130        GENERIC_SOURCES += \
    131131                generic/dlfcn.c \
    132                 rtld/rtld.c \
    133                 rtld/elf_load.c \
    134                 rtld/dynamic.c \
    135                 rtld/module.c \
    136                 rtld/symbol.c
     132                generic/rtld/rtld.c \
     133                generic/rtld/elf_load.c \
     134                generic/rtld/dynamic.c \
     135                generic/rtld/module.c \
     136                generic/rtld/symbol.c
    137137endif
    138138
  • uspace/lib/c/arch/ia32/include/rtld/dynamic.h

    rd2a6a04b r8a1fb09  
    3333 */
    3434
    35 #ifndef ia32_DYNAMIC_H_
    36 #define ia32_DYNAMIC_H_
     35#ifndef LIBC_ia32_RTLD_DYNAMIC_H_
     36#define LIBC_ia32_RTLD_DYNAMIC_H_
    3737
    3838#include <sys/types.h>
  • uspace/lib/c/arch/ia32/include/rtld/elf_dyn.h

    rd2a6a04b r8a1fb09  
    3333 */
    3434
    35 #ifndef ia32_ELF_DYN_H_
    36 #define ia32_ELF_DYN_H_
     35#ifndef LIBC_ia32_RTLD_ELF_DYN_H_
     36#define LIBC_ia32_RTLD_ELF_DYN_H_
    3737
    3838/*
  • uspace/lib/c/arch/ia32/src/rtld/dynamic.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcia32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
     
    3838#include <stdlib.h>
    3939
    40 #include <elf_dyn.h>
    41 #include <dynamic.h>
     40#include <rtld/elf_dyn.h>
     41#include <rtld/dynamic.h>
    4242
    4343void dyn_parse_arch(elf_dyn_t *dp, size_t bias, dyn_info_t *info)
  • uspace/lib/c/arch/ia32/src/rtld/reloc.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcia32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
     
    3939
    4040#include <libarch/rtld/elf_dyn.h>
    41 #include <symbol.h>
    42 #include <rtld.h>
    43 #include <rtld_debug.h>
    44 
    45 #include <rtld_arch.h>
     41#include <rtld/symbol.h>
     42#include <rtld/rtld.h>
     43#include <rtld/rtld_debug.h>
     44#include <rtld/rtld_arch.h>
    4645
    4746void module_process_pre_arch(module_t *m)
  • uspace/lib/c/arch/mips32/include/rtld/dynamic.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libcmips32
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef mips32_DYNAMIC_H_
    36 #define mips32_DYNAMIC_H_
     35#ifndef LIBC_mips32_RTLD_DYNAMIC_H_
     36#define LIBC_mips32_RTLD_DYNAMIC_H_
    3737
    3838#include <sys/types.h>
  • uspace/lib/c/arch/mips32/include/rtld/elf_dyn.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libcmips32
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef mips32_ELF_DYN_H_
    36 #define mips32_ELF_DYN_H_
     35#ifndef LIBC_mips32_RTLD_ELF_DYN_H_
     36#define LIBC_mips32_RTLD_ELF_DYN_H_
    3737
    3838/*
  • uspace/lib/c/arch/mips32/src/rtld/dynamic.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcmips32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
  • uspace/lib/c/arch/mips32/src/rtld/reloc.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcmips32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
  • uspace/lib/c/arch/ppc32/include/rtld/dynamic.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libcppc32
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef ppc32_DYNAMIC_H_
    36 #define ppc32_DYNAMIC_H_
     35#ifndef LIBC_ppc32_RTLD_DYNAMIC_H_
     36#define LIBC_ppc32_RTLD_DYNAMIC_H_
    3737
    3838#include <sys/types.h>
  • uspace/lib/c/arch/ppc32/include/rtld/elf_dyn.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libcppc32
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef ppc32_ELF_DYN_H_
    36 #define ppc32_ELF_DYN_H_
     35#ifndef LIBC_ppc32_RTLD_ELF_DYN_H_
     36#define LIBC_ppc32_RTLD_ELF_DYN_H_
    3737
    38 /* 
     38/*
    3939 * ppc32 dynamic relocation types
    4040 */
  • uspace/lib/c/arch/ppc32/src/rtld/dynamic.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcppc32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
  • uspace/lib/c/arch/ppc32/src/rtld/reloc.c

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup rtld rtld
     29/** @addtogroup libcppc32
    3030 * @brief
    3131 * @{
    32  */ 
     32 */
    3333/**
    3434 * @file
  • uspace/lib/c/generic/dlfcn.c

    rd2a6a04b r8a1fb09  
    3939#include <dlfcn.h>
    4040
    41 /* From librtld. */
    42 #include <module.h>
    43 #include <symbol.h>
     41#include <rtld/module.h>
     42#include <rtld/symbol.h>
    4443
    4544void *dlopen(const char *path, int flag)
  • uspace/lib/c/generic/libc.c

    rd2a6a04b r8a1fb09  
    5454
    5555#ifdef CONFIG_RTLD
    56 /* From librtld. */
    57 #include <rtld.h>
     56#include <rtld/rtld.h>
    5857#endif
    59 //#include <string.h>
    6058
    6159static bool env_setup = false;
  • uspace/lib/c/generic/rtld/dynamic.c

    rd2a6a04b r8a1fb09  
    3636
    3737#include <stdio.h>
    38 //#include <string.h>
    3938
    40 #include <elf_dyn.h>
    41 #include <dynamic.h>
    42 #include <rtld.h>
    43 #include <rtld_debug.h>
     39#include <rtld/elf_dyn.h>
     40#include <rtld/dynamic.h>
     41#include <rtld/rtld.h>
     42#include <rtld/rtld_debug.h>
    4443
    4544void dynamic_parse(elf_dyn_t *dyn_ptr, size_t bias, dyn_info_t *info)
  • uspace/lib/c/generic/rtld/module.c

    rd2a6a04b r8a1fb09  
    4242#include <loader/pcb.h>
    4343
    44 #include <rtld.h>
    45 #include <rtld_debug.h>
    46 #include <dynamic.h>
     44#include <rtld/rtld.h>
     45#include <rtld/rtld_debug.h>
     46#include <rtld/dynamic.h>
     47#include <rtld/rtld_arch.h>
     48#include <rtld/module.h>
    4749#include <elf_load.h>
    48 #include <rtld_arch.h>
    49 #include <module.h>
    5050
    5151/** (Eagerly) process all relocation tables in a module.
  • uspace/lib/c/generic/rtld/rtld.c

    rd2a6a04b r8a1fb09  
    3535 */
    3636
    37 #include <rtld.h>
     37#include <rtld/rtld.h>
    3838
    3939runtime_env_t *runtime_env;
  • uspace/lib/c/generic/rtld/symbol.c

    rd2a6a04b r8a1fb09  
    3737#include <stdio.h>
    3838#include <stdlib.h>
    39 //#include <string.h>
    40 
    41 #include <rtld.h>
    42 #include <rtld_debug.h>
    43 #include <symbol.h>
     39
     40#include <rtld/rtld.h>
     41#include <rtld/rtld_debug.h>
     42#include <rtld/symbol.h>
    4443#include <elf.h>
    4544
  • uspace/lib/c/include/rtld/dynamic.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef DYNAMIC_H_
    36 #define DYNAMIC_H_
     35#ifndef LIBC_RTLD_DYNAMIC_H_
     36#define LIBC_RTLD_DYNAMIC_H_
    3737
    3838#include <bool.h>
    39 #include <elf_dyn.h>
     39#include <rtld/elf_dyn.h>
    4040#include <libarch/rtld/dynamic.h>
    4141
  • uspace/lib/c/include/rtld/elf_dyn.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef ELF_DYN_H_
    36 #define ELF_DYN_H_
     35#ifndef LIBC_RTLD_ELF_DYN_H_
     36#define LIBC_RTLD_ELF_DYN_H_
    3737
    3838#include <arch/elf.h>
  • uspace/lib/c/include/rtld/module.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef MODULE_H_
    36 #define MODULE_H_
     35#ifndef LIBC_RTLD_MODULE_H_
     36#define LIBC_RTLD_MODULE_H_
    3737
    3838#include <sys/types.h>
    39 #include <dynamic.h>
     39#include <rtld/dynamic.h>
    4040#include <adt/list.h>
    4141
  • uspace/lib/c/include/rtld/rtld.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef RTLD_H_
    36 #define RTLD_H_
     35#ifndef LIBC_RTLD_H_
     36#define LIBC_RTLD_H_
    3737
    3838#include <sys/types.h>
    3939#include <adt/list.h>
    4040
    41 #include <dynamic.h>
    42 #include <module.h>
     41#include <rtld/dynamic.h>
     42#include <rtld/module.h>
    4343
    4444typedef struct {
  • uspace/lib/c/include/rtld/rtld_arch.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef RTLD_ARCH_H_
    36 #define RTLD_ARCH_H_
     35#ifndef LIBC_RTLD_RTLD_ARCH_H_
     36#define LIBC_RTLD_RTLD_ARCH_H_
    3737
    38 #include <rtld.h>
     38#include <rtld/rtld.h>
    3939#include <loader/pcb.h>
    4040
  • uspace/lib/c/include/rtld/rtld_debug.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef RTLD_DEBUG_H_
    36 #define RTLD_DEBUG_H_
     35#ifndef LIBC_RTLD_RTLD_DEBUG_H_
     36#define LIBC_RTLD_RTLD_DEBUG_H_
    3737
    3838/* Define to enable debugging mode. */
  • uspace/lib/c/include/rtld/symbol.h

    rd2a6a04b r8a1fb09  
    2727 */
    2828
    29 /** @addtogroup generic
     29/** @addtogroup libc
    3030 * @{
    3131 */
     
    3333 */
    3434
    35 #ifndef SYMBOL_H_
    36 #define SYMBOL_H_
     35#ifndef LIBC_RTLD_SYMBOL_H_
     36#define LIBC_RTLD_SYMBOL_H_
    3737
    38 #include <rtld.h>
     38#include <rtld/rtld.h>
    3939#include <elf.h>
    4040
  • uspace/srv/loader/Makefile

    rd2a6a04b r8a1fb09  
    3939LINKER_SCRIPT = $(LIBC_PREFIX)/arch/$(UARCH)/_link-loader.ld
    4040
    41 EXTRA_CFLAGS = -Iinclude -I../../lib/c/rtld/include
     41EXTRA_CFLAGS = -Iinclude
    4242
    4343BINARY = loader
  • uspace/srv/loader/main.c

    rd2a6a04b r8a1fb09  
    6464#include <elf_load.h>
    6565
    66 /* From librtld */
    6766#ifdef CONFIG_RTLD
    68 #include <rtld.h>
    69 #include <dynamic.h>
    70 #include <elf_load.h>
    71 #include <module.h>
     67#include <rtld/rtld.h>
     68#include <rtld/dynamic.h>
     69#include <rtld/module.h>
    7270
    7371static int ldr_load_dyn_linked(elf_info_t *p_info);
Note: See TracChangeset for help on using the changeset viewer.