Removed rld0.c (more or less merged its contents with rld.c).

Renamed RLD_STARTUP() runtime_loader() - the new entry point of the loader.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@11943 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2005-03-21 19:11:12 +00:00
parent f7a818f980
commit cd6c2db413
6 changed files with 20 additions and 29 deletions

View File

@ -2,7 +2,6 @@ SubDir OBOS_TOP src kernel runtime_loader ;
KernelObjects
rld.c
rld0.c
rldexport.c
rldelf.c
rldheap.c
@ -48,7 +47,6 @@ KernelStaticLibraryObjects librld.a :
;
KernelLd rld.so :
<$(SOURCE_GRIST)>rld0.o
<$(SOURCE_GRIST)>rld.o
<$(SOURCE_GRIST)>rldelf.o
<$(SOURCE_GRIST)>rldexport.o

View File

@ -1,7 +1,7 @@
OUTPUT_FORMAT("elf32-powerpc", "elf32-powerpc", "elf32-powerpc")
OUTPUT_ARCH(powerpc)
ENTRY(RLD_STARTUP)
ENTRY(runtime_loader)
SEARCH_DIR("libgcc");
SECTIONS
{

View File

@ -1,7 +1,7 @@
OUTPUT_FORMAT("elf32-i386", "elf32-i386", "elf32-i386")
OUTPUT_ARCH(i386)
ENTRY(RLD_STARTUP)
ENTRY(runtime_loader)
SEARCH_DIR("libgcc");
SECTIONS
{

View File

@ -1,7 +1,10 @@
/*
** Copyright 2002, Manuel J. Petit. All rights reserved.
** Distributed under the terms of the NewOS License.
*/
* Copyright 2005, Axel Dörfler, axeld@pinc-software.de.
* Distributed under the terms of the MIT License.
*
* Copyright 2002, Manuel J. Petit. All rights reserved.
* Distributed under the terms of the NewOS License.
*/
#include <string.h>
@ -10,14 +13,23 @@
#include "rld_priv.h"
/** This is the main entry point of the runtime loader as
* specified by its ld-script.
*/
int
rldmain(void *_args)
runtime_loader(void *_args)
{
struct uspace_program_args *args = (struct uspace_program_args *)_args;
void *entry = 0;
rldheap_init();
#if DEBUG_RLD
close(0); open("/dev/console", 0); /* stdin */
close(1); open("/dev/console", 0); /* stdout */
close(2); open("/dev/console", 0); /* stderr */
#endif
rldheap_init();
rldexport_init(args);
rldelf_init(args);

View File

@ -1,18 +0,0 @@
/*
** Copyright 2002, Manuel J. Petit. All rights reserved.
** Distributed under the terms of the NewOS License.
*/
#include "rld_priv.h"
int RLD_STARTUP(void *args)
{
#if DEBUG_RLD
close(0); open("/dev/console", 0); /* stdin */
close(1); open("/dev/console", 0); /* stdout */
close(2); open("/dev/console", 0); /* stderr */
#endif
return rldmain(args);
}

View File

@ -12,8 +12,7 @@
#include <user_runtime.h>
int RLD_STARTUP(void *);
int rldmain(void *arg);
int runtime_loader(void *arg);
status_t unload_program(image_id imageID);
image_id load_program(char const *path, void **entry);