X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=include%2Fsys%2Ftime.h;h=766ac728b17a070842f7fb3273624c6c46ec76b8;hb=8b61c816933abe9ac152a05ccf8bd801f7bc13bf;hp=9b3bfb9996520ace35e5068d9fc2d0d9e6b115c4;hpb=0b44a0315b47dd8eced9f3b7f31580cf14bbfc01;p=musl diff --git a/include/sys/time.h b/include/sys/time.h index 9b3bfb99..766ac728 100644 --- a/include/sys/time.h +++ b/include/sys/time.h @@ -9,7 +9,7 @@ extern "C" { #define __NEED_time_t #define __NEED_suseconds_t -#define __NEED_timeval +#define __NEED_struct_timeval #include @@ -17,10 +17,7 @@ extern "C" { int gettimeofday (struct timeval *, void *); -/* extensions */ -int settimeofday (const struct timeval *, void *); -int adjtime (const struct timeval *, struct timeval *); - +#if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) #define ITIMER_REAL 0 #define ITIMER_VIRTUAL 1 @@ -36,7 +33,11 @@ int getitimer (int, struct itimerval *); int setitimer (int, const struct itimerval *, struct itimerval *); int utimes (const char *, const struct timeval [2]); +#endif + #ifdef _GNU_SOURCE +int settimeofday (const struct timeval *, void *); +int adjtime (const struct timeval *, struct timeval *); struct timezone { int tz_minuteswest; int tz_dsttime;