Re: some kernel headers broken in current git ?
- From: Sam Ravnborg <sam@xxxxxxxxxxxx>
- Date: Sun, 21 Oct 2007 22:02:14 +0200
On Sun, Oct 21, 2007 at 12:15:48PM -0700, H. Peter Anvin wrote:
Gabriel C wrote:No - it is a kernel module.
BITS_PER_LONG was originally set in <asm/types.h>:User land does not know anything about 'CONFIG_X86_32' right ?
39 #ifdef CONFIG_X86_32
40 # define BITS_PER_LONG 32
41 #else
42 # define BITS_PER_LONG 64
43 #endif
Wait... this is *user mode* code at this point?
But what a messy codebase to look at...
Linux kernel headers aren't includable from user space without
processing them through "make headers_install".
However, from looking at the filenames in your list, it doesn't look
like userspace code at all (although they're wrappered to the degree
that it's somewhat hard to tell.) Thus, you're building a kernel
module, not userland.
That is the problem. I've changed the headers virtualbox need from
#ifdef CONFIG_X86_32 to #ifdef __i386__ and all compiled fine.
( subarch headers includes are changed manually still but I think it is
the same problem )
Also all the headers got these defines with CONFIG_X86_32 does not work.
...
#ifdef CONFIG_X86_32
# include "foo_32.h"
#else
# include "foo_64.h"
#endif
...
results in including both header files on my i686 box.
I don't know what the right way is to fix that , define some who
CONFIG_X86_32 to __i386__ ? or just s/CONFIG_X86_32/__i386__/ ?
It sounds like something is seriously broken in your setup, or in the
VirtualBox makefiles. From the looks of it, I would say the latter.
From the file "the-linux-kernel.h":/*
* Include iprt/types.h to install the bool wrappers.
* Then use the linux bool type for all the stuff include here.
*/
#include <iprt/types.h>
#define bool linux_bool
And that file named "types.h" is not a kernel types.h - so we miss that
file. I guess it was pulled in by some other headerfile in the past.
But I also notice that it latest source from VirtualBox the
line number for include of spinlock-h does not match.
This is most likely a combination of VirtualBox doing strange strange things
and some deep dependency missing in one of the headerfiles.
Add a #include <linux/types.h> to the-linux-kernel.h and let us know if it helps.
Sam
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: some kernel headers broken in current git ?
- From: Gabriel C
- Re: some kernel headers broken in current git ?
- References:
- some kernel headers broken in current git ?
- From: Gabriel C
- Re: some kernel headers broken in current git ?
- From: H. Peter Anvin
- Re: some kernel headers broken in current git ?
- From: Gabriel C
- Re: some kernel headers broken in current git ?
- From: Gabriel C
- Re: some kernel headers broken in current git ?
- From: H. Peter Anvin
- some kernel headers broken in current git ?
- Prev by Date: [HP6XX] - no init found (PATA issue?)
- Next by Date: ISSC W89C35 802.11bg (was Re: rt73usb: support for wireless in Kohjinsha subnotebook)
- Previous by thread: Re: some kernel headers broken in current git ?
- Next by thread: Re: some kernel headers broken in current git ?
- Index(es):
Relevant Pages
|