my kernel headers are hosed!
Klaus-Peter Schrage
kpschrage
Mon May 17 11:57:07 PDT 2004
Net Llama! wrote:
> Seems that I missed the memo long ago that ordered everyone to stop
> symlinking /usr/include/asm & /usr/include/linux into /usr/src/linux.
> So, i've continued to do that and now have discovered that its a bad
> thing because /usr/include/asm & /usr/include/linux should contain the
> headers used to build my current glibc, rather than the current kernel.
>
> My current glibc(-2.3.2) was built under kernel 2.4.22, so I thought
> that I could fix this mess with the following:
> cd /usr/src/linux-2.4.22
> make mrproper
> make include/linux/version.h
> make symlinks
> cp -HR include/asm /usr/include
> cp -R include/asm-generic /usr/include
> cp -R include/linux /usr/include
> touch /usr/include/linux/autoconf.h
>
> Unfortunately, that hasn't helped at all. Trying to buld anything that
> relies on the kernel headers is bombing out with an assortment of bad
> errors like:
>
> In file included from /usr/include/sys/wait.h:30,
> from xsystem.c:21:
> /usr/include/signal.h:27: error: conflicting types for `sigset_t'
> /usr/include/sys/select.h:38: error: previous declaration of `sigset_t'
> xsystem.c: In function `xsystem':
> xsystem.c:45: error: `errno' undeclared (first use in this function)
> xsystem.c:45: error: (Each undeclared identifier is reported only once
> xsystem.c:45: error: for each function it appears in.)
> make[1]: *** [xsystem.o] Error 1
>
>
> Surely there must be a way to fix this mess. Anyone?
I had a similar issue after I had reinstalled a fresh linux-2.4.23 into
/usr/src, nixing the one that was there before.
Nothing wanted to compile 'cause of lacking headers. I restored them by
a simple 'make xconfig' (perhaps I did a 'make dep' after that, don't
remember, but no need do a complete recompile ).
Klaus
More information about the Linux-users
mailing list