use WIN32_LEAN_AND_MEAN project-wise to silent warnings on windows about winsock2.h and windows.h

This commit is contained in:
sachaaaaa 2018-08-03 11:33:48 +10:00
parent 694644ac8b
commit 37aed03df2
2 changed files with 1 additions and 1 deletions

View File

@ -167,6 +167,7 @@ if(UNIX)
endif()
elseif(WIN32 OR MINGW)
set(LIBTUNTAP_IMPL ${TT_ROOT}/tuntap-windows.c)
add_definitions(-DWIN32_LEAN_AND_MEAN)
else()
message(FATAL_ERROR "What operating system _are_ you building on/for?")
endif(UNIX)

View File

@ -9,7 +9,6 @@
#include <string>
#ifdef _WIN32
#define VC_EXTRALEAN
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#endif