Re: Suggestion for MSVC build - Mailing list pgsql-hackers

From Chuck McDevitt
Subject Re: Suggestion for MSVC build
Date
Msg-id EB48EBF3B239E948AC1E3F3780CF8F8802A1B52A@MI8NYCMAIL02.Mi8.com
Whole thread Raw
In response to Suggestion for MSVC build  ("Chuck McDevitt" <cmcdevitt@greenplum.com>)
Responses Re: Suggestion for MSVC build
Re: Suggestion for MSVC build
List pgsql-hackers
Actually, the more I look at it, I realize it was correct before

We want to link against readline.lib and history.lib, but the ones in
the GnuWin32 distribution are broken.
The .lib files are made from the .def files, which are supposed to list
the exports, but don't.

They can be made from commands like this:

lib /machine:i386 /def:readline.def
lib /machine:i386 /def:history.def

But that only works if the .def files list the routines you want
exported.

It's easy enough to add the few we use by hand, but I'm not sure why
they aren't there.
Adding them, running those lib commands, allowed me to link with no
errors or warnings.

Maybe I need to do some research on readline... this seems more
complicated than I expected.
Does no one else use readline on Windows?  Is the Gnuwin32 readline a
fraud?  I just don't know.






> -----Original Message-----
> From: Chuck McDevitt
> Sent: Monday, September 24, 2007 2:17 PM
> To: Magnus Hagander
> Cc: pgsql-hackers@postgresql.org
> Subject: RE: [HACKERS] Suggestion for MSVC build
>
> The right lib files to link readline are the .a ones...
>
> Like this:
>
> if ($solution->{options}->{readline})
>     {
>         $psql->AddIncludeDir($solution->{options}->{readline} .
> '\include');
>         $psql->AddLibrary($solution->{options}->{readline} .
> '\lib\libreadline.dll.a');
>         $psql->AddLibrary($solution->{options}->{readline} .
> '\lib\libhistory.dll.a');
>     }
>
\



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: MSVC build scripts status
Next
From: "Mark Wong"
Date:
Subject: top for postgresql (ptop?)