On 03/06/2011 08:33 AM, Don Ward wrote: > Build in usrp/host/misc is failing on MinGW with > > tempname.c:315:4: error: too many arguments to function 'mkdir' > > It appears that the MKDIR_TAKES_ONE_ARGUMENT logic has been removed from > config/{mkstmp,gr_pwin32}.m4. > > Anyone know the right way to fix this?
The mkdir stuff was replaced with boost filesystem calls. I must have forgot to grep the random c files in the host code. Can you try the diff attached? -josh > > -- Don W. > > > _______________________________________________ > Discuss-gnuradio mailing list > Discuss-gnuradio@gnu.org > http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
diff --git a/usrp/host/misc/tempname.c b/usrp/host/misc/tempname.c index 2611126..a3599e7 100644 --- a/usrp/host/misc/tempname.c +++ b/usrp/host/misc/tempname.c @@ -21,6 +21,9 @@ # include <config.h> #endif +#include <boost/filesystem/path.hpp> +namespace fs = boost::filesystem; + #include <sys/types.h> #include <assert.h> @@ -98,11 +101,6 @@ # define struct_stat64 struct stat # define __getpid getpid # define __gettimeofday gettimeofday -#ifdef MKDIR_TAKES_ONE_ARG -# define __mkdir(pathname,mode) mkdir((pathname)) -#else -# define __mkdir mkdir -#endif # define __open open # define __open64 open #ifdef HAVE_LSTAT @@ -312,7 +310,7 @@ __gen_tempname (char *tmpl, int kind) break; case __GT_DIR: - fd = __mkdir (tmpl, S_IRUSR | S_IWUSR | S_IXUSR); + fd = fs::create_directory(tmpl, S_IRUSR | S_IWUSR | S_IXUSR); break; case __GT_NOCREATE:
_______________________________________________ Discuss-gnuradio mailing list Discuss-gnuradio@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnuradio