Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system - Mailing list pgsql-hackers

From Gregory Stark
Subject Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system
Date
Msg-id 87absjw39o.fsf@oxford.xeocode.com
Whole thread Raw
In response to Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system  (Peter Eisentraut <peter_e@gmx.net>)
Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
List pgsql-hackers
"Tom Lane" <tgl@sss.pgh.pa.us> writes:

> In the first place, it is considered bad form for a package to install
> an absolute symlink to /usr/share/zoneinfo:
>
> "symlinks _should_ be relative.  Even if all they have in common is /."
> - Jeremy Katz
> https://www.redhat.com/archives/fedora-maintainers/2007-August/msg00096.html
>
> Followup arguments in that thread mentioned chroots and NFS mounts as
> environments where absolute symlinks are likely to lead to the wrong
> place.  

Fwiw Debian also faced this issue and came to a different conclusion. IIRC the
policy is that it's explicitly supported for a sysadmin to replace any
directory in the top level directory with a symlink. So for example /home ->
/export/home.

Therefore any package which includes a symlink which traverses between top
level directories *must* be absolute. And any symlink which does not span two
top level directories *must* be relative. So /usr/foo/bar which links to
/var/foo/bar must be absolute. But /usr/foo/bar which links to /usr/qux/bar
must be a relative link ../qux/bar.

> In short, then, the patch actually being used (as of today) in Fedora
> and ultimately RHEL is as below, and I don't see any prospect of
> substituting the mechanism Peter has created.

Why would --with-zoneinfo want to use a symlink though? Shouldn't it just
compile the binary to use the path specified directly? Symlinks are fine for a
sysadmin or a packager but if it's going to be supported by Postgres code
directly why not do it directly?

--  Gregory Stark EnterpriseDB          http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [COMMITTERS] pgsql: Add configure option --with-system-tzdata to use operating system
Next
From: "Ben Tilly"
Date:
Subject: SQL feature requests