diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2013-08-10 22:02:58 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2013-08-10 22:03:36 -0700 |
commit | dc6d2b5b3652b68d4c62a3875c6960a473b4eaea (patch) | |
tree | 182edcde85db91f2600155c00e47de37a085735d /lib | |
parent | e485bbab866c91f6bd67c4630e87634983055f97 (diff) | |
download | gnulib-dc6d2b5b3652b68d4c62a3875c6960a473b4eaea.tar.gz |
sys_time: port to OpenBSD
* lib/sys_time.in.h: Simply delegate to the system's header
in the BSDish cases as well. Problem reported by Mike Miller in
<http://lists.gnu.org/archive/html/bug-gnulib/2013-08/msg00016.html>.
* tests/test-sys_select.c, tests/test-sys_time.c (verify_tv_sec_type):
Allow platforms like 64-bit OpenBSD where timeval's tv_sec is
wider than time_t.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/sys_time.in.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/sys_time.in.h b/lib/sys_time.in.h index 09c9601e43..90dd02bead 100644 --- a/lib/sys_time.in.h +++ b/lib/sys_time.in.h @@ -24,11 +24,12 @@ #endif @PRAGMA_COLUMNS@ -/* On Cygwin, <sys/time.h> includes itself recursively via <sys/select.h>. +/* On Cygwin and on many BSDish systems, <sys/time.h> includes itself + recursively via <sys/select.h>. Simply delegate to the system's header in this case; it is a no-op. Without this extra ifdef, the C++ gettimeofday declaration below would be a forward declaration in gnulib's nested <sys/time.h>. */ -#ifdef _CYGWIN_SYS_TIME_H +#if defined _CYGWIN_SYS_TIME_H || defined _SYS_TIME_H || defined _SYS_TIME_H_ # @INCLUDE_NEXT@ @NEXT_SYS_TIME_H@ #else |