Update Zoneinfo
How to use the vzic program to update the libical builtin zoneinfo database.
Preparations
- clone vzic some place
git clone git@github.com:libical/vzic.git
-
Retrieve the most recent tzdata from IANA from http://www.iana.org/time-zones
Look for a gzip-compressed tar file (a "tarball") named tzdata2024b.tar.gz, for example.
Save the tarball into your Downloads folder. -
Uncompress and untar the "tarball" file into the vzic folder:
cd vzic
mkdir tzdata2024b
cd tzdata2024b; tar xvfz ~/Downloads/tzdata202ba.tar.gz; cd ..
Building vzic
cd vzic
make -B OLSON_DIR=tzdata2024b CREATE_SYMLINK=0 IGNORE_TOP_LEVEL_LINK=0
pass PRODUCT_ID
and TZID_PREFIX
as necessary (shouldn't be) or you could edit the top-level Makefile
Running vzic
./vzic
The output is placed in the zoneinfo subdirectory by default, but you can use the --output-dir
options to set another toplevel output directory.
You'll probably see some warning messages but not sure what to do about those. The "Modifying RRULE to be compatible with Outlook" warnings are normal and can be ignored.
Merging Changes to the Master Set of VTIMEZONES
-
Run
./vzic-merge.pl --master-zoneinfo-dir=/home/allen/projects/libical/libical/zoneinfo --new-zoneinfo-dir=/home/allen/projects/libical/vzic/zoneinfo
-
You must add the new timezones in the zones.tab file by hand.
cd to the libical git repo (eg.
/home/allen/projects/libical/libical/zoneinfo
)
rungit status
look for new .ics files to be added (i.e untracked files in the zoneinfo directory) -
diff the new from
vzic/zoneinfo/zones.tab
versus the updated zones.tab in the libical git repocopy lines from the new
vzic/zoneinfo/zones.tab
that are new (or differ) from the git repo version
Testing
- run
make test-vzic
and then run./test-vzic
(make sure libical is installed to /usr/local) - run the libical test-suite (
./scripts/buildtests.sh
)