Subversion Repositories HelenOS

Compare Revisions

Ignore whitespace Rev 2981 → Rev 2982

/branches/dynload/uspace/app/dltest/dltest.c
34,12 → 34,8
* @file
*/
 
#include <libtest.h>
#include <stdio.h>
 
void __io_init(void);
void __main(void);
void __exit(void);
 
static void kputint(unsigned i)
{
unsigned dummy;
52,36 → 48,16
);
}
 
 
/*static void test(void)
int main(int argc, char *argv[])
{
kputint(-1);
kputint(42);
kputint(0x100);
printf("Hello from dltest!\n");
kputint(0x200);
while(1);
}*/
 
int main(int argc, char *argv[])
{
// test();
/* Unreachable, yet. Just to create a relocation entry */
test_func();
return 0;
}
 
void __io_init(void)
{
}
 
void __main(void)
{
main(0, 0);
}
 
void __exit(void)
{
}
 
 
/** @}
*/
 
/branches/dynload/uspace/app/dltest/Makefile
34,13 → 34,14
 
LIBC_PREFIX = ../../lib/libc
SOFTINT_PREFIX = ../../lib/softint
RTLD_PREFIX = ../../lib/rtld
include $(LIBC_PREFIX)/Makefile.toolchain
 
CFLAGS += -I../../lib/libtest -O0
LFLAGS := -Bdynamic -I/rtld.so
CFLAGS += -I../../lib/libc -O0
LFLAGS := -Bdynamic -I/rtld.so -rpath-link $(RTLD_PREFIX)
 
# LIBS = $(LIBC_PREFIX)/libc.a
LIBS = ../../lib/libtest/libtest.so.0
LIBS = ../../lib/libc-shared/libc.so.0
DEFS += -DRELEASE=\"$(RELEASE)\"
 
ifdef REVISION