Time zone confusion and implementation hints

Yves Goergen nospam.list at unclassified.de
Tue Jul 6 19:58:29 UTC 2010

On 06.07.2010 20:57 CE(S)T, lennox at cs.columbia.edu wrote:
> * set CFLAGS in the tzcode Makefile to

> * write a wrapper function for link() mapping it to the Windows NT
>   CreateHardLink function:

Thank you for these tips. I could now build zic with Visual Studio and
the following command:

ialloc.c my_getopt.c my_link.c

I needed to insert #include "getopt.h" in private.h (I thought it is an
appropriate location) and copy my_getopt (see other message) and another
c file with your link function into it.

I now have the following source files:


In the end I have a zic.exe that seems to do the job. I run it like this:

zic -d output input/africa input/antarctica input/asia input/australasia
input/etcetera input/europe input/northamerica input/pacificnew

(Windows CMD doesn't expand * like bash would do and zic doesn't do it
either so I need to specify all files separately.)

It creates 457 files in 16 directories with a total size of 536 kB.

After looking into the resulting files, I have the impression that the
transition timestamps are all 32-bit, even in the 64-bit v2 section
(half of the bytes in that area are 0). I assume that zic only creates
transition records until before 2038. How can I extend that range? I
didn't find a good place in the code.

> If you need to support older filesystems, e.g. FAT32, you could alternately
> map link() to CopyFile instead.

What does zic use links for? Does it link zone aliases? I think I won't
need them in my calendar application, do I? Could I disable creating
duplicate files (or linking them)?

Yves Goergen "LonelyPixel" <nospam.list at unclassified.de>
Visit my web laboratory at http://beta.unclassified.de

More information about the tz mailing list