Re: Compiling beta2 with openssl on XP Pro

From: "Tony and Bryn Reina" <reina_ga(at)hotmail(dot)com>
To: "Magnus Hagander" <mha(at)sollentuna(dot)net>
Cc: <pgsql-hackers-win32(at)postgresql(dot)org>
Subject: Re: Compiling beta2 with openssl on XP Pro
Date: 2004-09-04 12:41:19
Message-ID: BAY8-DAV45tD8s5FWn700019578@hotmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers-win32

The gdi32 library seems to be the trick for the openssl fix. Note that the
order of the libraries seems to be critical: -lssl -lcrypto -lgdi32. Any
other order seems to throw an error for gcc.

I changed the configure file as follows:

6626,6627d6625
< LIBS="-lcrypto $LIBS"
<
6634d6631
<
6641c6638
< LIBS="-lssl $LIBS"
---
> LIBS="-lssl -lcrypto -lgdi32 $LIBS"
6695c6692
< LIBS="-lssl $LIBS"
---
> LIBS="-lssl -lcrypto -lgdi32 $LIBS"

and the src/Makefile.shlib to:

327c327
< $(DLLWRAP) -o $(shlib) --dllname $(shlib) $(DLLWRAP_FLAGS) --def
$(NAME).def $(OBJS) $(SHLIB_LINK)
---
> $(DLLWRAP) -o $(shlib) --dllname $(shlib) $(DLLWRAP_FLAGS) --def
> $(NAME).def $(OBJS) $(SHLIB_LINK) -lgdi32

The Makefile wasn't picking up the -lgdi32 flag from configure (or wherever
it should get it from).

In any case, with these simple changes OpenSSL doesn't have to be tweaked to
incorporate it into the Mingw build of PostgreSQL. I was able to compile and
install the CVS tip from last night with these minor changes. Having trouble
doing an initdb, but still working on it.

-Tony

----- Original Message -----
From: "Magnus Hagander" <mha(at)sollentuna(dot)net>
To: "Tony and Bryn Reina" <reina_ga(at)hotmail(dot)com>; "Tom Lane"
<tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-hackers-win32(at)postgresql(dot)org>
Sent: Thursday, September 02, 2004 8:09 PM
Subject: SV: [pgsql-hackers-win32] Compiling beta2 with openssl on XP Pro

This is the known issue that's on the open items list as "fix SSL compiles".

The way to get it done now is to edit the source to openssl and remove the
references to those functions. Yes, it's ugly and yes it needs a proper fix.

//Magnus

In response to

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Christopher Browne 2004-09-04 13:07:38 Re: Developers page is down
Previous Message Gaetano Mendola 2004-09-04 08:48:01 Re: Developers page is down