Timezones on Tru64 (Digital Unix)

Started by Stephane Bortzmeyeralmost 26 years ago7 messagesgeneral
Jump to latest
#1Stephane Bortzmeyer
bortzmeyer@pasteur.fr

'set time zone 'GMT';', or any other 'set time zone' (even with numeric time
zones), is completely ignored on my Tru64 machine (I always get dates in local
time, UT+2). On Debian, everything is fine.

Did I forget something when compiling PostgreSQL? Is there something broken on
Tru64?

PostgreSQL 6.5. config.status follows:

./configure --with-template=alpha_cc --with-CC=cc --without-CXX \
--enable-locale --enable-cassert \
--with-perl --with-tcl --with-jdbc \
--with-x --with-pgport=5435

#2Stephane Bortzmeyer
bortzmeyer@pasteur.fr
In reply to: Stephane Bortzmeyer (#1)
Re: Timezones on Tru64 (Digital Unix)

On Tuesday 23 May 2000, at 14 h 17, the keyboard of Stephane Bortzmeyer
<bortzmeyer@pasteur.fr> wrote:

PostgreSQL 6.5.

And for those who wonder why I don't use 6.5.3, it's because, unlike 6.5, it doesn't compile on Tru64:

cc -I../../../include -I../../../backend -DNOFIXADE -std -O4 -Olimit 2000 -I../../../interfaces/libpq -I../../../include -I../../../backend -c -o pl_parse.o pl_gram.c
cc: Info: /usr/local/lib/bison.simple, line 300: In this statement, for the function "alloca", the implicit return type of "int" is not consistent with the expected type of "pointer to void". It will be treated as an ordinary implicitly defined external function. (bltinimplret)
plpgsql_yyss = (short *) alloca (plpgsql_yystacksize * sizeof (*plpgsql_yyssp));
-------------------------------^
cc -I../../../include -I../../../backend -DNOFIXADE -std -O4 -Olimit 2000 -I../../../interfaces/libpq -I../../../include -I../../../backend -c pl_handler.c -o pl_handler.o
cc -I../../../include -I../../../backend -DNOFIXADE -std -O4 -Olimit 2000 -I../../../interfaces/libpq -I../../../include -I../../../backend -c pl_comp.c -o pl_comp.o
cc: Error: pl_comp.c, line 72: The type of the tentatively-defined variable "plpgsql_yytext" is incomplete at the end of the compilation unit. (incomptent)
char plpgsql_yytext[];
--------^
make[3]: *** [pl_comp.o] Error 1
make[3]: Leaving directory `/local/packages/postgresql-6.5.3/src/pl/plpgsql/src'
make[2]: [all] Error 2 (ignored)
make[2]: Leaving directory `/local/packages/postgresql-6.5.3/src/pl/plpgsql'
make[1]: Leaving directory `/local/packages/postgresql-6.5.3/src/pl'

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Stephane Bortzmeyer (#2)
Re: Timezones on Tru64 (Digital Unix)

Stephane Bortzmeyer <bortzmeyer@pasteur.fr> writes:

And for those who wonder why I don't use 6.5.3, it's because, unlike
6.5, it doesn't compile on Tru64:

So have you tried 7.0 ?

Reports of porting problems for 7.0 will be gladly accepted, but you
are a few months too late to attract much interest in fixing such
glitches in 6.5.* ...

regards, tom lane

#4SL Baur
steve@beopen.com
In reply to: Stephane Bortzmeyer (#2)
Re: Timezones on Tru64 (Digital Unix)

Tom Lane <tgl@sss.pgh.pa.us> writes in pgsql-general@postgresql.org:

Stephane Bortzmeyer <bortzmeyer@pasteur.fr> writes:

And for those who wonder why I don't use 6.5.3, it's because, unlike
6.5, it doesn't compile on Tru64:

7.0 builds fine on Tru64.

So have you tried 7.0 ?

I just did and it doesn't work. I've built with locale and multibyte
enabled and tested in both C locale and a Japanese locale.

steve=# select now();
now
------------------------
2000-05-24 15:11:10+09
(1 row)

steve=# set timezone='US/Pacific';
SET VARIABLE
steve=# select now();
now
------------------------
2000-05-24 15:11:20+09
(1 row)

#5SL Baur
steve@beopen.com
In reply to: Stephane Bortzmeyer (#2)
Re: Timezones on Tru64 (Digital Unix)

SL Baur <steve@beopen.com> writes in pgsql-general@postgresql.org:

I just did and it doesn't work.

Oops. I didn't check carefully enough. Sorry.

steve=# set timezone='US/Pacific';

That's incorrect syntax, it appears. Setting the timezone as `PST8PDT'
or `:US/Pacific' works.

To answer the original question, GMT is named `GMT0' on Tru64.

steve=# set timezone='GMT0';
SET VARIABLE
steve=# select now();
now
------------------------
2000-05-24 07:04:37+00
(1 row)

#6Stephane Bortzmeyer
bortzmeyer@pasteur.fr
In reply to: SL Baur (#5)
Re: Timezones on Tru64 (Digital Unix)

On Wednesday 24 May 2000, at 16 h 8, the keyboard of SL Baur <steve@beopen.com>
wrote:

To answer the original question, GMT is named `GMT0' on Tru64.

It works fine, even on 6.5. I love portability on Unix :-} I noticed that PostgreSQL's documentation warns about the fact that the is no standard naming of timezones but I would never have thought that GMT is not standard!

Many thanks.

#7Tom Lane
tgl@sss.pgh.pa.us
In reply to: SL Baur (#5)
Re: Timezones on Tru64 (Digital Unix)

SL Baur <steve@beopen.com> writes:

Oops. I didn't check carefully enough. Sorry.

steve=# set timezone='US/Pacific';

That's incorrect syntax, it appears. Setting the timezone as `PST8PDT'
or `:US/Pacific' works.

Looking at the code, it seems that 'set timezone' is implemented
directly as setting the TZ environment variable in the server.
So whatever timezone names are known to your local tzset() are the
ones that should work. I'd expect names like `PST8PDT' to be
pretty standard, other names less so...

regards, tom lane