Eric Blake wrote on 2009-09-07: > I'm pushing this, which improves the rename module (after first making the > stdio module easier to modify) to cross-compile to non-mingw scenarios. > ... > --- a/lib/stdio.in.h > +++ b/lib/stdio.in.h > @@ -416,6 +416,20 @@ extern int putchar (int c); > extern int puts (const char *string); > #endif > > +#if @GNULIB_RENAME@ > +# if @REPLACE_RENAME@ > +# undef rename > +# define rename rpl_rename > +extern int rename (const char *old, const char *new); > +# endif
The identifier 'new' is a reserved word in C++ and leads to a syntax error here. I'm applying this fix: 2009-12-09 Bruno Haible <br...@clisp.org> Avoid syntax error in C++ mode. * lib/stdio.in.h (rename): Don't use parameter name 'new'. --- lib/stdio.in.h.orig 2009-12-10 14:08:02.000000000 +0100 +++ lib/stdio.in.h 2009-12-10 13:59:39.000000000 +0100 @@ -448,7 +448,7 @@ # if @REPLACE_RENAME@ # undef rename # define rename rpl_rename -extern int rename (const char *old, const char *new); +extern int rename (const char *old_filename, const char *new_filename); # endif #elif defined GNULIB_POSIXCHECK # undef rename