[Prev][Next][Index][Thread]

Re: Porting Oskit



> Date: Tue, 31 Jul 2001 12:13:11 +0530 (IST)
> From: Soumyadeb Mitra <csd97407@cse.iitd.ernet.in>
> To: <oskit-users@fast.cs.utah.edu>
> Subject: Porting Oskit
> 
> Hello
> 	I am trying to strip down OsKit(to port it to a new architecture).
> What I need is a basic C library with just printf & malloc.
> 	Has anyone stripped down the C library.How easy or difficult is it
> going to be?
> 
> 

The current "minimal" C library has evolved away from the hardware and
does have more dependencies than it used to.  I would suggest:

For printf, use the stuff in libc/stdio and you provide a
console_putbytes and console_putchar defined in terms of your architecture.

For malloc, its a little more involved.  You could start with the
libc/malloc code which relies on an oskit_mem interface.  The easiest
thing to do would be to provide an implementation of that interface
built on top the lmm functions.  clientos/mem.c provides such an
implemenetation.  This assumes you have the LMM library working which
is heavily tied up with libkern.