On 03/19/13 11:43, marco atzeri wrote: > it does not seem to work: Thanks, we did make some progress, but not enough. How about this patch instead? This affects Solaris, too. I tested it on Solaris 9 but do not have a 2.6 host to test it on; perhaps Tom can do that.
>From 0973b3f06923f7c4e719b546c77c45933e690f02 Mon Sep 17 00:00:00 2001 From: Paul Eggert <egg...@cs.ucla.edu> Date: Tue, 19 Mar 2013 09:08:47 -0700 Subject: [PATCH] sys_select: Port 2013-01-30 Solaris 2.6 fix to Cygwin. Problem reported by Marco Atzeri in <http://lists.gnu.org/archive/html/bug-gnulib/2013-03/msg00000.html>. * lib/sys_select.in.h [HAVE_SYS_SELECT_H && _CYGWIN_SYS_TIME_H]: Simply delegate to the system <sys/select.h> in this case too. Also, pay attention to _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H only if OSF/1, since otherwise Cygwin breaks, and it doesn't seem to be needed on Solaris either. --- ChangeLog | 11 +++++++++++ lib/sys_select.in.h | 16 ++++++++++------ 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 60dbe19..c468845 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2013-03-20 Paul Eggert <egg...@cs.ucla.edu> + + sys_select: Port 2013-01-30 Solaris 2.6 fix to Cygwin. + Problem reported by Marco Atzeri in + <http://lists.gnu.org/archive/html/bug-gnulib/2013-03/msg00000.html>. + * lib/sys_select.in.h [HAVE_SYS_SELECT_H && _CYGWIN_SYS_TIME_H]: + Simply delegate to the system <sys/select.h> in this case too. + Also, pay attention to _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H only + if OSF/1, since otherwise Cygwin breaks, and it doesn't seem to + be needed on Solaris either. + 2013-03-19 Karl Berry <k...@gnu.org> * build-aux/gnupload: check for erroneous (with gnupload) use of diff --git a/lib/sys_select.in.h b/lib/sys_select.in.h index 5a88d51..28a3dac 100644 --- a/lib/sys_select.in.h +++ b/lib/sys_select.in.h @@ -21,23 +21,27 @@ /* On OSF/1 and Solaris 2.6, <sys/types.h> and <sys/time.h> both include <sys/select.h>. + On Cygwin, <sys/time.h> includes <sys/select.h>. Simply delegate to the system's header in this case. */ #if (@HAVE_SYS_SELECT_H@ \ - && ((defined __osf__ && defined _SYS_TYPES_H_ && defined _OSF_SOURCE) \ + && ((defined __osf__ && defined _SYS_TYPES_H_ \ + && !defined _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H \ + && defined _OSF_SOURCE) \ || (defined __sun && defined _SYS_TYPES_H \ && (! (defined _XOPEN_SOURCE || defined _POSIX_C_SOURCE) \ - || defined __EXTENSIONS__))) \ - && !defined _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TYPES_H) + || defined __EXTENSIONS__)))) # define _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TYPES_H # @INCLUDE_NEXT@ @NEXT_SYS_SELECT_H@ #elif (@HAVE_SYS_SELECT_H@ \ - && ((defined __osf__ && defined _SYS_TIME_H_ && defined _OSF_SOURCE) \ + && (defined _CYGWIN_SYS_TIME_H \ + || (defined __osf__ && defined _SYS_TIME_H_ \ + && !defined _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H \ + && defined _OSF_SOURCE) \ || (defined __sun && defined _SYS_TIME_H \ && (! (defined _XOPEN_SOURCE || defined _POSIX_C_SOURCE) \ - || defined __EXTENSIONS__))) \ - && !defined _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H) + || defined __EXTENSIONS__)))) # define _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H # @INCLUDE_NEXT@ @NEXT_SYS_SELECT_H@ -- 1.7.11.7