diff --git a/include/uv-win.h b/include/uv-win.h index 23b42324..9bc0962f 100644 --- a/include/uv-win.h +++ b/include/uv-win.h @@ -30,6 +30,15 @@ typedef intptr_t ssize_t; #endif #include + +#if defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) +typedef struct pollfd { + SOCKET fd; + short events; + short revents; +} WSAPOLLFD, *PWSAPOLLFD, *LPWSAPOLLFD; +#endif + #include #include #include diff --git a/src/win/getnameinfo.c b/src/win/getnameinfo.c index c1aae13f..b8bf23b8 100644 --- a/src/win/getnameinfo.c +++ b/src/win/getnameinfo.c @@ -27,6 +27,17 @@ #include "internal.h" #include "req-inl.h" +#ifndef GetNameInfo +int WSAAPI GetNameInfoW( + const SOCKADDR *pSockaddr, + socklen_t SockaddrLength, + PWCHAR pNodeBuffer, + DWORD NodeBufferSize, + PWCHAR pServiceBuffer, + DWORD ServiceBufferSize, + INT Flags +); +#endif static void uv__getnameinfo_work(struct uv__work* w) { uv_getnameinfo_t* req; diff --git a/src/win/tty.c b/src/win/tty.c index 87e3eb5d..6b8297cb 100644 --- a/src/win/tty.c +++ b/src/win/tty.c @@ -30,6 +30,10 @@ # include #endif +#ifndef COMMON_LVB_REVERSE_VIDEO +# define COMMON_LVB_REVERSE_VIDEO 0x4000 +#endif + #include "uv.h" #include "internal.h" #include "handle-inl.h"