For unfathomable reasons, ipfilter abuses kernel data structures for its
own purposes. To pull this off, it defines _KERNEL before including the headers where these structures are defined. This leads to no end of trouble when some of these headers, or other headers that they include, change, as demonstrated by r180755. The quick fix in this particular case is to define _WANT_FILE instead of _KERNEL, conditional on __FreeBSD__. A better long-term fix is left as an exercise to the reader.
This commit is contained in:
parent
8f8e4f1bbb
commit
4cb5c18630
@ -33,15 +33,23 @@ typedef int boolean_t;
|
|||||||
# ifdef __NetBSD__
|
# ifdef __NetBSD__
|
||||||
# include <machine/lock.h>
|
# include <machine/lock.h>
|
||||||
# endif
|
# endif
|
||||||
# define _KERNEL
|
# ifdef __FreeBSD__
|
||||||
# define KERNEL
|
# define _WANT_FILE
|
||||||
|
# else
|
||||||
|
# define _KERNEL
|
||||||
|
# define KERNEL
|
||||||
|
# endif
|
||||||
# ifdef ultrix
|
# ifdef ultrix
|
||||||
# undef LOCORE
|
# undef LOCORE
|
||||||
# include <sys/smp_lock.h>
|
# include <sys/smp_lock.h>
|
||||||
# endif
|
# endif
|
||||||
# include <sys/file.h>
|
# include <sys/file.h>
|
||||||
# undef _KERNEL
|
# ifdef __FreeBSD__
|
||||||
# undef KERNEL
|
# undef _WANT_FILE
|
||||||
|
# else
|
||||||
|
# undef _KERNEL
|
||||||
|
# undef KERNEL
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
#include <nlist.h>
|
#include <nlist.h>
|
||||||
#include <sys/user.h>
|
#include <sys/user.h>
|
||||||
|
Loading…
Reference in New Issue
Block a user