Date: Thu, 02 Jul 2020 01:33:32 +0000 From: bugzilla-noreply@freebsd.org To: standards@FreeBSD.org Subject: [Bug 247701] CLOCK_REALTIME is not visible when _XOPEN_SOURCE == 500 or _POSIX_C_SOURCE == 199506 Message-ID: <bug-247701-99@https.bugs.freebsd.org/bugzilla/>
index | next in thread | raw e-mail
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=247701 Bug ID: 247701 Summary: CLOCK_REALTIME is not visible when _XOPEN_SOURCE == 500 or _POSIX_C_SOURCE == 199506 Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: standards Assignee: standards@FreeBSD.org Reporter: jbeich@FreeBSD.org When old POSIX conformance is requested FreeBSD for some reason hides CLOCK_REALTIME to a later version. Issue 7: https://pubs.opengroup.org/onlinepubs/9699919799/functions/clock_getres.html https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/time.h.html Issue 5: https://pubs.opengroup.org/onlinepubs/007908799/xsh/clock_settime.html https://pubs.opengroup.org/onlinepubs/007908799/xsh/time.h.html $ cc a.c a.c:7:17: error: use of undeclared identifier 'CLOCK_REALTIME' clock_gettime(CLOCK_REALTIME, &tp); ^ 1 error generated. $ cat a.c #define _XOPEN_SOURCE 500 #include <time.h> int main() { struct timespec tp; clock_gettime(CLOCK_REALTIME, &tp); return 0; } -- You are receiving this mail because: You are the assignee for the bug.home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-247701-99>
