24 static char __attribute__((unused)) privatehid[] = "@(
#)private.h 8.3";
28 #define GRANDPARENTED "Local time zone must be set--see zic manual page"
36 #define HAVE_ADJTIME 1
40 #define HAVE_GETTEXT 0
43 #ifndef HAVE_INCOMPATIBLE_CTIME_R
44 #define HAVE_INCOMPATIBLE_CTIME_R 0
47 #ifndef HAVE_SETTIMEOFDAY
48 #define HAVE_SETTIMEOFDAY 3
52 #define HAVE_STRERROR 1
56 #define HAVE_SYMLINK 1
59 #ifndef HAVE_SYS_STAT_H
60 #define HAVE_SYS_STAT_H 1
63 #ifndef HAVE_SYS_WAIT_H
64 #define HAVE_SYS_WAIT_H 1
68 #define HAVE_UNISTD_H 1
72 #define HAVE_UTMPX_H 0
76 #define LOCALE_HOME "/usr/lib/locale"
79 #if HAVE_INCOMPATIBLE_CTIME_R
80 #define asctime_r _incompatible_asctime_r
81 #define ctime_r _incompatible_ctime_r
88 #include "sys/types.h"
101 #include <sys/wait.h>
105 #define WIFEXITED(status) (((status) & 0xff) == 0)
108 #define WEXITSTATUS(status) (((status) >> 8) & 0xff)
125 #define is_digit(c) ((unsigned)(c) - '0' <= 9)
133 #ifndef HAVE_STDINT_H
134 #define HAVE_STDINT_H \
135 (199901 <= __STDC_VERSION__ || \
136 2 < (__GLIBC__ + (0 < __GLIBC_MINOR__)))
143 #ifndef INT_FAST64_MAX
145 #if defined LLONG_MAX || defined __LONG_LONG_MAX__
146 typedef long long int_fast64_t;
148 #if (LONG_MAX >> 31) < 0xffffffff
149 Please use a compiler that supports a 64-bit integer type (or wider);
150 you may need to compile with
"-DHAVE_STDINT_H".
152 typedef long int_fast64_t;
157 #define INT32_MAX 0x7fffffff
160 #define INT32_MIN (-1 - INT32_MAX)
180 #define EXIT_SUCCESS 0
188 #define EXIT_FAILURE 1
199 #include "sys/param.h"
204 #define FILENAME_MAX MAXPATHLEN
207 #define FILENAME_MAX 1024
217 extern int unlink P((
const char * filename));
218 #define remove unlink
235 char * icalloc P((
int nelem,
int elsize));
236 char * icatalloc P((
char * old,
const char *
new));
237 char * icpyalloc P((
const char *
string));
238 char * imalloc P((
int n));
239 void * irealloc P((
void * pointer,
int size));
240 void icfree P((
char * pointer));
241 void ifree P((
char * pointer));
242 const char * scheck P((
const char *
string,
const char * format));
257 #define TYPE_BIT(type) (sizeof (type) * CHAR_BIT)
261 #define TYPE_SIGNED(type) (((type) -1) < 0)
269 #ifndef TYPE_INTEGRAL
270 #define TYPE_INTEGRAL(type) (((type) 0.5) != 0.5)
273 #ifndef INT_STRLEN_MAXIMUM
280 #define INT_STRLEN_MAXIMUM(type) \
281 ((TYPE_BIT(type) - TYPE_SIGNED(type)) * 302 / 1000 + \
282 1 + TYPE_SIGNED(type))
302 #define INITIALIZE(x) ((x) = 0)
305 #define INITIALIZE(x)
317 #define _(msgid) gettext(msgid)
319 #define _(msgid) msgid
324 #define TZ_DOMAIN "tz"
327 #if HAVE_INCOMPATIBLE_CTIME_R
330 char *asctime_r P((
struct tm
const *,
char *));
331 char *ctime_r P((time_t
const *,
char *));
334 #ifndef YEARSPERREPEAT
335 #define YEARSPERREPEAT 400
342 #ifndef AVGSECSPERYEAR
343 #define AVGSECSPERYEAR 31556952L
346 #ifndef SECSPERREPEAT
347 #define SECSPERREPEAT ((int_fast64_t) YEARSPERREPEAT * (int_fast64_t) AVGSECSPERYEAR)
350 #ifndef SECSPERREPEAT_BITS
351 #define SECSPERREPEAT_BITS 34
Time-related functions and macros.