Skip to content
This repository

test/runner-win.c compile error on MinGW #583

hnakamur opened this Issue · 4 comments

4 participants

Hiroaki Nakamura Ben Noordhuis Bert Belder pH200
Hiroaki Nakamura

with error message.
test/runner-win.c:27:20: fatal error: crtdbg.h: No such file or directory


Ben Noordhuis

Does this patch fix it?

diff --git a/test/runner-win.c b/test/runner-win.c
index 111a686..8ea459b 100644
--- a/test/runner-win.c
+++ b/test/runner-win.c
@@ -24,7 +24,10 @@
 #include <malloc.h>
 #include <stdio.h>
 #include <process.h>
-#include <crtdbg.h>
+#if !defined(__MINGW32__)
+# include <crtdbg.h>

 #include "task.h"
 #include "runner.h"
Hiroaki Nakamura hnakamur referenced this issue from a commit in hnakamur/libuv
Hiroaki Nakamura hnakamur Disable crtdbg on MinGW. refs #583 937b780
Hiroaki Nakamura

No. I sent a pull request. Please see #585

Bert Belder

Fixed in 2684f87.


Oops, sorry for breaking the build :p

Although libuv is only supported build with either MSVC or MinGW for Windows. Given the fact that crtdbg.h is an MSVC specific header, maybe it would be more appropriate to write:
#if defined(_MSC_VER)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.