git: dfce25edfb69 - main - cdesf: Support _POSIX_C_SOURCE 202405 for POSIX 2024
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 15 Nov 2024 02:02:07 UTC
The branch main has been updated by imp:
URL: https://cgit.FreeBSD.org/src/commit/?id=dfce25edfb696e19e532f44bcb8002ce21976a3e
commit dfce25edfb696e19e532f44bcb8002ce21976a3e
Author: Warner Losh <imp@FreeBSD.org>
AuthorDate: 2024-11-14 23:52:27 +0000
Commit: Warner Losh <imp@FreeBSD.org>
CommitDate: 2024-11-15 01:57:28 +0000
cdesf: Support _POSIX_C_SOURCE 202405 for POSIX 2024
Allow applications to request a strict POSIX 2024 by setting
_POSIX_C_SOURCE to 202405 or higher. The rest of the system needs tweaks
to be compliant, so this is a work in progress.
Sponsored by: Netflix
Reviewed by: brooks
Differential Revision: https://reviews.freebsd.org/D47575
---
sys/sys/cdefs.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h
index bafceb8cb9cb..25248bd235b2 100644
--- a/sys/sys/cdefs.h
+++ b/sys/sys/cdefs.h
@@ -542,7 +542,10 @@
#define _POSIX_C_SOURCE 198808
#endif
#ifdef _POSIX_C_SOURCE
-#if _POSIX_C_SOURCE >= 200809
+#if _POSIX_C_SOURCE >= 202405
+#define __POSIX_VISIBLE 202405
+#define __ISO_C_VISIBLE 2017
+#elif _POSIX_C_SOURCE >= 200809
#define __POSIX_VISIBLE 200809
#define __ISO_C_VISIBLE 1999
#elif _POSIX_C_SOURCE >= 200112