From decde27a8de0953d402df2db3716543b213b9755 Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Sat, 9 Feb 2019 16:48:54 -0500 Subject: add POSIX.2 identifiers --- src/unistd/_POSIX2_C_VERSION.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/unistd/_POSIX2_C_VERSION.c (limited to 'src/unistd/_POSIX2_C_VERSION.c') diff --git a/src/unistd/_POSIX2_C_VERSION.c b/src/unistd/_POSIX2_C_VERSION.c new file mode 100644 index 00000000..44c9a0ba --- /dev/null +++ b/src/unistd/_POSIX2_C_VERSION.c @@ -0,0 +1,20 @@ +#include + +#if (defined _POSIX_C_SOURCE) +#if _POSIX_C_SOURCE >= 200809L +#define _POSIX2_C_VERSION (200809L) +#elif _POSIX_C_SOURCE >= 200112L +#define _POSIX2_C_VERSION (200112L) +#elif _POSIX_C_SOURCE >= 199506L +#define _POSIX2_C_VERSION (199506L) +#elif _POSIX_C_SOURCE >= 2 +#define _POSIX2_C_VERSION (199209L) +#else +#undef _POSIX2_C_VERSION +#endif +#endif + +/* +POSIX(2) +*/ + -- cgit v1.2.1