Thread: Can not build libpq.dll with BCC
Hi! I filled out the bug form but I don't see my report appear in bug archive. Hence I am resorting to pgsql-bug list. Regards, CN ============ OS: Win98 on top of win4lin on top of Linux Compiler BC++ 5.6.4 Possible bug 1: Unless lines 142 and 143 in ~/interfaces/libpq/bcc32.mak are changed to as the following, make aborts when copying: pthread.h: pthread-win32.h copy pthread-win32.h pthread.h Possible bug 2: With lines 142 and 143 in bcc32.mak changed to the above lines, make still fails with the messages: MAKE Version 5.2 Copyright (c) 1987, 2000 Borland Building the Win32 DLL and Static Library... No configuration specified. Defaulting to Release. echo #define SYSCONFDIR pg_config_paths.h #define SYSCONFDIR pg_config_paths.h bcc32.exe @MAKE0002.@@@ Borland C++ 5.6.4 for Win32 Copyright (c) 1993, 2002 Borland ..\..\port\getaddrinfo.c: Warning W8017 ..\..\include\port/win32.h 46: Redefinition of 'DLLIMPORT' is not identical Warning W8017 ..\..\include\port/win32.h 149: Redefinition of 'SIGUSR1' is not identical Warning W8017 ..\..\include\port/win32.h 150: Redefinition of 'SIGUSR2' is not identical Error E2451 ..\..\port\getaddrinfo.c 245: Undefined symbol 'WSA_NOT_ENOUGH_MEMORY' in function pg_getaddrinfo Error E2451 ..\..\port\getaddrinfo.c 335: Undefined symbol 'WSA_NOT_ENOUGH_MEMORY' in function pg_gai_strerror Error E2451 ..\..\port\getaddrinfo.c 404: Undefined symbol 'WSA_NOT_ENOUGH_MEMORY' in function pg_getnameinfo Error E2451 ..\..\port\getaddrinfo.c 417: Undefined symbol 'WSA_NOT_ENOUGH_MEMORY' in function pg_getnameinfo *** 4 errors in Compile *** ** error 1 ** deleting ".\Release\getaddrinfo.obj" -- http://www.fastmail.fm - The way an email service should be
> Error E2451 ..\..\port\getaddrinfo.c 245: Undefined symbol=20 > 'WSA_NOT_ENOUGH_MEMORY' in function pg_getaddrinfo Error=20 > E2451 ..\..\port\getaddrinfo.c 335: Undefined symbol=20 > 'WSA_NOT_ENOUGH_MEMORY' in function pg_gai_strerror Error=20 > E2451 ..\..\port\getaddrinfo.c 404: Undefined symbol=20 > 'WSA_NOT_ENOUGH_MEMORY' in function pg_getnameinfo Error=20 > E2451 ..\..\port\getaddrinfo.c 417: Undefined symbol=20 > 'WSA_NOT_ENOUGH_MEMORY' in function pg_getnameinfo > *** 4 errors in Compile *** >=20 > ** error 1 ** deleting ".\Release\getaddrinfo.obj" This sounds like you need a newer Platform SDK. This define should be in winsock2.h, per http://msdn.microsoft.com/library/default.asp?url=3D/library/en-us/winsock /winsock/windows_sockets_error_codes_2.asp. Probably your includes from BCC are too old and needs updating. //Magnus
Thank you! Magnus, > This sounds like you need a newer Platform SDK. This define should be in > winsock2.h, per > http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock > /winsock/windows_sockets_error_codes_2.asp. Probably your includes from > BCC are too old and needs updating. > Before reported this issue, I had checked BCC's winsock2.h and noticed that the required defines are already there: ... /* * WinSock 2 extension -- new error codes and type definition */ #ifdef WIN32 #define WSAAPI FAR PASCAL #define WSAEVENT HANDLE #define LPWSAEVENT LPHANDLE #define WSAOVERLAPPED OVERLAPPED typedef struct _OVERLAPPED * LPWSAOVERLAPPED; #define WSA_IO_PENDING (ERROR_IO_PENDING) #define WSA_IO_INCOMPLETE (ERROR_IO_INCOMPLETE) #define WSA_INVALID_HANDLE (ERROR_INVALID_HANDLE) #define WSA_INVALID_PARAMETER (ERROR_INVALID_PARAMETER) #define WSA_NOT_ENOUGH_MEMORY (ERROR_NOT_ENOUGH_MEMORY) #define WSA_OPERATION_ABORTED (ERROR_OPERATION_ABORTED) ... Regards, CN -- http://www.fastmail.fm - Access your email from home and the web