[klibc] Patch to klibc to work with headers from make install_headers

H. Peter Anvin hpa at zytor.com
Tue Dec 26 08:21:07 PST 2006

Colin Watson wrote:
> On Tue, Dec 19, 2006 at 10:49:30PM -0500, Jeff Bailey wrote:
>> Hi!  Now that there are usable userspace headers, we should use the
>> data from those.  In this case, the workaround in
>> usr/include/sys/types.h was missing some header definitions.  Rather
>> than adding the definitions, I figured that the most correct thing to
>> do was to just use them from the kernel.
> FYI, this broke fstype on Ubuntu because klibc's internal
> usr/include/sys/types.h has "typedef __kernel_loff_t off_t;" (sic)
> whereas <linux/types.h> has "typedef __kernel_off_t off_t;", and
> usr/klibc/SYSCALLS.def uses off_t for a bunch of syscalls with 32/64-bit
> alternatives where the kernel uses loff_t for the 64-bit version.
> Changing these all to loff_t might work, since that's what the kernel
> was doing anyway, but in the meantime I just backed out the patch from
> Ubuntu.

Yes, and that's because in the the klibc context, off_t *is* 
__kernel_loff_t, not __kernel_off_t.  This is, in fact, critically 
important to proper operation (klibc is *always* 64-bit clean.)

So the patch is wrong.


More information about the klibc mailing list