for usleep and gettimeofday.
Unified · Split
| @@ -32,6 +32,8 @@ void sleep_ms(unsigned n) · 31 unmodified lines | |||
| 32 | Sleep(n); | 32 | Sleep(n); |
| 33 | } | 33 | } |
| 34 | #else | 34 | #else |
| 35 | #include <sys/time.h> | ||
| 36 | #include <unistd.h> | ||
| 35 | #include <pthread.h> | 37 | #include <pthread.h> |
| 36 | #define TF_TYPE(func, param) void* func(void *param) | 38 | #define TF_TYPE(func, param) void* func(void *param) |
| 37 | typedef TF_TYPE(ThreadFunc, x); | 39 | typedef TF_TYPE(ThreadFunc, x); |