1#ifndef _LIBC_TIME_H
2#define _LIBC_TIME_H
3
4#include <bits/time.h>
5#include <fcntl.h>
6#include <stddef.h>
7#include <sys/cdefs.h>
8#include <sys/types.h>
9
10__BEGIN_DECLS
11
12time_t time(time_t* timep);
13char* asctime(const tm_t* tm);
14char* asctime_r(const tm_t* tm, char* buf);
15
16char* ctime(const time_t* timep);
17char* ctime_r(const time_t* timep, char* buf);
18tm_t* gmtime(const time_t* timep);
19tm_t* gmtime_r(const time_t* timep, tm_t* result);
20
21tm_t* localtime(const time_t* timep);
22tm_t* localtime_r(const time_t* timep, tm_t* result);
23
24size_t strftime(char* s, size_t max, const char* format, const tm_t* tm);
25
26time_t mktime(tm_t* tm);
27
28int clock_getres(clockid_t clk_id, timespec_t* res);
29int clock_gettime(clockid_t clk_id, timespec_t* tp);
30int clock_settime(clockid_t clk_id, const timespec_t* tp);
31
32__END_DECLS
33
34#endif // _LIBC_TIME_H