From 029a9ca507423c026f35853075fc80336d4ca2da Mon Sep 17 00:00:00 2001 From: Joel Dice Date: Fri, 16 Sep 2011 18:42:18 -0600 Subject: [PATCH] fix MinGW (non-w64) build Commit a2dca0dc fixed the MinGW-w64 openjdk-src build but broke the traditional MinGW build. This should ensure that both work. --- makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/makefile b/makefile index 38db3391ab..5a3be6a5a6 100755 --- a/makefile +++ b/makefile @@ -937,11 +937,12 @@ ifeq ($(platform),windows) < "$(openjdk-src)/windows/native/java/net/net_util_md.h" \ > $(build)/openjdk/net_util_md.h sed \ - -e 's/IpPrefix/hide_IpPrefix/' \ - -e 's/IpSuffix/hide_IpSuffix/' \ - -e 's/IpDad/hide_IpDad/' \ - -e 's/ScopeLevel/hide_ScopeLevel/' \ - -e 's/SCOPE_LEVEL/hide_SCOPE_LEVEL/' \ + -e 's/\(^#include "net_util.h"\)/\1\n#if (defined _INC_NLDEF) || (defined _WS2DEF_)\n#define HIDE(x) hide_##x\n#else\n#define HIDE(x) x\n#define _WINSOCK2API_\n#endif/' \ + -e 's/\(IpPrefix[a-zA-Z_]*\)/HIDE(\1)/' \ + -e 's/\(IpSuffix[a-zA-Z_]*\)/HIDE(\1)/' \ + -e 's/\(IpDad[a-zA-Z_]*\)/HIDE(\1)/' \ + -e 's/\(ScopeLevel[a-zA-Z_]*\)/HIDE(\1)/' \ + -e 's/\(SCOPE_LEVEL[a-zA-Z_]*\)/HIDE(\1)/' \ < "$(openjdk-src)/windows/native/java/net/NetworkInterface.h" \ > $(build)/openjdk/NetworkInterface.h echo 'static int getAddrsFromAdapter(IP_ADAPTER_ADDRESSES *ptr, netaddr **netaddrPP);' >> $(build)/openjdk/NetworkInterface.h