Description: Search for time.h, and use it in !HAVE_WAIT3 case.
 This helps getting a correct define for HZ when wait3 is detected to not be
 properly filling in rusage.
Author: Pino Toscano

--- a/configure.ac
+++ b/configure.ac
@@ -61,6 +61,7 @@ AC_SUBST([WARN_CFLAGS])
 dnl Checks for header files.
 AC_HEADER_STDC
 AC_HEADER_SYS_WAIT
+AC_CHECK_HEADERS(time.h)
 
 dnl Checks for typedefs, structures, and compiler characteristics.
 AC_C_CONST
--- a/src/resuse.c
+++ b/src/resuse.c
@@ -28,6 +28,9 @@
 
 #if !HAVE_WAIT3
 # include <sys/times.h>
+# if HAVE_TIME_H
+#  include <time.h>
+# endif
 # ifndef HZ
 #  include <sys/param.h>
 # endif
