00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00021 #ifndef GRU_TIME_PORTABLE_H
00022 #define GRU_TIME_PORTABLE_H
00023
00024 #if !defined(_WIN32) && !defined(_WIN64)
00025 #include <sys/time.h>
00026 #else
00027 #include <windows.h>
00028 #endif
00029
00030 #include "common/gru_portable.h"
00031
00032 #ifdef __cplusplus
00033 extern "C" {
00034 #endif
00035
00036 #if (!defined __linux__ && !defined __APPLE__)
00037 gru_export int
00038 gru_time_timersub(struct timeval *start, struct timeval *end, struct timeval *result);
00039
00040 #define timersub(start, end, result) gru_time_timersub(start, end, result)
00041 #endif
00042
00043 #ifdef __cplusplus
00044 }
00045 #endif
00046
00047 #endif