Changeset 7fb3f1c in mainline


Ignore:
Timestamp:
2011-04-30T20:22:35Z (13 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5b72635
Parents:
2ca5f632
Message:

Make all architectures buildable. Only allow enabling dynamic linking on ia32.

Files:
10 edited

Legend:

Unmodified
Added
Removed
  • HelenOS.config

    r2ca5f632 r7fb3f1c  
    528528! [PLATFORM=sparc64&MACHINE=generic] CONFIG_AOUT_ISOFS_B (y)
    529529
     530% Dynamic linking support
     531! [PLATFORM=ia32] CONFIG_RTLD (n/y)
     532! [PLATFORM=abs32le|PLATFORM=amd64|PLATFORM=arm32|PLATFORM=ia64|PLATFORM=mips32|PLATFORM=ppc32|PLATFORM=sparc64] CONFIG_RTLD (n)
     533
    530534% Build shared libraries
    531 ! CONFIG_BUILD_SHARED_LIBS (y/n)
     535! [CONFIG_RTLD=y] CONFIG_BUILD_SHARED_LIBS (n/y)
     536! [CONFIG_RTLD=n] CONFIG_BUILD_SHARED_LIBS (n)
    532537
    533538% Link against shared libraries
  • boot/Makefile.common

    r2ca5f632 r7fb3f1c  
    118118RD_DRV_CFG =
    119119
    120 RD_LIBS = \
    121         $(USPACE_PATH)/lib/test/libtest.so.0
     120RD_LIBS =
     121
     122ifeq ($(CONFIG_RTLD), y)
     123        RD_LIBS += $(USPACE_PATH)/lib/test/libtest.so.0
     124endif
    122125
    123126ifeq ($(CONFIG_BUILD_SHARED_LIBS), y)
  • defaults/ia32/Makefile.config

    r2ca5f632 r7fb3f1c  
    6565CONFIG_VESA_BPP = 16
    6666
    67 # Build shared libraries
    68 CONFIG_BUILD_SHARED_LIBS = y
    69 
    70 # Link against shared libraries
    71 CONFIG_USE_SHARED_LIBS = y
    72 
    7367# Load disk drivers on startup
    7468CONFIG_START_BD = n
  • defaults/mips32/Makefile.config

    r2ca5f632 r7fb3f1c  
    4141CONFIG_HID_OUT = generic
    4242
    43 # Build shared libraries
    44 CONFIG_BUILD_SHARED_LIBS = n
    45 
    4643# Load disk drivers on startup
    4744CONFIG_START_BD = n
  • defaults/ppc32/Makefile.config

    r2ca5f632 r7fb3f1c  
    4141CONFIG_BAT = y
    4242
    43 # Build shared libraries
    44 CONFIG_BUILD_SHARED_LIBS = n
    45 
    4643# Load disk drivers on startup
    4744CONFIG_START_BD = n
  • uspace/Makefile

    r2ca5f632 r7fb3f1c  
    3535DIRS = \
    3636        app/bdsh \
    37         app/dltest2 \
    3837        app/edit \
    3938        app/getterm \
     
    9695ifeq ($(CONFIG_BUILD_SHARED_LIBS), y)
    9796        DIRS += \
    98                 app/dltest
     97                app/dltest \
     98                app/dltest2
    9999endif
    100100
  • uspace/Makefile.common

    r2ca5f632 r7fb3f1c  
    7373endif
    7474
    75 ifneq ($(SLIBRARY),)
    76         LARCHIVE = $(LIBRARY).la
    77         LOUTPUT = $(SLIBRARY)
    78         EXTRA_OUTPUT += $(LOUTPUT).disasm
    79         EXTRA_CLEAN += $(LOUTPUT).map $(LOUTPUT).ldisasm \
    80             $(LIBC_PREFIX)/shared/arch/$(UARCH)/_lib.ld
     75ifeq ($(CONFIG_BUILD_SHARED_LIBS), y)
     76        ifneq ($(SLIBRARY),)
     77                LARCHIVE = $(LIBRARY).la
     78                LOUTPUT = $(SLIBRARY)
     79                EXTRA_OUTPUT += $(LOUTPUT).disasm
     80                EXTRA_CLEAN += $(LOUTPUT).map $(LOUTPUT).ldisasm \
     81                    $(LIBC_PREFIX)/shared/arch/$(UARCH)/_lib.ld
     82        endif
    8183endif
    8284
  • uspace/lib/c/Makefile

    r2ca5f632 r7fb3f1c  
    7171        generic/device/hw_res.c \
    7272        generic/device/char_dev.c \
    73         generic/dlfcn.c \
    7473        generic/event.c \
    7574        generic/errno.c \
     
    126125        generic/sort.c \
    127126        generic/stats.c \
    128         generic/assert.c \
    129         rtld/rtld.c \
    130         rtld/elf_load.c \
    131         rtld/dynamic.c \
    132         rtld/module.c \
    133         rtld/symbol.c
     127        generic/assert.c
     128
     129ifeq ($(CONFIG_RTLD), y)
     130        GENERIC_SOURCES += \
     131                generic/dlfcn.c \
     132                rtld/rtld.c \
     133                rtld/elf_load.c \
     134                rtld/dynamic.c \
     135                rtld/module.c \
     136                rtld/symbol.c
     137endif
    134138
    135139SOURCES = \
  • uspace/lib/c/generic/libc.c

    r2ca5f632 r7fb3f1c  
    5353#include "private/io.h"
    5454
     55#ifdef CONFIG_RTLD
    5556/* From librtld. */
    5657#include <rtld.h>
     58#endif
    5759//#include <string.h>
    5860
  • uspace/srv/loader/main.c

    r2ca5f632 r7fb3f1c  
    6565
    6666/* From librtld */
     67#ifdef CONFIG_RTLD
    6768#include <rtld.h>
    6869#include <dynamic.h>
     
    7071#include <module.h>
    7172
     73static int ldr_load_dyn_linked(elf_info_t *p_info);
     74#endif
     75
    7276#define DPRINTF(...)
    73 
    74 static int ldr_load_dyn_linked(elf_info_t *p_info);
    7577
    7678/** Pathname of the file that will be loaded */
     
    102104static bool connected = false;
    103105
     106#ifdef CONFIG_RTLD
    104107/** State structure of the dynamic linker. */
    105108runtime_env_t dload_re;
    106109static module_t prog_mod;
     110#endif
    107111
    108112static void ldr_get_taskid(ipc_callid_t rid, ipc_call_t *request)
     
    317321       
    318322        DPRINTF("Binary is dynamically linked.\n");
     323#ifdef CONFIG_RTLD
    319324        DPRINTF(" - pcb address: %p\n", &pcb);
    320325        DPRINTF( "- prog dynamic: %p\n", prog_info.dynamic);
    321326
    322327        rc = ldr_load_dyn_linked(&prog_info);
    323 
     328#else
     329        rc = ENOTSUP;
     330#endif
    324331        async_answer_0(rid, rc);
    325332        return 0;
    326333}
     334
     335#ifdef CONFIG_RTLD
    327336
    328337static int ldr_load_dyn_linked(elf_info_t *p_info)
     
    372381        return 0;
    373382}
     383#endif
    374384
    375385/** Run the previously loaded program.
Note: See TracChangeset for help on using the changeset viewer.