瀏覽代碼

mingw & cygwin have gettimeofday (and possibly timespec) in sys/time.h

Samuel Thibault 10 年之前
父節點
當前提交
15fa7c89da
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      include/starpu_util.h

+ 3 - 0
include/starpu_util.h

@@ -276,6 +276,9 @@ double starpu_timing_now(void);
 #ifdef _WIN32
 /* Try to fetch the system definition of timespec */
 #include <time.h>
+#if defined(__MINGW32__) || defined(__CYGWIN__)
+#include <sys/time.h>
+#endif
 #if !defined(_MSC_VER) || defined(BUILDING_STARPU)
 #include <pthread.h>
 #endif