diff options
author | Manuel Novoa III <mjn3@codepoet.org> | 2002-07-15 16:26:52 +0000 |
---|---|---|
committer | Manuel Novoa III <mjn3@codepoet.org> | 2002-07-15 16:26:52 +0000 |
commit | c96a844f5209ee078b282b1bec690f80f7411ada (patch) | |
tree | 19cd4a0fb42b17fbcc34304ae4ffa5385dccbdfd /libc/unistd/sysconf.c | |
parent | 8431a6f2e2585bbeb9de72939dd423b9f6a1d418 (diff) |
Clean up CLK_TCK situation. clock() and sysconf() now use an
arch-specific constant value defined in bits/uClibc_clk_tck.h.
Default is 100 (common/bits) but alpha uses 1024 following glibc.
Override per arch as necessary.
Diffstat (limited to 'libc/unistd/sysconf.c')
-rw-r--r-- | libc/unistd/sysconf.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/libc/unistd/sysconf.c b/libc/unistd/sysconf.c index 66b40aa03..89f1e7573 100644 --- a/libc/unistd/sysconf.c +++ b/libc/unistd/sysconf.c @@ -31,8 +31,8 @@ #include <sys/types.h> #include <regex.h> -#ifndef SYSTEM_CLK_TCK -# define SYSTEM_CLK_TCK 100 +#ifndef __UCLIBC_CLK_TCK_CONST +#error __UCLIBC_CLK_TCK_CONST not defined! #endif extern int getpagesize (void); @@ -94,7 +94,7 @@ long int __sysconf(int name) case _SC_CLK_TCK: /* Can't use CLK_TCK here since that calls __sysconf(_SC_CLK_TCK) */ - return SYSTEM_CLK_TCK; + return __UCLIBC_CLK_TCK_CONST; case _SC_NGROUPS_MAX: #ifdef NGROUPS_MAX @@ -121,7 +121,8 @@ long int __sysconf(int name) #if 0 RETURN_FUNCTION(tzname_max ()); #else - RETURN_NEG_1; +/* RETURN_NEG_1; */ + return _POSIX_TZNAME_MAX; #endif case _SC_JOB_CONTROL: |