zic: symlink generation issue

Hello, on openSUSE we are seeing issues generating symlinks after replacing our distribution specific patches with the upstream code: $ rm /etc/localtime $ ln -s /usr/share/zoneinfo/Europe/London /etc/localtime $ ls -l /etc/localtime lrwxrwxrwx 1 root root 33 Oct 6 12:47 /etc/localtime -> /usr/share/zoneinfo/Europe/London $ zic -l Europe/Berlin $ ls -l /etc/localtime lrwxrwxrwx 1 root root 19 Oct 6 11:47 /etc/localtime -> ../../Europe/Berlin resulting in a broken symbolic link. The previous code supplied relname(), and in dolink() instead of calculating the dotdots using fromfield/tofield we used fromname/toname, respectively. I though I'd let you know while we are working on this, in case you have a quick fix. Otherwise we'll attempt to upstream what we come up with. Andreas -- Andreas Stieger <astieger@suse.com> Project Manager Security SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)

Thanks for reporting that bug. When adding support for keeping symlinks in 2016g, I didn't think about the possibility of TZDEFAULT being defined to an absolute file name. Please try the attached patch, which I've installed into the development repository on GitHub.

Hello Paul, On 10/06/2016 08:50 PM, Paul Eggert wrote:
When adding support for keeping symlinks in 2016g, I didn't think about the possibility of TZDEFAULT being defined to an absolute file name.
df9991a2186d4236ba1e97e6638fa53b578bc6d7 appears to fix the issue, and our bug https://bugzilla.opensuse.org/show_bug.cgi?id=1003324 We'll give it a spin in automation and QA. Thanks, Andreas -- Andreas Stieger <astieger@suse.com> Project Manager Security SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)
participants (2)
-
Andreas Stieger
-
Paul Eggert