Index: sys/sys/cdefs.h =================================================================== --- sys/sys/cdefs.h +++ sys/sys/cdefs.h @@ -718,6 +718,19 @@ #define __POSIX_VISIBLE 198808 #define __ISO_C_VISIBLE 0 #endif /* _POSIX_C_SOURCE */ +/* + * glibc enables c11 features when _ISOC11_SOURCE is defined, or when compiling + * with -stdc=c11. It's not clear that doing this automatically is standard's + * complaint. However, definning _ISOC11_SOURCE to enable is compatible with + * glibc; standards complaint; and easy enough to do to enable. We implement + * this glibc extension, though it has not yet been standardized. The POSIX-1 + * standards allow enabling additional interfaces only when certain feature test + * macros are defined. + */ +#if _ISOC11_SOURCE +#undef __ISO_C_VISIBLE +#define __ISO_C_VISIBLE 2011 +#endif #else /*- * Deal with _ANSI_SOURCE: