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 #endif +#include +namespace fs = boost::filesystem; + #include #include @@ -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: