diff options
| author | Warner Losh <imp@FreeBSD.org> | 2023-03-22 02:25:58 +0000 |
|---|---|---|
| committer | Warner Losh <imp@FreeBSD.org> | 2023-03-23 06:39:30 +0000 |
| commit | d08ffbd70e7245f94af4b103f64c7ecab6da9d7f (patch) | |
| tree | 8d02add76294b92e2badacc90a621194b6804e14 /sys | |
| parent | af28d08bda99d7a841743f75d736cf677ab0ad0e (diff) | |
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/sys/_endian.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/sys/_endian.h b/sys/sys/_endian.h index 7ac39386e2e1..3b4460472eb6 100644 --- a/sys/sys/_endian.h +++ b/sys/sys/_endian.h @@ -36,6 +36,8 @@ #error "sys/_endian.h should not be included directly" #endif +#include <sys/cdefs.h> /* visibility macros */ + /* BSD Compatiblity */ #define _BYTE_ORDER __BYTE_ORDER__ @@ -66,10 +68,11 @@ #endif /* - * Deprecated variants that don't have enough underscores to be useful in more - * strict namespaces. + * POSIX Issue 8 will require these for endian.h. Define them there and in the + * traditional BSD compilation environment. Since issue 8 doesn't yet have an + * assigned date, use strictly greater than issue 7's date. */ -#if __BSD_VISIBLE +#if __BSD_VISIBLE || _POSIX_C_SOURCE > 200809 #define LITTLE_ENDIAN _LITTLE_ENDIAN #define BIG_ENDIAN _BIG_ENDIAN #define PDP_ENDIAN _PDP_ENDIAN |
