8199736: Define WIN32_LEAN_AND_MEAN before including windows.h

Reviewed-by: erikj, ihse, kbarrett, dholmes
This commit is contained in:
Robin Westberg 2018-04-09 10:09:38 +02:00
parent a384a668a5
commit 2dfa53af63
4 changed files with 6 additions and 2 deletions

View File

@ -453,7 +453,7 @@ AC_DEFUN([FLAGS_SETUP_CFLAGS_HELPER],
elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
ALWAYS_DEFINES_JDK="-DWIN32_LEAN_AND_MEAN -D_CRT_SECURE_NO_DEPRECATE \
-D_CRT_NONSTDC_NO_DEPRECATE -DWIN32 -DIAL"
ALWAYS_DEFINES_JVM="-DNOMINMAX"
ALWAYS_DEFINES_JVM="-DNOMINMAX -DWIN32_LEAN_AND_MEAN"
fi
###############################################################################

View File

@ -99,6 +99,8 @@
// for enumerating dll libraries
#include <vdmdbg.h>
#include <psapi.h>
#include <mmsystem.h>
#include <winsock2.h>
// for timer info max values which include all bits
#define ALL_64_BITS CONST64(-1)

View File

@ -45,7 +45,7 @@ BasicType Bytecodes::_result_type [Bytecodes::number_of_codes];
s_char Bytecodes::_depth [Bytecodes::number_of_codes];
u_char Bytecodes::_lengths [Bytecodes::number_of_codes];
Bytecodes::Code Bytecodes::_java_code [Bytecodes::number_of_codes];
u_short Bytecodes::_flags [(1<<BitsPerByte)*2];
unsigned short Bytecodes::_flags [(1<<BitsPerByte)*2];
#ifdef ASSERT
bool Bytecodes::check_method(const Method* method, address bcp) {

View File

@ -1027,6 +1027,8 @@ bufferedStream::~bufferedStream() {
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#elif defined(_WINDOWS)
#include <winsock2.h>
#endif
// Network access