With this, getopt actually do seem to compile and work in Visual
Studio.  Tested with the CLI in libtasn1, part of GnuTLS, with long
options.

I'll install this shortly unless someone protests.

2006-02-28  Simon Josefsson  <[EMAIL PROTECTED]>

        * getopt.c: Protect #include of unistd.h, for MSVS.

--- getopt.c    24 Jan 2006 12:55:34 +0100      1.48
+++ getopt.c    28 Feb 2006 11:31:27 +0100      
@@ -29,7 +29,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #ifdef VMS
 # include <unixlib.h>


_______________________________________________
bug-gnulib mailing list
bug-gnulib@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnulib

Reply via email to