Discussion:
C Library with L4 - Diet Libc library?
Håvard Ostnes
2012-04-18 13:11:42 UTC
Permalink
Hi!

I have googled around and saw someone mentioning that the
diet libc library could be used with L4 Pistachio.

I was wondering if someone knows how to successfully compile
an L4 application using the diet libc library.
(or another similar C library).

The reason is I need to use malloc and other functions in my application.

Best regards,
håvard ostnes
Jan Stoess
2012-04-23 08:36:42 UTC
Permalink
Hello Håvard,

Dietlibc should principally do, although not all functions may be supported without writing a proper backend for L4 akin to Linux backend. For instance, supporting pthreads on L4 through dietlibc will require you to map whatever dietlibc's backend for threads is onto L4 threads.

We had made use of dietlibc some time ago ourselves, for the afterburner project:
http://www.l4ka.org/projects/virtualization
but support was limited to those functions that do without a backend (eg. math functions).


Side note, if you're just looking for a malloc implementation, you may want to consider dlmalloc
ftp://g.oswego.edu/pub/misc/malloc.c

Best,
-Jan
--
Dr. Jan Stoess, KIT System Architecture Group
Phone: +49 (721) 6084 4056 Cell: / +49 (178) 149 5341
-----Original Message-----
karlsruhe.de] On Behalf Of Håvard Ostnes
Sent: Wednesday, April 18, 2012 3:12 PM
Subject: C Library with L4 - Diet Libc library?
Hi!
I have googled around and saw someone mentioning that the diet libc library
could be used with L4 Pistachio.
I was wondering if someone knows how to successfully compile an L4
application using the diet libc library.
(or another similar C library).
The reason is I need to use malloc and other functions in my application.
Loading...