Mercurial > gnulib
diff lib/stdlib.in.h @ 39240:26058d7353f4
stdlib: Fix compilation error on OpenIndiana.
* lib/stdlib.in.h: Before including <sys/loadavg.h>, include
<sys/time.h>.
* m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
* m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Sat, 03 Feb 2018 14:05:45 +0100 |
parents | 24e347e0e326 |
children | beb2ad957aca |
line wrap: on
line diff
--- a/lib/stdlib.in.h Sat Feb 03 12:50:17 2018 +0100 +++ b/lib/stdlib.in.h Sat Feb 03 14:05:45 2018 +0100 @@ -47,6 +47,9 @@ /* Solaris declares getloadavg() in <sys/loadavg.h>. */ #if (@GNULIB_GETLOADAVG@ || defined GNULIB_POSIXCHECK) && @HAVE_SYS_LOADAVG_H@ +/* OpenIndiana has a bug: <sys/time.h> must be included before + <sys/loadavg.h>. */ +# include <sys/time.h> # include <sys/loadavg.h> #endif