[tz] iana build failures on Windows

Manuela Friedrich Manuela.Friedrich at actian.com
Tue Apr 27 11:02:33 UTC 2021


Hello Paul,

I rebuilt the latest git code but the zdump -v output is the same.

I created Abidjan-od-t-x1-win.txt and it is indeed different from your version.
Note it is the same as for the released 2021a version though.
Also the 2021a zdump -v worked fine on the 2021a Abidjan file.

Your zdump-2.diff produced the same result for me, see zdump-2-win.txt.

Regards
Manuela Friedrich

-----Original Message-----
From: Paul Eggert <eggert at cs.ucla.edu> 
Sent: Samstag, 24. April 2021 08:09
To: Manuela Friedrich <Manuela.Friedrich at actian.com>
Cc: Steven Shuriff <Steven.Shuriff at actian.com>; Time zone mailing list <tz at iana.org>
Subject: Re: iana build failures on Windows

On 4/22/21 11:22 PM, Manuela Friedrich wrote:

> please find the tracing output attached.

Thanks. Here's the first line that differs between your output (-) and mine (+):

-TRACING: lotm_ok=1 tm_ok=1 only_ok=0 lot=-1830384001 t=-1830383664
tm={1911-364T23:49:28 dst=0} lotm={1911-364T23:43:51 dst=0} delta=337
t-lot=337
+TRACING: lotm_ok=1 tm_ok=1 only_ok=0 lot=-1830383326 t=-1830382989
tm={1912-000T00:16:51 dst=0} lotm={1911-364T23:55:06 dst=0} delta=1305
t-lot=337

This difference suggests that for TZ=Africa/Abidjan and the timestamp -1830383495, tzdb's localtime behaves differently on your platform than on mine, although the two platforms agree on -1830384001 and on
-1830382989 (the point of disagreement is halfway between the two points of agreement). localtime should convert this timestamp to 1911-12-31
23:52:17 -00:16:08 LMT (with no DST), but evidently it converts to something else on your platform.

I see three things that could have gone wrong. First, while looking into this I noticed that relevant parts of zic.c and localtime.c rely on implementation-defined behavior when shifting or converting negative integers. Although I doubt that's your problem please try the latest GitHub tzdb development version, which has these fixes I installed today:

https://mm.icann.org/pipermail/tz/2021-April/030025.html
https://mm.icann.org/pipermail/tz/2021-April/030024.html

Second, the TZif file for Africa/Abidjan could be incorrect on your platform, which would mean a portability bug in zic.c. I'm attaching my Abidjan file (it's binary data) along with Abidjan-od-t-x1.txt, the output of the shell command 'od -t x1 Africa/Abidjan' (it's a textual representation of that data). Please compare this to your Abidjan file, making sure that it's the actual Abidjan file you're using (you perhaps have multiple near-copies of that file on your system by now...).

Third, there could be a problem in tzdb's localtime code. To test this, please apply the attached patch zdump-2.diff to otherwise-unmodified source code and then run 'zdump Africa/Abidjan' (without the '-v'). The output I get is also attached as zdump-2.txt; what output do you get?
-------------- next part --------------
d:\devsrc\treasure_test\iana\zoneinfo\iana\Africa\Abidjan  
t=-1830383495 sp->ats[0]=-1830383032 sp->timecnt=1
sp->ats[sp->timecnt-1]=-1830383032 sp->goback=0 sp->goahead=0
i=sp->defaulttype=0
ttisp->tt_utoff=-968
 localsub={1911-365 1911-12-31 23:52:17 dst=0}
Sun Dec 31 23:52:17 1911 LMT
-------------- next part --------------
0000000 54 5a 69 66 32 00 00 00 00 00 00 00 00 00 00 00
0000020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000040 00 00 00 01 00 00 00 02 00 00 00 08 92 e6 92 48
0000060 01 ff ff fc 38 00 00 00 00 00 00 00 04 4c 4d 54
0000100 00 47 4d 54 00 54 5a 69 66 32 00 00 00 00 00 00
0000120 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000140 00 00 00 00 00 00 00 00 01 00 00 00 02 00 00 00
0000160 08 ff ff ff ff 92 e6 92 48 01 ff ff fc 38 00 00
0000200 00 00 00 00 00 04 4c 4d 54 00 47 4d 54 00 0a 47
0000220 4d 54 30 0a
0000224
-------------- next part --------------
A non-text attachment was scrubbed...
Name: od-t-x1-diff.JPG
Type: image/jpeg
Size: 122977 bytes
Desc: od-t-x1-diff.JPG
URL: <http://mm.icann.org/pipermail/tz/attachments/20210427/56491946/od-t-x1-diff-0001.JPG>


More information about the tz mailing list