mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
win solve various cranky problems with msvc
After emptyVoid at ---> https://github.com/warmcat/libwebsockets/issues/374 Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
parent
71e267574d
commit
eee0d8af5f
3 changed files with 7 additions and 9 deletions
|
@ -105,12 +105,6 @@ extern "C" {
|
|||
#include "lws_config.h"
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
#if (WINVER < 0x0600)
|
||||
#undef WINVER
|
||||
#undef _WIN32_WINNT
|
||||
#define WINVER 0x0600
|
||||
#define _WIN32_WINNT WINVER
|
||||
#endif
|
||||
#ifndef WIN32_LEAN_AND_MEAN
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#endif
|
||||
|
|
|
@ -66,6 +66,7 @@
|
|||
#define lws_socket_is_valid(x) (!!x)
|
||||
#define LWS_SOCK_INVALID 0
|
||||
#include <winsock2.h>
|
||||
#include <ws2tcpip.h>
|
||||
#include <windows.h>
|
||||
#include <tchar.h>
|
||||
#ifdef LWS_HAVE_IN6ADDR_H
|
||||
|
|
|
@ -1,3 +1,9 @@
|
|||
#if defined(_WIN32) && defined(EXTERNAL_POLL)
|
||||
#define WINVER 0x0600
|
||||
#define _WIN32_WINNT 0x0600
|
||||
#define poll(fdArray, fds, timeout) WSAPoll((LPWSAPOLLFD)(fdArray), (ULONG)(fds), (INT)(timeout))
|
||||
#endif
|
||||
|
||||
#include "lws_config.h"
|
||||
|
||||
#include <stdio.h>
|
||||
|
@ -13,9 +19,6 @@
|
|||
|
||||
#ifdef _WIN32
|
||||
#include <io.h>
|
||||
#ifdef EXTERNAL_POLL
|
||||
#define poll WSAPoll
|
||||
#endif
|
||||
#include "gettimeofday.h"
|
||||
#else
|
||||
#include <syslog.h>
|
||||
|
|
Loading…
Add table
Reference in a new issue