Re: [PATCHES] libpq build problem with <io.h>

From: Andreas Pflug <pgadmin(at)pse-consulting(dot)de>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Andrew Francis <locust(at)familyhealth(dot)com(dot)au>, pgsql-hackers-win32(at)postgresql(dot)org, PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: [PATCHES] libpq build problem with <io.h>
Date: 2004-08-17 10:40:58
Message-ID: 4121E0BA.1080301@pse-consulting.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers-win32 pgsql-patches

Bruce,

I posted the attached patch 4 days ago, with the comment
"The attached patch will redefine unlink and rename only if FRONTEND is
not defined.".

I still believe this a good way to fix it.

Tom Lane wrote:
>
>
> To put that in a more positive light: we like to think that our code is
> Posix-compliant and runs in a Posix-compliant environment. We're not
> thrilled about introducing non-Posix-isms for the convenience of one
> platform ... especially if there's no easy way to enforce that the
> nonstandard coding convention be used.
>
> Back on track: if rename() does exist under Windows then my idea is
> unreliable. Any other thoughts? How about #including <io.h> in port.h
> (for Windows only of course) before we #define these things?

Probably won't work, because pgrename and rename do not have the same
definition/linkage.

Regards,
Andreas

Attachment Content-Type Size
port.h.diff text/x-patch 567 bytes

In response to

Responses

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Mark Cave-Ayland 2004-08-17 14:33:49 Re: [PATCHES] GUC variables invisible to contrib/ modules
Previous Message Christian Klemke 2004-08-17 09:41:21 Re: our friend the win32 system timer.

Browse pgsql-patches by date

  From Date Subject
Next Message Fabien COELHO 2004-08-17 12:26:35 Re: [BUGS] BUG #1219: pgxs does not work fully
Previous Message Martin Münstermann 2004-08-17 07:24:37 Re: [BUGS] 8.0.0beta1: -lpthread missing