Merge branch 'master' of git://localhost/acess2
[tpg/acess2.git] / Usermode / Libraries / libposix.so_src / include_exp / sys / time.h
index 5cd2876..cef859b 100644 (file)
@@ -8,6 +8,12 @@
 #ifndef _LIBPOSIX__SYS__TIME_H_
 #define _LIBPOSIX__SYS__TIME_H_
 
+#include <time.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 typedef unsigned long  suseconds_t;
 
 struct timeval
@@ -16,6 +22,28 @@ struct timeval
        suseconds_t     tv_usec;
 };
 
+// struct timezone . tz_dsttime
+enum
+{
+       DST_NONE,       // No DST
+       DST_USA,        // USA style DST
+       DST_AUST,       // Australian style DST
+       DST_WET,        // Western European DST
+       DST_MET,        // Middle European DST
+       DST_EET,        // Eastern European DST
+       DST_CAN,        // Canada
+       DST_GB,         // Great Britain and Eire
+       DST_RUM,        // Rumania
+       DST_TUR,        // Turkey
+       DST_AUSTALT,    // Australia with 1986 shift
+};
+
+struct timezone
+{
+       int tz_minuteswest;
+       int tz_dsttime;
+};
+
 struct itimerval
 {
        struct timeval  it_interval;
@@ -24,11 +52,16 @@ struct itimerval
 
 // TODO: This should also define fd_set and select()
 
-extern int     getitimer(int, struct itimerval *);
-extern int     setitimer(int, const struct itimerval *, struct itimerval *);
-extern int     gettimeofday(struct timeval *, void *);
+extern int     getitimer(int which, struct itimerval *current_value);
+extern int     setitimer(int which, const struct itimerval *new_value, struct itimerval *old_value);
+extern int     gettimeofday(struct timeval *tv, struct timezone *tz);
+// extern int  settimeofday(const struct timeval *tv, const struct timezone *tz); //ifdef _BSD_SOURCE
 // select
 extern int     utimes(const char *, const struct timeval [2]);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif
 

UCC git Repository :: git.ucc.asn.au