On Fri, 29 Jul 2005 21:56:32 -0400 Malcolm Nooning <[EMAIL PROTECTED]> wrote:

  Hi,

> There is one thing I had to do though.  I had to go into file 
> c:\mingw\include io.h and change
>       _CRTIMP int __cdecl mkdir (const char*);
> to
>       _CRTIMP int __cdecl mkdir (const char*, int);
> because I was getting complaints about mkdir requiring two arguements.  
> I don't know C so I am doing this blindly.  It may crash other things.  
> Still, it worked with compiling PAR, so ...

  This will break the compilation of any program using mkdir correctly
under Windows... the solution is replacing the mkdir call with something
like this.

#ifdef WIN32
    mkdir( path );
#else
    mkdir( path, mode );
#endif

or providing a mkdir wrapper (let's say par_mkdir):

int par_mkdir(const char* path, int mode)
{
#ifdef WIN32
    return mkdir( path );
#else
    return mkdir( path, mode );
#endif
}

and use it where it is needed.

Regards
Mattia

Reply via email to