diff options
author | Bruno Haible <bruno@clisp.org> | 2002-12-31 13:43:06 +0000 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2002-12-31 13:43:06 +0000 |
commit | e059c2358aad79ce8dfd9581dd6f12ce8503dc63 (patch) | |
tree | 9ddff5119783ac032c26bc98393df8f5f3a15f41 /m4/timespec.m4 | |
parent | 53b8fa05726a7fb30010e42ce02e44a35f0d7489 (diff) | |
download | gnulib-e059c2358aad79ce8dfd9581dd6f12ce8503dc63.tar.gz |
An independent .m4 file for each module.
Diffstat (limited to 'm4/timespec.m4')
-rw-r--r-- | m4/timespec.m4 | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/m4/timespec.m4 b/m4/timespec.m4 index 5edb554dbe..5df984f347 100644 --- a/m4/timespec.m4 +++ b/m4/timespec.m4 @@ -1,13 +1,28 @@ -#serial 5 +#serial 6 dnl From Jim Meyering +AC_DEFUN([gl_TIMESPEC], +[ + dnl Prerequisites of lib/timespec.h. + AC_REQUIRE([AC_HEADER_TIME]) + AC_CHECK_HEADERS_ONCE(sys/time.h) + jm_CHECK_TYPE_STRUCT_TIMESPEC + AC_STRUCT_ST_MTIM_NSEC + + dnl Persuade glibc <time.h> to declare nanosleep(). + AC_REQUIRE([AC_GNU_SOURCE]) + + AC_CHECK_DECLS(nanosleep, , , [#include <time.h>]) +]) + dnl Define HAVE_STRUCT_TIMESPEC if `struct timespec' is declared dnl in time.h or sys/time.h. AC_DEFUN([jm_CHECK_TYPE_STRUCT_TIMESPEC], [ AC_REQUIRE([AC_HEADER_TIME]) + AC_CHECK_HEADERS_ONCE(sys/time.h) AC_CACHE_CHECK([for struct timespec], fu_cv_sys_struct_timespec, [AC_TRY_COMPILE( [ |