# HG changeset patch # User Eric Blake # Date 1313612015 21600 # Node ID 8d4beb5eae92a3b4979da0045c7bc13697fceb64 # Parent 5b310380e54f6aaa5880b582ca21499010f3e194 getcwd: fix compilation on mingw64 Mingw 64 added as a place that declared getcwd. It is a non-standard header, but since we already include it in the replacement for , we must also include it in the replacement for to avoid compilation problems. * lib/unistd.in.h (includes) [mingw]: Include for getcwd. Reported by Marc-André Lureau. Signed-off-by: Eric Blake diff --git a/ChangeLog b/ChangeLog --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,10 @@ 2011-08-17 Eric Blake + getcwd: fix compilation on mingw64 + * lib/unistd.in.h (includes) [mingw]: Include for + getcwd. + Reported by Marc-André Lureau. + pipe2: silence compiler warning * lib/pipe2.c (pipe2): Hide label if it is not used. diff --git a/lib/unistd.in.h b/lib/unistd.in.h --- a/lib/unistd.in.h +++ b/lib/unistd.in.h @@ -85,7 +85,8 @@ /* mingw declares getcwd in , not in . */ #if ((@GNULIB_GETCWD@ || defined GNULIB_POSIXCHECK) \ && ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__)) -# include +# include /* mingw32, mingw64 */ +# include /* mingw64 */ #endif /* AIX and OSF/1 5.1 declare getdomainname in , not in .