Re: 2.1.31 doesn't build on Intel with glibc

Martin von Loewis (
Sun, 6 Apr 1997 13:05:22 +0200

> > Compilation of arch/i386/boot/compressed/misc.c fails with 2.1.31
> [...]
> > A fudge is to move the #include <string.h> until after the two #include
> > <asm/...> lines in misc.c.
> Here it is as a diff against 2.1.32:
> --- linux/arch/i386/boot/compressed/misc.c.orig Fri Mar 28 13:49:15 1997

I don't understand. <string.h> is a C library header file. C library
headers should *never* be included into kernel mode code. So the first
step is to remove <string.h> from this file altogether.
Then, it fails because __ptr_t is not defined. This is IMHO an omission
in linux/types.h, but I'm not sure how to fix it so that this does not
get in the way of libc 5. So, a better hack instead of moving <string.h>
is IMHO to replace the include with
#define __ptr_t void*
or to replace the use of __ptr_t with void* altogether.


P.S. This discussion does not take into account that STANDALONE_DEBUG
might be defined. If it is, misc.c is a C library client, so things are
reversed, and misc.c should not include asm/io.h and asm/segment.h
if possible.