44 lines
1.2 KiB
Diff
44 lines
1.2 KiB
Diff
From 4eee9eef8c4ac97a9e5afc0fe4ad00f74de155c8 Mon Sep 17 00:00:00 2001
|
|
From: mati865 <mati865@gmail.com>
|
|
Date: Sun, 4 Sep 2016 18:14:37 +0200
|
|
Subject: [PATCH 06/13] fix winnt version
|
|
|
|
Define 0x0600 version to fix compilation
|
|
---
|
|
node.gyp | 5 ++++-
|
|
src/cares_wrap.cc | 5 +++++
|
|
2 files changed, 9 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/node.gyp b/node.gyp
|
|
index d098100..39acb6c 100644
|
|
--- a/node.gyp
|
|
+++ b/node.gyp
|
|
@@ -448,7 +448,10 @@
|
|
]
|
|
} ],
|
|
[ 'node_use_perfctr=="true"', {
|
|
- 'defines': [ 'HAVE_PERFCTR=1' ],
|
|
+ 'defines': [
|
|
+ 'HAVE_PERFCTR=1',
|
|
+ '_WIN32_WINNT=0x0600',
|
|
+ ],
|
|
'dependencies': [ 'node_perfctr' ],
|
|
'sources': [
|
|
'src/node_win32_perfctr_provider.h',
|
|
diff --git a/src/cares_wrap.cc b/src/cares_wrap.cc
|
|
index 4a9c6f7..ffe33b0 100644
|
|
--- a/src/cares_wrap.cc
|
|
+++ b/src/cares_wrap.cc
|
|
@@ -1,4 +1,9 @@
|
|
#define CARES_STATICLIB
|
|
+/* TODO: find real fix; this code uses defines from ws2tcpip.h which require winnt 0x0600 */
|
|
+#if _WIN32_WINNT < 0x0600
|
|
+#undef _WIN32_WINNT
|
|
+#define _WIN32_WINNT 0x0600
|
|
+#endif
|
|
#include "ares.h"
|
|
#include "async-wrap.h"
|
|
#include "async-wrap-inl.h"
|
|
--
|
|
2.9.1
|