[Barrelfish-users] New version of glibc?

Kornilios Kourtis kornilios.kourtis at inf.ethz.ch
Tue Oct 23 16:06:01 CEST 2012

Hi Robert,

On Tue, Oct 23, 2012 at 03:26:35PM +0200, Robert Radkiewicz wrote:
> I managed to get the newlib into the barrelfish-tree and compiling it
> with hake, but the problems arise when parts of barrelfish are
> compiled and the definitions of functions or variables don't fit
> together. I'm not an expert in the libc, I'm just using it, so I
> think I have to shift that part to the future for the moment.
> I am even unsure, if the problem I had in the first place would be
> solved, because I stepped over some compiling errors there.

Since you are planning to use newlib, have you considered porting
barrelfish's newlib to your architecture? From what I remember, you only
need setjmp routines, since for everything else newlib has C versions.
You can probably find a ready to use setjmp assembly file in your newlib

> I get some wrong values when printing (!) 64 bit characters which are
> lying on the stack, the lower or upper 32 bits maybe cluttered.
> Printing it 32-bit wise works. I guess some of the definitions for
> the data type are not consistent, because I need to specify an "l" as
> printf-argument for printing a uint32_t variable, which should not be
> necessary. The sizeof-from all the types give the expected values. So
> far I did not notice any wrong calculations with 64bit-values.
> Any suggestions where to search?

The portable way to print uint32_t is to use PRIu32, so the fact that you
need to specify the "l" modifier is not necessarily a bug. For printing
64-bit values, I remember having some similar problems, which were solved
by adding the following defines:


Kornilios Kourtis

More information about the Barrelfish-users mailing list