[MinGW-w64]Build gdb/ctf.c failed
Yao Qi
yao@codesourcery.com
Mon Mar 25 09:42:00 GMT 2013
On 03/25/2013 04:06 PM, Kai Tietz wrote:
> The function 'mkdir' (please note it is without leading underscore),
> is declared in io.h header, which is of course include within unistd.h
> header.
Right, 'mkdir' is declared io.h, which is included in unistd.h. Looks
like we should use "mkdir" instead of "_mkdir". How about the patch
below? It unbreaks the build of using mingw-w64 toolchain, while
mingw32 toolchain doesn't complain about it.
--
Yao (é½å°§)
gdb:
2013-03-25 Yao Qi <yao@codesourcery.com>
* ctf.c [USE_WIN32API]: Use 'mkdir' instead of '_mkdir'.
---
gdb/ctf.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/gdb/ctf.c b/gdb/ctf.c
index 8510ff9..3df2de5 100644
--- a/gdb/ctf.c
+++ b/gdb/ctf.c
@@ -296,7 +296,7 @@ ctf_target_save (struct trace_file_writer *self,
}
#ifdef USE_WIN32API
-#define mkdir(pathname, mode) _mkdir (pathname)
+#define mkdir(pathname, mode) mkdir (pathname)
#endif
/* This is the implementation of trace_file_write_ops method
--
1.7.7.6
More information about the Gdb-patches
mailing list