fix for client utils compilation under win32

From: Joe Conway <mail(at)joeconway(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: fix for client utils compilation under win32
Date: 2002-09-26 21:37:11
Message-ID: 3D937E07.9020605@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> It might work to measure time since the start of the whole process, or
> until the timeout target, rather than accumulating adjustments to the
> "remains" count each time through. In other words something like
>
> at start: targettime = time() + specified-timeout
>
> each time we are about to wait: set select timeout to
> targettime - time().
>
> This bounds the error at 1 second which is probably good enough (you
> might want to add 1 to targettime to ensure the error is in the
> conservative direction of not timing out too soon).
>

The attached patch fixes a number of issues related to compiling the client
utilities (libpq.dll and psql.exe) for win32 (missing defines, adjustments to
includes, pedantic casting, non-existent functions) per:
http://developer.postgresql.org/docs/postgres/install-win32.html.

It compiles cleanly under Windows 2000 using Visual Studio .net. Also compiles
clean and passes all regression tests (regular and contrib) under Linux.

In addition to a review by the usual suspects, it would be very desirable for
someone well versed in the peculiarities of win32 to take a look.

If there are no objections, please commit.

Thanks,

Joe

Attachment Content-Type Size
pgsql.w32.3.patch text/plain 22.8 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2002-09-26 21:39:14 Re: [HACKERS] Performance while loading data and indexing
Previous Message Doug McNaught 2002-09-26 21:37:10 Re: [HACKERS] Performance while loading data and indexing