slcc/fakelibc/time.h

30 lines
475 B
C
Raw Permalink Normal View History

#ifndef _FAKELIBC_TIME_H
#define _FAKELIBC_TIME_H
typedef long time_t;
char* ctime(const time_t* timevar);
/* TODO: Check if modern systems add any more fields. */
struct tm {
int tm_sec;
int tm_min;
int tm_hour;
int tm_mday;
int tm_mon;
int tm_year;
int tm_wday;
int tm_yday;
int tm_isdst;
};
struct timespec {
int tv_sec;
long tv_nsec;
};
struct tm* localtime(const time_t* timep);
/* From ifndef at top of file: */
#endif