Hi,
(14 years later...)
I'm also trying to setup a system with TAI as CLOCK_REALTIME.
UTC - TAI offset is now 37s. But the offset between the "posix" and
"right" zoneinfo is only 27s :
$ TZDIR=/usr/share/zoneinfo/right TZ=Europe/Paris date; \
TZDIR=/usr/share/zoneinfo/posix TZ=Europe/Paris date
Mon Jan 16 11:17:00 CET 2023
Mon Jan 16 11:17:27 CET 2023
Readme.debian says:
- TZDIR=/usr/share/zoneinfo/posix TZ=Europe/Paris on a system with
hardware clock set to UTC. > - TZDIR=/usr/share/zoneinfo/right TZ=Europe/Paris on a system with >
*hardware clock set to TAI*.
(emphasis is mine)
Which means that with CLOCK_REALTIME setup as TAI and TZDIR=.../right,
the displayed time is wrong by 10s.
I've check the content of right/UTC and it contains a leapsecond offset
of 27s since 01-01-2017. I guess it miss the original UTC-TAI offset of
10s (before the first leapsecond in June 1972)
Either something is wrong in the "right" zoneinfo or the doc (or I'm
mistaken).
As a workaround, I've setup CLOCK_REALTIME as TAI+10s and using the
"right" zoneinfo, the displayed time is correct.
Regards,
--
Yoann Congal
Smile ECS - Tech Expert