Subject: bug#12918: 24.2.50; fileio.c:2106:3: error: too few arguments to function 'rpl_mkdir'

From: Eli Zaretskii <[email-masked]>
Date: Sat, 17 Nov 2012 23:07:15 +0200

> Date: Sat, 17 Nov 2012 20:59:12 +0000
> From: Stephen Powell <[email-masked]>
> 
> Built from head of trunk for the first time in a week.
> 
> gcc -I. -c -DENABLE_CHECKING -DXASSERTS -gdwarf-2 -g3 -O0 -march=native
>  -pipe     -Demacs=1 -I../lib -I../nt/inc -DUSE_CRT_DLL=1
> -DPURESIZE=5000000 -o oo-spd/i386/fileio.o fileio.c
> fileio.c: In function 'Fmake_directory_internal':
> fileio.c:2106:3: error: too few arguments to function 'rpl_mkdir'
> In file included from ../nt/inc/ms-w32.h:363:0,
>                  from ./conf_post.h:32,
>                  from ./config.h:1696,
>                  from fileio.c:20:
> ../lib/sys/stat.h:813:1: note: declared here
> Makefile:332: recipe for target 'oo-spd/i386/fileio.o' failed

??? How did you configure Emacs?  The only way you could get
'rpl_mkdir' is if you generated lib/sys/stat.h, but the Windows build
procedure doesn't do that, we use nt/inc/sys/stat.h instead.  I'm
bewildered what kind of build procedure could get you there.  Did you
per chance run the top-level configure script?

> Also several warnings for "mkdir" and "O_NDELAY" being redefined.
> 
> gcc -I. -c -DENABLE_CHECKING -DXASSERTS -gdwarf-2 -g3 -O0 -march=native
> -pipe     -Demacs=1 -I../lib -I../nt/inc -DUSE_CRT_DLL=1
> -DPURESIZE=5000000 -o oo-spd/i386/w32.o w32.c
> In file included from ./conf_post.h:32:0,
>                  from ./config.h:1696,
>                  from w32.c:39:
> ../nt/inc/ms-w32.h:165:0: warning: "mkdir" redefined [enabled by default]
> In file included from ../lib/fcntl.h:58:0,
>                  from w32.c:28:
> ../lib/sys/stat.h:821:0: note: this is the location of the previous
> definition
> In file included from w32.c:155:0:
> ../nt/inc/sys/socket.h:122:0: warning: "O_NDELAY" redefined [enabled by
> default]
> In file included from w32.c:28:0:
> ../lib/fcntl.h:536:0: note: this is the location of the previous definition

Likewise: neither lib/sys/stat.h not lib/fcntl.h shouldn't exist in
the Windows build.  Maybe you tried some other build (Cygwin?) in the
same directory.