Re: FW: Timezone library

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Magnus Hagander <mha(at)sollentuna(dot)net>, pgsql-patches(at)postgresql(dot)org
Subject: Re: FW: Timezone library
Date: 2004-04-30 14:27:13
Message-ID: 200404301427.i3UERDY29123@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Tom Lane wrote:
> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > /usr/include/time.h:104: `pg_timezone' redeclared as different kind of
> > symbol
>
> Your <time.h> really defines "pg_timezone"?? I'm wondering if this is
> an indirect effect of a macro naming collision.

I applied the following patch to allow it to compile on Unix. I had to
mask the 'timezone' define before including "time.h".

I also pass pkglibdir into the timezone makefile like we do for fmgr so
it will know where to find the timezone database. This is probably only
an interim solution. We need a more general fix for lib/ anyway, and
this is basically the same problem (that the lib directory is compiled
into the binary and can't be moved).

With this change it compiles but I get this error:

zic -d /usr/local/pgsql/share/timezone data/africa data/antarctica
data/asia data/australasia data/europe data/northamerica
data/southamerica data/pacificnew data/etcetera data/factory
data/backward data/systemv data/solar87 data/solar88 data/solar89
"data/solar87", line 385: too many local time types (rule from
"data/solar87", line 45)

Magnus doesn't see it on Win32.

To test, define PGTZ in pg_config.h and set PGTZ=yes in Makefile.global.

--
Bruce Momjian | http://candle.pha.pa.us
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

Attachment Content-Type Size
unknown_filename text/plain 2.9 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2004-04-30 14:55:52 Re: Call for 7.5 feature completion
Previous Message Bruce Momjian 2004-04-30 14:23:04 Re: FW: Timezone library

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2004-04-30 14:37:46 Re: FW: Timezone library
Previous Message Bruce Momjian 2004-04-30 14:23:04 Re: FW: Timezone library