From nobody@FreeBSD.org  Wed Oct  7 14:55:02 2009
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id BD1321065679
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  7 Oct 2009 14:55:02 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id ACBCD8FC14
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  7 Oct 2009 14:55:02 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n97Et2HQ094888
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 7 Oct 2009 14:55:02 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id n97Et1dM094875;
	Wed, 7 Oct 2009 14:55:01 GMT
	(envelope-from nobody)
Message-Id: <200910071455.n97Et1dM094875@www.freebsd.org>
Date: Wed, 7 Oct 2009 14:55:01 GMT
From: Sergey Kuritsin <kuritsin_s_v@mail.ru>
To: freebsd-gnats-submit@FreeBSD.org
Subject: absense of AUE_NULL
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         139403
>Category:       kern
>Synopsis:       [headers] absense of AUE_NULL
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Oct 07 15:00:09 UTC 2009
>Closed-Date:    
>Last-Modified:  Sun Jul 18 19:59:00 UTC 2010
>Originator:     Sergey Kuritsin
>Release:        FreeBSD-8.0RC1
>Organization:
Urals State University
>Environment:
FreeBSD dev.localdomain 8.0-RC1 FreeBSD 8.0-RC1 #0: Thu Sep 17 20:45:19 UTC 2009 root@almeida.cse.buffalo.edu:/usr/obj/usr/src/GENERIC i386
>Description:
There is no definition of AUE_NULL constant in sys/sysent.h (or in bsm/audit.h). When you include in source file sys/sysent.h header compiler says that thereis no definition of AUE_NULL. 
>How-To-Repeat:
Use in your code macro SYSCALL_MODULE form sys/sysent.h


>Fix:
It can be fixed by adding #define AUE_NULL 0 in bsm/audit.h for example. 

>Release-Note:
>Audit-Trail:
From: =?koi8-r?B?88XSx8XKIOvV0snDyc4=?= <kuritsin_s_v@mail.ru>
To: <bug-followup@FreeBSD.org>
Subject: Re: i386/139403: absense of AUE_NULL
Date: Wed, 7 Oct 2009 11:17:51 -0400

To fix it header bsm/audit_kevents.h must be included in bsm/audit.h or
in sys/sysent.h

From: Bruce Evans <brde@optusnet.com.au>
To: Sergey Kuritsin <kuritsin_s_v@mail.ru>
Cc: freebsd-gnats-submit@FreeBSD.org, freebsd-i386@FreeBSD.org
Subject: Re: i386/139403: absense of AUE_NULL
Date: Thu, 8 Oct 2009 10:02:50 +1100 (EST)

 On Wed, 7 Oct 2009, Sergey Kuritsin wrote:
 
 >> Description:
 > There is no definition of AUE_NULL constant in sys/sysent.h (or in bsm/audit.h). When you include in source file sys/sysent.h header compiler says that thereis no definition of AUE_NULL.
 >> How-To-Repeat:
 > Use in your code macro SYSCALL_MODULE form sys/sysent.h
 >
 >
 >> Fix:
 > It can be fixed by adding #define AUE_NULL 0 in bsm/audit.h for example.
 
 Here is my old mail about this bug and related messes in headers.
 
 I'm trying to build an old module under FreeBSD-7.  It failed to compile
 because SYSCALL_MODULE() uses AUE_NULL which is never defined despite
 massive namespace pollution (#include <bsm/audit.h>) in <sys/sysent.h>.
 AUE_NULL is defined in <bsm/audit_kevents.h> but the pollution doesn't
 extend that far.  <sys/sysent.h> seems to use only au_event_t directly
 from bsm, and only AUE_NULL indirectly from bsm.
 
 The <bsm/audit_kevents.h> pollution is machine-generated into
 <sys/sysproto.h> together with lots of other pollution.  Most of
 the original pollution in <sys/sysproto.h> is unnecessary now that
 there is a non-polluting header for sigset_t, but there is now
 about 10 times as much as when I started cleaning it up.  I still
 remove it all in my version using the following hack:
 
 <hack deleted>
 
 The FreeBSD-7 sysproto.h seems to use only AUE_NULL from
 <bsm/audit_kevents.h>.  That is a lot of pollution for a fancy spelling of 0.
 
 Bruce
Responsible-Changed-From-To: freebsd-i386->freebsd-bugs 
Responsible-Changed-By: gavin 
Responsible-Changed-When: Fri Oct 9 08:31:41 UTC 2009 
Responsible-Changed-Why:  
Not i386 specific 

http://www.freebsd.org/cgi/query-pr.cgi?pr=139403 
>Unformatted:
