This is the mail archive of the
libc-hacker@sourceware.cygnus.com
mailing list for the glibc project.
Can we use -ansi with -D_POSIX_SOURCE?
- To: roland@frob.com
- Subject: Can we use -ansi with -D_POSIX_SOURCE?
- From: hjl@lucon.org (H.J. Lu)
- Date: Mon, 26 Oct 1998 14:27:45 -0800 (PST)
- Cc: libc-hacker@cygnus.com (GNU C Library)
# gcc x.c -D_POSIX_SOURCE -ansi
# a.out
1000000: 100
How do we fix it? It is quite confusing. We define CLK_TCK to different
values in /usr/include/time.h and /usr/include/bits/time.h.
--
H.J. Lu (hjl@gnu.org)
---
#include <time.h>
#include <unistd.h>
main ()
{
printf ("%ld: %ld\n", CLK_TCK, sysconf(_SC_CLK_TCK));
}