Re: [BUGS] (Modified) Patch request for PostgreSQL 7.4

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: "Patches (PostgreSQL)" <pgsql-patches(at)postgresql(dot)org>
Subject: Re: [BUGS] (Modified) Patch request for PostgreSQL 7.4
Date: 2003-12-09 20:39:12
Message-ID: 3FD632F0.6030800@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches


It just struck me that *maybe* a portable solution would be to put the
awk output inside genbki.sh in a .h file and then #include it in a one
line .c file which is passed to the preprocessor. Would that keep the
(strange) HP compiler happy?

cheers

andrew

ViSolve Open Source Team wrote:

>
> **
> *2. About the TMPFILE definition change from .c to .h:*
> Unfortunately, the -V option does not work the same way across HP
> compilers (it works as expected with HP aCC, but not with HP cc).
>
> We have a couple of alternatives here.
>
> a. Using `uname` (to look for HP-UX) /and/ checking to see if
> *$CPP* is set to //usr/bin/cc/ or //opt/aCC/bin/aCC./ Not good.
> b. Doing nothing. The TMPFILE mod is a trivial change to make with
> each new version of PostgreSQL that we build for HP-UX. (We had in
> fact suggested this in our original request email). So if you make no
> changes to the TMPFILE code, that will be fine too.
>
> thanks
> ViSolve OpenSource Team
>
> ============================================================================
>
> From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us
> <mailto:pgman(at)candle(dot)pha(dot)pa(dot)us>
>
> Subject: Re: [BUGS] (Modified) Patch request for PostgreSQL 7.4 for HP-UX
> IA-64
>
>
> Peter also mentioned:
>
> >You're doing this:
>
> >-TMPFILE="$TMPDIR/genbkitmp$$.c"
> >+TMPFILE="$TMPDIR/genbkitmp$$.h"
>
> I'm afraid this will not fly, because calling the preprocessor is only
> portable on .c files. Generally, it's also unwise to rely in this kind
> of subtle side effect. We need a general solution.
>
> Can you give us a way to test for your preprocessor? Is there some
> unique output like --version or -V that we can test and use *.h only
> in that case?
>
> --
> Bruce Momjian | http://candle.pha.pa.us
> pgman(at)candle(dot)pha(dot)pa(dot)us <mailto:pgman(at)candle(dot)pha(dot)pa(dot)us>
> | (610) 359-1001
> + If your life is a hard drive, | 13 Roberts Road
> + Christ can be your backup. | Newtown Square, Pennsylvania
> 19073
> ====================================================================================
>
>
>
>
>
>

In response to

Browse pgsql-patches by date

  From Date Subject
Next Message Kurt Roeckx 2003-12-09 21:14:47 on_proc_exit/on_shmem_exit prototypes.
Previous Message Claudio Natoli 2003-12-09 13:28:19 Comments requested on attached fork/exec patch