Re: Why 'linux/fs.h' cannot be included? I *can*...

From: Keith Owens (kaos@ocs.com.au)
Date: Wed Jan 30 2002 - 20:51:50 EST


On Wed, 30 Jan 2002 20:17:54 -0500,
Jeff Garzik <garzik@havoc.gtf.org> wrote:
>On Thu, Jan 31, 2002 at 10:33:46AM +1100, Keith Owens wrote:
>> On Wed, 30 Jan 2002 13:24:22 -0500,
>> Pete Zaitcev <zaitcev@redhat.com> wrote:
>> >Kernel headers are not to be included in applications.
>>
>> Just to flog this dead horse into the ground, the reverse is also true.
>> Kernel code must not include user space headers (kernel code excludes
>> programs that are used to build the kernel).
>
>Wow, does that actually occur? File references?

It slips in occasionally. LVM in 2.4.0-test had #include <endian.h>, I
vaguely remember some compression code that included glibc headers by
mistake. We weed them out of the kernel whenever we spot them, they
tend not to live very long. Christoph Hellwig suggested a Makefile
change that prevents kernel code including user space headers, it is
included in kbuild 2.5 and there is a 2.4 version in

http://marc.theaimsgroup.com/?l=linux-kernel&m=100321690511549&w=2

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Jan 31 2002 - 21:01:29 EST