build: fix build on MinGW32
This commit is contained in:
parent
636b108d37
commit
b17223cd60
@ -30,6 +30,15 @@ typedef intptr_t ssize_t;
|
||||
#endif
|
||||
|
||||
#include <winsock2.h>
|
||||
|
||||
#if defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR)
|
||||
typedef struct pollfd {
|
||||
SOCKET fd;
|
||||
short events;
|
||||
short revents;
|
||||
} WSAPOLLFD, *PWSAPOLLFD, *LPWSAPOLLFD;
|
||||
#endif
|
||||
|
||||
#include <mswsock.h>
|
||||
#include <ws2tcpip.h>
|
||||
#include <windows.h>
|
||||
|
||||
@ -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;
|
||||
|
||||
@ -30,6 +30,10 @@
|
||||
# include <stdint.h>
|
||||
#endif
|
||||
|
||||
#ifndef COMMON_LVB_REVERSE_VIDEO
|
||||
# define COMMON_LVB_REVERSE_VIDEO 0x4000
|
||||
#endif
|
||||
|
||||
#include "uv.h"
|
||||
#include "internal.h"
|
||||
#include "handle-inl.h"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user