Compiling 8.0beta on mingw with openssl support - Mailing list pgsql-hackers-win32
From | G Reina |
---|---|
Subject | Compiling 8.0beta on mingw with openssl support |
Date | |
Msg-id | BAY8-F112fJNwPmxd220003d903@hotmail.com Whole thread Raw |
List | pgsql-hackers-win32 |
I've had no trouble compiling 8.0beta on a Windows XP box with mingw, but am having a devil of a time doing it with OpenSSL support. Specifically, the configure script is throwing an error when it attempts to use the SSL library. I've tried compiling OpenSSL 0.9.7d within mingw, from my MS Visual Studio compiler, and from a packaged binary. The mingw OpenSSL version seems to be the only usable one since it is the only one that seems to be installing libcrypto.a and libssl.a. The other two are just building DLLs (libeay32.dll and ssleay32.dll). The configure script error with the mingw openssl try is: ... configure:5916: checking for inflate in -lz configure:5949: gcc -o conftest.exe -O2 -fno-strict-aliasing -I./src/include/port/win32 -DEXEC_BACKEND -I/usr/local/include -I/usr/local/ssl/include/openssl -L/usr/local/lib -L/usr/local/ssl/lib conftest.c -lz -lwsock32 -lm >&5 configure:5952: $? = 0 configure:5955: test -s conftest.exe configure:5958: $? = 0 configure:5969: result: yes configure:6566: checking for CRYPTO_new_ex_data in -lcrypto configure:6599: gcc -o conftest.exe -O2 -fno-strict-aliasing -I./src/include/port/win32 -DEXEC_BACKEND -I/usr/local/include -I/usr/local/ssl/include/openssl -L/usr/local/lib -L/usr/local/ssl/lib conftest.c -lcrypto -lz -lwsock32 -lm >&5 configure:6602: $? = 0 configure:6605: test -s conftest.exe configure:6608: $? = 0 configure:6619: result: yes configure:6635: checking for SSL_library_init in -lssl configure:6668: gcc -o conftest.exe -O2 -fno-strict-aliasing -I./src/include/port/win32 -DEXEC_BACKEND -I/usr/local/include -I/usr/local/ssl/include/openssl -L/usr/local/lib -L/usr/local/ssl/lib conftest.c -lssl -lcrypto -lz -lwsock32 -lm >&5 C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xae3):rand_win.c: undefined reference to `CreateDCA@16' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xaf4):rand_win.c: undefined reference to `CreateCompatibleDC@4' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xb09):rand_win.c: undefined reference to `GetDeviceCaps@8' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xb19):rand_win.c: undefined reference to `GetDeviceCaps@8' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xb33):rand_win.c: undefined reference to `CreateCompatibleBitmap@12' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xb41):rand_win.c: undefined reference to `SelectObject@8' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xb53):rand_win.c: undefined reference to `GetObjectA@12' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xbc1):rand_win.c: undefined reference to `BitBlt@36' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xbcb):rand_win.c: undefined reference to `GetBitmapBits@12' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xc22):rand_win.c: undefined reference to `SelectObject@8' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xc29):rand_win.c: undefined reference to `DeleteObject@4' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xc33):rand_win.c: undefined reference to `DeleteDC@4' C:/msys/1.0/local/ssl/lib/libcrypto.a(rand_win.o)(.text+0xc3d):rand_win.c: undefined reference to `DeleteDC@4' configure:6671: $? = 1 configure: failed program was: #line 6642 "configure" //#include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char SSL_library_init (); #ifdef F77_DUMMY_MAIN # ifdef __cplusplus extern "C" # endif int F77_DUMMY_MAIN() { return 1; } #endif int main () { SSL_library_init (); ; return 0; } configure:6688: result: no configure:6698: error: library 'ssl' is required for OpenSSL ## ---------------- ## ## Cache variables. ## ## ---------------- ## ac_cv_build=i686-pc-mingw32 ac_cv_build_alias=i686-pc-mingw32 ac_cv_c_compiler_gnu=yes ... So it would seem that something is wrong with rand_win.c in my crypto library???? Has anyone who's compiled on mingw with openssl support run into this? I think Magnus' download page has a nightly snapshot that is compiled with openssl support. Perhaps he knows the voodoo involved? Thanks. -Tony _________________________________________________________________ Express yourself instantly with MSN Messenger! Download today - it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
pgsql-hackers-win32 by date: