--- src/bin/pg_config/win32.mak.orig Fri Nov 11 02:29:14 2005 +++ src/bin/pg_config/win32.mak Fri Nov 11 02:29:45 2005 @@ -55,7 +55,7 @@ LINK32=link.exe LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\ - advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\ + advapi32.lib shell32.lib shfolder.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\ odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:no\ /pdb:"$(OUTDIR)\pg_config.pdb" /machine:I386 $(LOPT) /out:"$(OUTDIR)\pg_config.exe" LINK32_OBJS= \ --- src/include/getaddrinfo.h.orig Fri Nov 11 01:57:29 2005 +++ src/include/getaddrinfo.h Fri Nov 11 09:48:14 2005 @@ -42,6 +42,10 @@ #define EAI_MEMORY (-10) #define EAI_SYSTEM (-11) #else /* WIN32 */ +#if defined(_MSC_VER) +#define WSA_NOT_ENOUGH_MEMORY (WSAENOBUFS) +#define WSATYPE_NOT_FOUND (WSABASEERR+109) +#endif #define EAI_AGAIN WSATRY_AGAIN #define EAI_BADFLAGS WSAEINVAL #define EAI_FAIL WSANO_RECOVERY --- src/port/getaddrinfo.c.orig Fri Nov 11 09:47:25 2005 +++ src/port/getaddrinfo.c Fri Nov 11 09:47:54 2005 @@ -40,6 +40,7 @@ #include +#if !defined(_MSC_VER) /* * The native routines may or may not exist on the Windows platform we are on, * so we dynamically look up the routines, and call them via function pointers. @@ -129,6 +130,7 @@ return (getaddrinfo_ptr != NULL); } #endif +#endif /* @@ -149,7 +151,7 @@ *psin; struct addrinfo hints; -#ifdef WIN32 +#if defined(WIN32) && !defined(_MSC_VER) /* * If Windows has native IPv6 support, use the native Windows routine. @@ -272,7 +274,7 @@ { if (res) { -#ifdef WIN32 +#if defined(WIN32) && !defined(_MSC_VER) /* * If Windows has native IPv6 support, use the native Windows routine. @@ -364,7 +366,7 @@ char *node, int nodelen, char *service, int servicelen, int flags) { -#ifdef WIN32 +#if defined(WIN32) && !defined(_MSC_VER) /* * If Windows has native IPv6 support, use the native Windows routine.