#ifndef OLSON_H #define OLSON_H #include #define OLSON_API typedef struct zoneinfo_* zoneinfo_t; OLSON_API void olson_init(const char* tzdir); OLSON_API zoneinfo_t olson_create(const char* name); OLSON_API void olson_destroy(zoneinfo_t sp); OLSON_API zoneinfo_t olson_gmt(void); OLSON_API const char* olson_name(zoneinfo_t sp); OLSON_API char* olson_asctime(const struct tm*, char*); OLSON_API char* olson_ctime(zoneinfo_t sp, const time_t*, char*); OLSON_API double olson_difftime(const time_t, const time_t); OLSON_API struct tm* olson_gmtime(const time_t*, struct tm*); OLSON_API struct tm* olson_localtime(zoneinfo_t sp, const time_t*, struct tm*); OLSON_API time_t olson_mktime(zoneinfo_t sp, struct tm* const); OLSON_API struct tm* olson_offtime(const time_t*, const long, struct tm*); OLSON_API void olson_tzset(zoneinfo_t sp, const char* name); OLSON_API void olson_tzsetwall(zoneinfo_t sp); OLSON_API long olson_gmtoff(zoneinfo_t sp, int isdst); OLSON_API const char* olson_zone(zoneinfo_t sp, int isdst); #if 0 # define asctime 0 # define asctime_r 0 # define ctime 0 # define ctime_r 0 # define difftime 0 # define gmtime 0 # define gmtime_r 0 # define localtime 0 # define localtime_r 0 # define mktime 0 # define offtime 0 # define posix2time 0 # define time2posix 0 # define timegm 0 # define timelocal 0 # define timeoff 0 # define tzset 0 # define tzsetwall 0 # define timezone 0 # define daylight 0 # define altzone 0 # define tzname 0 #endif #endif /* OLSON_H */