* lib/unistd.in.h: Include <sys/types.h>.
* tests/test-fcntl-h.c: Check that off_t is defined.
* tests/test-sys_stat.c: Likewise.
* tests/test-sys_types.c: Likewise.
+2011-09-16 Bruno Haible <bruno@clisp.org>
+
+ Support for MSVC compiler: Ensure off_t gets defined.
+ * lib/unistd.in.h: Include <sys/types.h>.
+ * tests/test-fcntl-h.c: Check that off_t is defined.
+ * tests/test-sys_stat.c: Likewise.
+ * tests/test-sys_types.c: Likewise.
+
2011-09-16 Eric Blake <eblake@redhat.com>
fdatasync: port to Solaris
# include <netdb.h>
#endif
+/* MSVC defines off_t in <sys/types.h>. */
+#if !@HAVE_UNISTD_H@
+/* Get off_t. */
+# include <sys/types.h>
+#endif
+
#if (@GNULIB_READ@ || @GNULIB_WRITE@ \
|| @GNULIB_READLINK@ || @GNULIB_READLINKAT@ \
|| @GNULIB_PREAD@ || @GNULIB_PWRITE@ || defined GNULIB_POSIXCHECK)
/* Check that the types are all defined. */
pid_t t1;
+off_t t2;
int
main (void)
/* Check the existence of some types. */
nlink_t t1;
+off_t t2;
-struct timespec t2;
+struct timespec t3;
int
main (void)
pid_t t1;
size_t t2;
ssize_t t3;
+off_t t4;
int
main (void)