Avoid compilation warnings on Cygwin.
authorBruno Haible <bruno@clisp.org>
Tue, 20 Jan 2004 16:54:56 +0000 (16:54 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 20 Jan 2004 16:54:56 +0000 (16:54 +0000)
lib/ChangeLog
lib/binary-io.h

index ea8a674..cbd1164 100644 (file)
@@ -1,3 +1,7 @@
+2003-10-17  Bruno Haible  <bruno@clisp.org>
+
+       * binary-io.h: Avoid warnings on Cygwin.
+
 2003-12-28  Bruno Haible  <bruno@clisp.org>
 
        * wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
index 3ff2a37..2845ee7 100644 (file)
 # undef O_TEXT
 #endif
 #if O_BINARY
-# if !(defined __EMX__ || defined __DJGPP__)
+# if !(defined __EMX__ || defined __DJGPP__ || defined __CYGWIN__)
 #  define setmode _setmode
 #  define fileno _fileno
 # endif
-# ifdef __DJGPP__
+# if defined __DJGPP__ || defined __CYGWIN__
 #  include <io.h> /* declares setmode() */
+# endif
+# ifdef __DJGPP__
 #  include <unistd.h> /* declares isatty() */
 #  /* Avoid putting stdin/stdout in binary mode if it is connected to the
 #     console, because that would make it impossible for the user to