Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Nov 2002 11:21:52 -0600
From:      Kyle Martin <mkm@ieee.org>
To:        Kirk McKusick <mckusick@beastie.mckusick.com>
Cc:        arch@freebsd.org
Subject:   Re: Shared-memory version of <sys/queue.h> macros
Message-ID:  <20021112172152.GC15329@marvin.bsdng.org>
In-Reply-To: <200211112232.gABMW459037409@beastie.mckusick.com>
References:  <p05200f0db9f5d85c6d3e@[128.113.24.47]> <200211112232.gABMW459037409@beastie.mckusick.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Nov 11, 2002 at 02:32:04PM -0800, Kirk McKusick wrote:
> 
> Historically /usr/include/sys was used to include files that
> provided headers that included interfaces between the kernel
> and userland. For example, <sys/stat.h> describes that
> stat structure which is filled in by the kernel and used
> by userland applications. Since the queue macros do not
> describe any kernel/userland shared structures, they belong
> in /usr/include. They are much more like <stdio.h> which
> describes purely userland structures like FILE *. However,
> we canot move <sys/queue.h> from the /sys/sys directory as
> it is needed by the kernel (indeed was originally developed
> for the kernel) as there is another rule which says that
> the kernel headers need to be self contained (that is the
> kernel cannot depend on anything in /usr/include). So, there
> is the dilemma of duplicating the queue macros used in the
> kernel in a /usr/include file, or trying to avoid divergence
> by pulling in the kernel macros from /usr/include/sys. As
> for what userland applications should do, once <queue.h>
> exists, they should always use that file.
> 

perhaps "#include<sys/queue.h>" could appear in /usr/include/queue.h with
some typical #ifdef glue in <sys/queue.h>

-- 
Kyle Martin
mkm@ieee.org

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021112172152.GC15329>