From 6a2b75c2c88ac583362d8300163fc2332851c6c8 Mon Sep 17 00:00:00 2001 From: Bruce Momjian Date: Fri, 30 Apr 2004 04:09:23 +0000 Subject: [PATCH] Add Olson's public domain timezone library to src/timezone. --- src/timezone/Makefile | 33 + src/timezone/README | 17 + src/timezone/asctime.c | 74 + src/timezone/data/africa | 605 ++++++++ src/timezone/data/antarctica | 318 ++++ src/timezone/data/asia | 1458 +++++++++++++++++++ src/timezone/data/australasia | 1338 +++++++++++++++++ src/timezone/data/backward | 95 ++ src/timezone/data/etcetera | 79 + src/timezone/data/europe | 2389 +++++++++++++++++++++++++++++++ src/timezone/data/factory | 8 + src/timezone/data/iso3166.tab | 262 ++++ src/timezone/data/leapseconds | 79 + src/timezone/data/northamerica | 1968 +++++++++++++++++++++++++ src/timezone/data/pacificnew | 26 + src/timezone/data/solar87 | 388 +++++ src/timezone/data/solar88 | 388 +++++ src/timezone/data/solar89 | 393 +++++ src/timezone/data/southamerica | 934 ++++++++++++ src/timezone/data/systemv | 50 + src/timezone/data/yearistype.sh | 37 + src/timezone/data/zone.tab | 402 ++++++ src/timezone/difftime.c | 83 ++ src/timezone/ialloc.c | 81 ++ src/timezone/localtime.c | 1707 ++++++++++++++++++++++ src/timezone/pgtz.c | 42 + src/timezone/pgtz.h | 8 + src/timezone/private.h | 294 ++++ src/timezone/scheck.c | 59 + src/timezone/tzfile.h | 188 +++ src/timezone/zic.c | 2236 +++++++++++++++++++++++++++++ 31 files changed, 16039 insertions(+) create mode 100644 src/timezone/Makefile create mode 100644 src/timezone/README create mode 100644 src/timezone/asctime.c create mode 100644 src/timezone/data/africa create mode 100644 src/timezone/data/antarctica create mode 100644 src/timezone/data/asia create mode 100644 src/timezone/data/australasia create mode 100644 src/timezone/data/backward create mode 100644 src/timezone/data/etcetera create mode 100644 src/timezone/data/europe create mode 100644 src/timezone/data/factory create mode 100644 src/timezone/data/iso3166.tab create mode 100644 src/timezone/data/leapseconds create mode 100644 src/timezone/data/northamerica create mode 100644 src/timezone/data/pacificnew create mode 100644 src/timezone/data/solar87 create mode 100644 src/timezone/data/solar88 create mode 100644 src/timezone/data/solar89 create mode 100644 src/timezone/data/southamerica create mode 100644 src/timezone/data/systemv create mode 100755 src/timezone/data/yearistype.sh create mode 100644 src/timezone/data/zone.tab create mode 100644 src/timezone/difftime.c create mode 100644 src/timezone/ialloc.c create mode 100644 src/timezone/localtime.c create mode 100644 src/timezone/pgtz.c create mode 100644 src/timezone/pgtz.h create mode 100644 src/timezone/private.h create mode 100644 src/timezone/scheck.c create mode 100644 src/timezone/tzfile.h create mode 100644 src/timezone/zic.c diff --git a/src/timezone/Makefile b/src/timezone/Makefile new file mode 100644 index 0000000000..b087b818ff --- /dev/null +++ b/src/timezone/Makefile @@ -0,0 +1,33 @@ +#------------------------------------------------------------------------- +# +# Makefile-- +# Makefile for the timezone library + +# IDENTIFICATION +# $PostgreSQL: pgsql/src/timezone/Makefile,v 1.1 2004/04/30 04:09:23 momjian Exp $ +# +#------------------------------------------------------------------------- + +subdir = src/port/tz +top_builddir = ../../.. +include $(top_builddir)/src/Makefile.global + +OBJS= asctime.o difftime.o localtime.o pgtz.o +ZICOBJS= zic.o ialloc.o scheck.o localtime.o asctime.o pgtz.o ../path.o + +TZDATA := africa antarctica asia australasia europe northamerica southamerica pacificnew etcetera factory backward systemv solar87 solar88 solar89 +TZDATAFILES := $(TZDATA:%=data/%) + +all: SUBSYS.o zic + +SUBSYS.o: $(OBJS) + $(LD) $(LDREL) $(LDOUT) SUBSYS.o $(OBJS) + + +zic: $(ZICOBJS) + +install: zic + zic -d $(datadir)/timezone $(TZDATAFILES) + +clean distclean maintainer-clean: + rm -f SUBSYS.o $(OBJS) $(ZICOBJS) diff --git a/src/timezone/README b/src/timezone/README new file mode 100644 index 0000000000..79b6ee7d97 --- /dev/null +++ b/src/timezone/README @@ -0,0 +1,17 @@ +This is a PostgreSQL adapted version of the timezone library +from: +ftp://elsie.nci.nih.gov/pub/tz*.tar.gz + + +The interface is used when USE_PGTZ is defined at the top level. This +will cause the following functions to be redefined: + localtime pg_localtime + gmtime pg_gmtime + asctime pg_asctime + ctime pg_ctime + difftime pg_difftime + mktime pg_mktime + tzset pg_tzset + +and the TIMEZONE_GLOBAL define in c.h is redefined to pg_timezone. + diff --git a/src/timezone/asctime.c b/src/timezone/asctime.c new file mode 100644 index 0000000000..7054c75458 --- /dev/null +++ b/src/timezone/asctime.c @@ -0,0 +1,74 @@ +/* +** This file is in the public domain, so clarified as of +** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). +*/ + +#ifndef lint +#ifndef NOID +static char elsieid[] = "@(#)asctime.c 7.9"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/*LINTLIBRARY*/ + +#include "private.h" +#include "tzfile.h" + +/* +** A la ISO/IEC 9945-1, ANSI/IEEE Std 1003.1, Second Edition, 1996-07-12. +*/ + +char * +asctime_r(timeptr, buf) +register const struct tm * timeptr; +char * buf; +{ + static const char wday_name[][3] = { + "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" + }; + static const char mon_name[][3] = { + "Jan", "Feb", "Mar", "Apr", "May", "Jun", + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" + }; + register const char * wn; + register const char * mn; + + if (timeptr->tm_wday < 0 || timeptr->tm_wday >= DAYSPERWEEK) + wn = "???"; + else wn = wday_name[timeptr->tm_wday]; + if (timeptr->tm_mon < 0 || timeptr->tm_mon >= MONSPERYEAR) + mn = "???"; + else mn = mon_name[timeptr->tm_mon]; + /* + ** The X3J11-suggested format is + ** "%.3s %.3s%3d %02.2d:%02.2d:%02.2d %d\n" + ** Since the .2 in 02.2d is ignored, we drop it. + */ + (void) sprintf(buf, "%.3s %.3s%3d %02d:%02d:%02d %d\n", + wn, mn, + timeptr->tm_mday, timeptr->tm_hour, + timeptr->tm_min, timeptr->tm_sec, + TM_YEAR_BASE + timeptr->tm_year); + return buf; +} + +/* +** A la X3J11, with core dump avoidance. +*/ + +char * +asctime(timeptr) +register const struct tm * timeptr; +{ + /* + ** Big enough for something such as + ** ??? ???-2147483648 -2147483648:-2147483648:-2147483648 -2147483648\n + ** (two three-character abbreviations, five strings denoting integers, + ** three explicit spaces, two explicit colons, a newline, + ** and a trailing ASCII nul). + */ + static char result[3 * 2 + 5 * INT_STRLEN_MAXIMUM(int) + + 3 + 2 + 1 + 1]; + + return asctime_r(timeptr, result); +} diff --git a/src/timezone/data/africa b/src/timezone/data/africa new file mode 100644 index 0000000000..e8223f78f5 --- /dev/null +++ b/src/timezone/data/africa @@ -0,0 +1,605 @@ +# @(#)africa 7.36 + +# This data is by no means authoritative; if you think you know better, +# go ahead and edit the file (and please send any changes to +# tz@elsie.nci.nih.gov for general use in the future). + +# From Paul Eggert (1999-03-22): +# +# A good source for time zone historical data outside the U.S. is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1990, +# and IATA SSIM is the source for entries after 1990. +# +# Another source occasionally used is Edward W. Whitman, World Time Differences, +# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which +# I found in the UCLA library. +# +# A reliable and entertaining source about time zones is +# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997). +# +# Previous editions of this database used WAT, CAT, SAT, and EAT +# for +0:00 through +3:00, respectively, +# but Mark R V Murray reports that +# `SAST' is the official abbreviation for +2:00 in the country of South Africa, +# `CAT' is commonly used for +2:00 in countries north of South Africa, and +# `WAT' is probably the best name for +1:00, as the common phrase for +# the area that includes Nigeria is ``West Africa''. +# He has heard of ``Western Sahara Time'' for +0:00 but can find no reference. +# +# To make things confusing, `WAT' seems to have been used for -1:00 long ago; +# I'd guess that this was because people needed _some_ name for -1:00, +# and at the time, far west Africa was the only major land area in -1:00. +# This usage is now obsolete, as the last use of -1:00 on the African +# mainland seems to have been 1976 in Western Sahara. +# +# To summarize, the following abbreviations seem to have some currency: +# -1:00 WAT West Africa Time (no longer used) +# 0:00 GMT Greenwich Mean Time +# 2:00 CAT Central Africa Time +# 2:00 SAST South Africa Standard Time +# and Murray suggests the following abbreviation: +# 1:00 WAT West Africa Time +# I realize that this leads to `WAT' being used for both -1:00 and 1:00 +# for times before 1976, but this is the best I can think of +# until we get more information. +# +# I invented the following abbreviations; corrections are welcome! +# 2:00 WAST West Africa Summer Time +# 2:30 BEAT British East Africa Time (no longer used) +# 2:44:45 BEAUT British East Africa Unified Time (no longer used) +# 3:00 CAST Central Africa Summer Time (no longer used) +# 3:00 SAST South Africa Summer Time (no longer used) +# 3:00 EAT East Africa Time +# 4:00 EAST East Africa Summer Time (no longer used) + +# Algeria +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Algeria 1916 only - Jun 14 23:00s 1:00 S +Rule Algeria 1916 1919 - Oct Sun<=7 23:00s 0 - +Rule Algeria 1917 only - Mar 24 23:00s 1:00 S +Rule Algeria 1918 only - Mar 9 23:00s 1:00 S +Rule Algeria 1919 only - Mar 1 23:00s 1:00 S +Rule Algeria 1920 only - Feb 14 23:00s 1:00 S +Rule Algeria 1920 only - Oct 23 23:00s 0 - +Rule Algeria 1921 only - Mar 14 23:00s 1:00 S +Rule Algeria 1921 only - Jun 21 23:00s 0 - +Rule Algeria 1939 only - Sep 11 23:00s 1:00 S +Rule Algeria 1939 only - Nov 19 1:00 0 - +Rule Algeria 1944 1945 - Apr Mon<=7 2:00 1:00 S +Rule Algeria 1944 only - Oct 8 2:00 0 - +Rule Algeria 1945 only - Sep 16 1:00 0 - +Rule Algeria 1971 only - Apr 25 23:00s 1:00 S +Rule Algeria 1971 only - Sep 26 23:00s 0 - +Rule Algeria 1977 only - May 6 0:00 1:00 S +Rule Algeria 1977 only - Oct 21 0:00 0 - +Rule Algeria 1978 only - Mar 24 1:00 1:00 S +Rule Algeria 1978 only - Sep 22 3:00 0 - +Rule Algeria 1980 only - Apr 25 0:00 1:00 S +Rule Algeria 1980 only - Oct 31 2:00 0 - +# Shanks gives 0:09 for Paris Mean Time; go with Howse's more precise 0:09:21. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Algiers 0:12:12 - LMT 1891 Mar 15 0:01 + 0:09:21 - PMT 1911 Mar 11 # Paris Mean Time + 0:00 Algeria WE%sT 1940 Feb 25 2:00 + 1:00 Algeria CE%sT 1946 Oct 7 + 0:00 - WET 1956 Jan 29 + 1:00 - CET 1963 Apr 14 + 0:00 Algeria WE%sT 1977 Oct 21 + 1:00 Algeria CE%sT 1979 Oct 26 + 0:00 Algeria WE%sT 1981 May + 1:00 - CET + +# Angola +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Luanda 0:52:56 - LMT 1892 + 0:52:04 - AOT 1911 May 26 # Angola Time + 1:00 - WAT + +# Benin +# Whitman says they switched to 1:00 in 1946, not 1934; go with Shanks. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Porto-Novo 0:10:28 - LMT 1912 + 0:00 - GMT 1934 Feb 26 + 1:00 - WAT + +# Botswana +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Gaborone 1:43:40 - LMT 1885 + 2:00 - CAT 1943 Sep 19 2:00 + 2:00 1:00 CAST 1944 Mar 19 2:00 + 2:00 - CAT + +# Burkina Faso +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Ouagadougou -0:06:04 - LMT 1912 + 0:00 - GMT + +# Burundi +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Bujumbura 1:57:28 - LMT 1890 + 2:00 - CAT + +# Cameroon +# Whitman says they switched to 1:00 in 1920; go with Shanks. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Douala 0:38:48 - LMT 1912 + 1:00 - WAT + +# Cape Verde +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/Cape_Verde -1:34:04 - LMT 1907 # Praia + -2:00 - CVT 1942 Sep + -2:00 1:00 CVST 1945 Oct 15 + -2:00 - CVT 1975 Nov 25 2:00 + -1:00 - CVT + +# Central African Republic +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Bangui 1:14:20 - LMT 1912 + 1:00 - WAT + +# Chad +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Ndjamena 1:00:12 - LMT 1912 + 1:00 - WAT 1979 Oct 14 + 1:00 1:00 WAST 1980 Mar 8 + 1:00 - WAT + +# Comoros +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Comoro 2:53:04 - LMT 1911 Jul # Moroni, Gran Comoro + 3:00 - EAT + +# Democratic Republic of Congo +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Kinshasa 1:01:12 - LMT 1897 Nov 9 + 1:00 - WAT +Zone Africa/Lubumbashi 1:49:52 - LMT 1897 Nov 9 + 2:00 - CAT + +# Republic of the Congo +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Brazzaville 1:01:08 - LMT 1912 + 1:00 - WAT + +# Cote D'Ivoire +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Abidjan -0:16:08 - LMT 1912 + 0:00 - GMT + +# Djibouti +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Djibouti 2:52:36 - LMT 1911 Jul + 3:00 - EAT + +############################################################################### + +# Egypt + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Egypt 1940 only - Jul 15 0:00 1:00 S +Rule Egypt 1940 only - Oct 1 0:00 0 - +Rule Egypt 1941 only - Apr 15 0:00 1:00 S +Rule Egypt 1941 only - Sep 16 0:00 0 - +Rule Egypt 1942 1944 - Apr 1 0:00 1:00 S +Rule Egypt 1942 only - Oct 27 0:00 0 - +Rule Egypt 1943 1945 - Nov 1 0:00 0 - +Rule Egypt 1945 only - Apr 16 0:00 1:00 S +Rule Egypt 1957 only - May 10 0:00 1:00 S +Rule Egypt 1957 1958 - Oct 1 0:00 0 - +Rule Egypt 1958 only - May 1 0:00 1:00 S +Rule Egypt 1959 1981 - May 1 1:00 1:00 S +Rule Egypt 1959 1965 - Sep 30 3:00 0 - +Rule Egypt 1966 1994 - Oct 1 3:00 0 - +Rule Egypt 1982 only - Jul 25 1:00 1:00 S +Rule Egypt 1983 only - Jul 12 1:00 1:00 S +Rule Egypt 1984 1988 - May 1 1:00 1:00 S +Rule Egypt 1989 only - May 6 1:00 1:00 S +Rule Egypt 1990 1994 - May 1 1:00 1:00 S +# IATA (after 1990) says transitions are at 0:00. +# Go with IATA starting in 1995, except correct 1995 entry from 09-30 to 09-29. +Rule Egypt 1995 max - Apr lastFri 0:00s 1:00 S +Rule Egypt 1995 max - Sep lastThu 23:00s 0 - + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Cairo 2:05:00 - LMT 1900 Oct + 2:00 Egypt EE%sT + +# Equatorial Guinea +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Malabo 0:35:08 - LMT 1912 + 0:00 - GMT 1963 Dec 15 + 1:00 - WAT + +# Eritrea +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Asmera 2:35:32 - LMT 1870 + 2:35:32 - AMT 1890 # Asmera Mean Time + 2:35:20 - ADMT 1936 May 5 # Adis Dera MT + 3:00 - EAT + +# Ethiopia +# From Paul Eggert (1997-10-05): +# Shanks writes that Ethiopia had six narrowly-spaced time zones between +# 1870 and 1890, and that they merged to 38E50 (2:35:20) in 1890. +# We'll guess that 38E50 is for Adis Dera. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Addis_Ababa 2:34:48 - LMT 1870 + 2:35:20 - ADMT 1936 May 5 # Adis Dera MT + 3:00 - EAT + +# Gabon +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Libreville 0:37:48 - LMT 1912 + 1:00 - WAT + +# Gambia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Banjul -1:06:36 - LMT 1912 + -1:06:36 - BMT 1935 # Banjul Mean Time + -1:00 - WAT 1964 + 0:00 - GMT + +# Ghana +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Whitman says DST was observed from 1931 to ``the present''; go with Shanks. +Rule Ghana 1936 1942 - Sep 1 0:00 0:20 GHST +Rule Ghana 1936 1942 - Dec 31 0:00 0 GMT +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Accra -0:00:52 - LMT 1918 + 0:00 Ghana %s + +# Guinea +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Conakry -0:54:52 - LMT 1912 + 0:00 - GMT 1934 Feb 26 + -1:00 - WAT 1960 + 0:00 - GMT + +# Guinea-Bissau +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Bissau -1:02:20 - LMT 1911 May 26 + -1:00 - WAT 1975 + 0:00 - GMT + +# Kenya +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Nairobi 2:27:16 - LMT 1928 Jul + 3:00 - EAT 1930 + 2:30 - BEAT 1940 + 2:44:45 - BEAUT 1960 + 3:00 - EAT + +# Lesotho +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Maseru 1:50:00 - LMT 1903 Mar + 2:00 - SAST 1943 Sep 19 2:00 + 2:00 1:00 SAST 1944 Mar 19 2:00 + 2:00 - SAST + +# Liberia +# From Paul Eggert (2001-07-17): +# In 1972 Liberia was the last country to switch +# from a UTC offset that was not a multiple of 15 or 20 minutes. +# Howse reports that it was in honor of their president's birthday. +# Shanks reports the date as May 1, whereas Howse reports Jan; go with Shanks. +# For Liberia before 1972, Shanks reports -0:44, whereas Howse and Whitman +# each report -0:44:30; go with the more precise figure. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Monrovia -0:43:08 - LMT 1882 + -0:43:08 - MMT 1919 Mar # Monrovia Mean Time + -0:44:30 - LRT 1972 May # Liberia Time + 0:00 - GMT + +############################################################################### + +# Libya + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Libya 1951 only - Oct 14 2:00 1:00 S +Rule Libya 1952 only - Jan 1 0:00 0 - +Rule Libya 1953 only - Oct 9 2:00 1:00 S +Rule Libya 1954 only - Jan 1 0:00 0 - +Rule Libya 1955 only - Sep 30 0:00 1:00 S +Rule Libya 1956 only - Jan 1 0:00 0 - +Rule Libya 1982 1984 - Apr 1 0:00 1:00 S +Rule Libya 1982 1985 - Oct 1 0:00 0 - +Rule Libya 1985 only - Apr 6 0:00 1:00 S +Rule Libya 1986 only - Apr 4 0:00 1:00 S +Rule Libya 1986 only - Oct 3 0:00 0 - +Rule Libya 1987 1989 - Apr 1 0:00 1:00 S +Rule Libya 1987 1990 - Oct 1 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Tripoli 0:52:44 - LMT 1920 + 1:00 Libya CE%sT 1959 + 2:00 - EET 1982 + 1:00 Libya CE%sT 1990 May 4 +# The following entries are all from Shanks; +# the IATA SSIM data contain some obvious errors. + 2:00 - EET 1996 Sep 30 + 1:00 - CET 1997 Apr 4 + 1:00 1:00 CEST 1997 Oct 4 + 2:00 - EET + +# Madagascar +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Antananarivo 3:10:04 - LMT 1911 Jul + 3:00 - EAT 1954 Feb 27 23:00s + 3:00 1:00 EAST 1954 May 29 23:00s + 3:00 - EAT + +# Malawi +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Blantyre 2:20:00 - LMT 1903 Mar + 2:00 - CAT + +# Mali +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Bamako -0:32:00 - LMT 1912 + 0:00 - GMT 1934 Feb 26 + -1:00 - WAT 1960 Jun 20 + 0:00 - GMT +# no longer different from Bamako, but too famous to omit +Zone Africa/Timbuktu -0:12:04 - LMT 1912 + 0:00 - GMT + +# Mauritania +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Nouakchott -1:03:48 - LMT 1912 + 0:00 - GMT 1934 Feb 26 + -1:00 - WAT 1960 Nov 28 + 0:00 - GMT + +# Mauritius +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Mauritius 3:50:00 - LMT 1907 # Port Louis + 4:00 - MUT # Mauritius Time +# Agalega Is, Rodriguez +# no information; probably like Indian/Mauritius + +# Mayotte +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Mayotte 3:00:56 - LMT 1911 Jul # Mamoutzou + 3:00 - EAT + +# Morocco +# See the `europe' file for Spanish Morocco (Africa/Ceuta). +# RULE NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Morocco 1939 only - Sep 12 0:00 1:00 S +Rule Morocco 1939 only - Nov 19 0:00 0 - +Rule Morocco 1940 only - Feb 25 0:00 1:00 S +Rule Morocco 1945 only - Nov 18 0:00 0 - +Rule Morocco 1950 only - Jun 11 0:00 1:00 S +Rule Morocco 1950 only - Oct 29 0:00 0 - +Rule Morocco 1967 only - Jun 3 12:00 1:00 S +Rule Morocco 1967 only - Oct 1 0:00 0 - +Rule Morocco 1974 only - Jun 24 0:00 1:00 S +Rule Morocco 1974 only - Sep 1 0:00 0 - +Rule Morocco 1976 1977 - May 1 0:00 1:00 S +Rule Morocco 1976 only - Aug 1 0:00 0 - +Rule Morocco 1977 only - Sep 28 0:00 0 - +Rule Morocco 1978 only - Jun 1 0:00 1:00 S +Rule Morocco 1978 only - Aug 4 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Casablanca -0:30:20 - LMT 1913 Oct 26 + 0:00 Morocco WE%sT 1984 Mar 16 + 1:00 - CET 1986 + 0:00 - WET +# Western Sahara +Zone Africa/El_Aaiun -0:52:48 - LMT 1934 Jan + -1:00 - WAT 1976 Apr 14 + 0:00 - WET + +# Mozambique +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Maputo 2:10:20 - LMT 1903 Mar + 2:00 - CAT + +# Namibia +# The 1994-04-03 transition is from Shanks. +# Shanks reports no DST after 1998-04; go with IATA. +# RULE NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Namibia 1994 max - Sep Sun>=1 2:00 1:00 S +Rule Namibia 1995 max - Apr Sun>=1 2:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Windhoek 1:08:24 - LMT 1892 Feb 8 + 1:30 - SWAT 1903 Mar # SW Africa Time + 2:00 - SAST 1942 Sep 20 2:00 + 2:00 1:00 SAST 1943 Mar 21 2:00 + 2:00 - SAST 1990 Mar 21 # independence + 2:00 - CAT 1994 Apr 3 + 1:00 Namibia WA%sT + +# Niger +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Niamey 0:08:28 - LMT 1912 + -1:00 - WAT 1934 Feb 26 + 0:00 - GMT 1960 + 1:00 - WAT + +# Nigeria +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Lagos 0:13:36 - LMT 1919 Sep + 1:00 - WAT + +# Reunion +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Reunion 3:41:52 - LMT 1911 Jun # Saint-Denis + 4:00 - RET # Reunion Time +# +# Scattered Islands (Iles Eparses) administered from Reunion are as follows. +# The following information about them is taken from +# Iles Eparses (www.outre-mer.gouv.fr/domtom/ile.htm, 1997-07-22, in French; +# no longer available as of 1999-08-17). +# We have no info about their time zone histories. +# +# Bassas da India - uninhabited +# Europa Island - inhabited from 1905 to 1910 by two families +# Glorioso Is - inhabited until at least 1958 +# Juan de Nova - uninhabited +# Tromelin - inhabited until at least 1958 + +# Rwanda +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Kigali 2:00:16 - LMT 1935 Jun + 2:00 - CAT + +# St Helena +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/St_Helena -0:22:48 - LMT 1890 # Jamestown + -0:22:48 - JMT 1951 # Jamestown Mean Time + 0:00 - GMT +# The other parts of the St Helena territory are similar: +# Tristan da Cunha: on GMT, say Whitman and the CIA +# Ascension: on GMT, says usno1995 and the CIA +# Gough (scientific station since 1955; sealers wintered previously): +# on GMT, says the CIA +# Inaccessible, Nightingale: no information, but probably GMT + +# Sao Tome and Principe +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Sao_Tome 0:26:56 - LMT 1884 + -0:36:32 - LMT 1912 # Lisbon Mean Time + 0:00 - GMT + +# Senegal +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Dakar -1:09:44 - LMT 1912 + -1:00 - WAT 1941 Jun + 0:00 - GMT + +# Seychelles +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Mahe 3:41:48 - LMT 1906 Jun # Victoria + 4:00 - SCT # Seychelles Time +# From Paul Eggert (2001-05-30): +# Aldabra, Farquhar, and Desroches, originally dependencies of the +# Seychelles, were transferred to the British Indian Ocean Territory +# in 1965 and returned to Seychelles control in 1976. We don't know +# whether this affected their time zone, so omit this for now. +# Possibly the islands were uninhabited. + +# Sierra Leone +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Whitman gives Mar 31 - Aug 31 for 1931 on; go with Shanks. +Rule SL 1935 1942 - Jun 1 0:00 0:40 SLST +Rule SL 1935 1942 - Oct 1 0:00 0 WAT +Rule SL 1957 1962 - Jun 1 0:00 1:00 SLST +Rule SL 1957 1962 - Sep 1 0:00 0 GMT +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Freetown -0:53:00 - LMT 1882 + -0:53:00 - FMT 1913 Jun # Freetown Mean Time + -1:00 SL %s 1957 + 0:00 SL %s + +# Somalia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Mogadishu 3:01:28 - LMT 1893 Nov + 3:00 - EAT 1931 + 2:30 - BEAT 1957 + 3:00 - EAT + +# South Africa +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule SA 1942 1943 - Sep Sun>=15 2:00 1:00 - +Rule SA 1943 1944 - Mar Sun>=15 2:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Johannesburg 1:52:00 - LMT 1892 Feb 8 + 1:30 - SAST 1903 Mar + 2:00 SA SAST +# Marion and Prince Edward Is +# scientific station since 1947 +# no information + +# Sudan +# +# From +# Sudan News Agency (2000-01-13) +# , also reported by Michael De Beukelaer-Dossche via Steffen Thorsen: +# Clocks will be moved ahead for 60 minutes all over the Sudan as of noon +# Saturday.... This was announced Thursday by Caretaker State Minister for +# Manpower Abdul-Rahman Nur-Eddin. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Sudan 1970 only - May 1 0:00 1:00 S +Rule Sudan 1970 1985 - Oct 15 0:00 0 - +Rule Sudan 1971 only - Apr 30 0:00 1:00 S +Rule Sudan 1972 1985 - Apr lastSun 0:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Khartoum 2:10:08 - LMT 1931 + 2:00 Sudan CA%sT 2000 Jan 15 12:00 + 3:00 - EAT + +# Swaziland +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Mbabane 2:04:24 - LMT 1903 Mar + 2:00 - SAST + +# Tanzania +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Dar_es_Salaam 2:37:08 - LMT 1931 + 3:00 - EAT 1948 + 2:44:45 - BEAUT 1961 + 3:00 - EAT + +# Togo +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Lome 0:04:52 - LMT 1893 + 0:00 - GMT + +# Tunisia +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Tunisia 1939 only - Apr 15 23:00s 1:00 S +Rule Tunisia 1939 only - Nov 18 23:00s 0 - +Rule Tunisia 1940 only - Feb 25 23:00s 1:00 S +Rule Tunisia 1941 only - Oct 6 0:00 0 - +Rule Tunisia 1942 only - Mar 9 0:00 1:00 S +Rule Tunisia 1942 only - Nov 2 3:00 0 - +Rule Tunisia 1943 only - Mar 29 2:00 1:00 S +Rule Tunisia 1943 only - Apr 17 2:00 0 - +Rule Tunisia 1943 only - Apr 25 2:00 1:00 S +Rule Tunisia 1943 only - Oct 4 2:00 0 - +Rule Tunisia 1944 1945 - Apr Mon>=1 2:00 1:00 S +Rule Tunisia 1944 only - Oct 8 0:00 0 - +Rule Tunisia 1945 only - Sep 16 0:00 0 - +Rule Tunisia 1977 only - Apr 30 0:00s 1:00 S +Rule Tunisia 1977 only - Sep 24 0:00s 0 - +Rule Tunisia 1978 only - May 1 0:00s 1:00 S +Rule Tunisia 1978 only - Oct 1 0:00s 0 - +Rule Tunisia 1988 only - Jun 1 0:00s 1:00 S +Rule Tunisia 1988 1990 - Sep lastSun 0:00s 0 - +Rule Tunisia 1989 only - Mar 26 0:00s 1:00 S +Rule Tunisia 1990 only - May 1 0:00s 1:00 S +# Shanks gives 0:09 for Paris Mean Time; go with Howse's more precise 0:09:21. +# Shanks says the 1911 switch occurred on Mar 9; go with Howse's Mar 11. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Tunis 0:40:44 - LMT 1881 May 12 + 0:09:21 - PMT 1911 Mar 11 # Paris Mean Time + 1:00 Tunisia CE%sT + +# Uganda +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Kampala 2:09:40 - LMT 1928 Jul + 3:00 - EAT 1930 + 2:30 - BEAT 1948 + 2:44:45 - BEAUT 1957 + 3:00 - EAT + +# Zambia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Lusaka 1:53:08 - LMT 1903 Mar + 2:00 - CAT + +# Zimbabwe +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Africa/Harare 2:04:12 - LMT 1903 Mar + 2:00 - CAT diff --git a/src/timezone/data/antarctica b/src/timezone/data/antarctica new file mode 100644 index 0000000000..b5c12cbaee --- /dev/null +++ b/src/timezone/data/antarctica @@ -0,0 +1,318 @@ +# @(#)antarctica 7.23 + +# From Paul Eggert (1999-11-15): +# To keep things manageable, we list only locations occupied year-round; see +# +# COMNAP - Stations and Bases +# +# and +# +# Summary of the Peri-Antarctic Islands (1998-07-23) +# +# for information. +# Unless otherwise specified, we have no time zone information. +# +# Except for the French entries, +# I made up all time zone abbreviations mentioned here; corrections welcome! +# FORMAT is `zzz' and GMTOFF is 0 for locations while uninhabited. + +# These rules are stolen from the `europe' file. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule RussAQ 1981 1984 - Apr 1 0:00 1:00 S +Rule RussAQ 1981 1983 - Oct 1 0:00 0 - +Rule RussAQ 1984 1991 - Sep lastSun 2:00s 0 - +Rule RussAQ 1985 1991 - Mar lastSun 2:00s 1:00 S +Rule RussAQ 1992 only - Mar lastSat 23:00 1:00 S +Rule RussAQ 1992 only - Sep lastSat 23:00 0 - +Rule RussAQ 1993 max - Mar lastSun 2:00s 1:00 S +Rule RussAQ 1993 1995 - Sep lastSun 2:00s 0 - +Rule RussAQ 1996 max - Oct lastSun 2:00s 0 - + +# These rules are stolen from the `southamerica' file. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule ArgAQ 1964 1966 - Mar 1 0:00 0 - +Rule ArgAQ 1964 1966 - Oct 15 0:00 1:00 S +Rule ArgAQ 1967 only - Apr 1 0:00 0 - +Rule ArgAQ 1967 1968 - Oct Sun<=7 0:00 1:00 S +Rule ArgAQ 1968 1969 - Apr Sun<=7 0:00 0 - +Rule ArgAQ 1974 only - Jan 23 0:00 1:00 S +Rule ArgAQ 1974 only - May 1 0:00 0 - +Rule ArgAQ 1974 1976 - Oct Sun<=7 0:00 1:00 S +Rule ArgAQ 1975 1977 - Apr Sun<=7 0:00 0 - +Rule ChileAQ 1966 1997 - Oct Sun>=9 0:00 1:00 S +Rule ChileAQ 1967 1998 - Mar Sun>=9 0:00 0 - +Rule ChileAQ 1998 only - Sep 27 0:00 1:00 S +Rule ChileAQ 1999 only - Apr 4 0:00 0 - +Rule ChileAQ 1999 max - Oct Sun>=9 0:00 1:00 S +Rule ChileAQ 2000 max - Mar Sun>=9 0:00 0 - + + +# Argentina - year-round bases +# Belgrano II, Confin Coast, -770227-0343737, since 1972-02-05 +# Esperanza, San Martin Land, -6323-05659, since 1952-12-17 +# Jubany, Potter Peninsula, King George Island, -6414-0602320, since 1982-01 +# Marambio, Seymour I, -6414-05637, since 1969-10-29 +# Orcadas, Laurie I, -6016-04444, since 1904-02-22 +# San Martin, Debenham I, -6807-06708, since 1951-03-21 +# (except 1960-03 / 1976-03-21) + +# Australia - territories +# Heard Island, McDonald Islands (uninhabited) +# previously sealers and scientific personnel wintered +# +# Margaret Turner reports +# (1999-09-30) that they're UTC+5, with no DST; +# presumably this is when they have visitors. +# +# year-round bases +# Casey, Bailey Peninsula, -6617+11032, since 1969 +# Davis, Vestfold Hills, -6835+07759, since 1957-01-13 +# (except 1964-11 - 1969-02) +# Mawson, Holme Bay, -6736+06253, since 1954-02-13 +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/Casey 0 - zzz 1969 + 8:00 - WST # Western (Aus) Standard Time +Zone Antarctica/Davis 0 - zzz 1957 Jan 13 + 7:00 - DAVT 1964 Nov # Davis Time + 0 - zzz 1969 Feb + 7:00 - DAVT +Zone Antarctica/Mawson 0 - zzz 1954 Feb 13 + 6:00 - MAWT # Mawson Time +# References: +# +# Casey Weather (1998-02-26) +# +# +# Davis Station, Antarctica (1998-02-26) +# +# +# Mawson Station, Antarctica (1998-02-25) +# + +# Brazil - year-round base +# Ferraz, King George Island, since 1983/4 + +# Chile - year-round bases and towns +# Escudero, South Shetland Is, -621157-0585735, since 1994 +# Frei, King George Island, -6214-05848, since 1969-03-07 +# O'Higgins, Antarctic Peninsula, -6319-05704, since 1948-02 +# Prat, -6230-05941 +# Villa Las Estrellas (a town), King George Island, since 1984-04-09 +# These locations have always used Santiago time; use TZ='America/Santiago'. + +# China - year-round bases +# Great Wall, King George Island, since 1985-02-20 +# Zhongshan, Larsemann Hills, Prydz Bay, since 1989-02-26 + +# France - year-round bases +# +# From Antoine Leca (1997-01-20): +# Time data are from Nicole Pailleau at the IFRTP +# (French Institute for Polar Research and Technology). +# She confirms that French Southern Territories and Terre Adelie bases +# don't observe daylight saving time, even if Terre Adelie supplies came +# from Tasmania. +# +# French Southern Territories with year-round inhabitants +# +# Martin-de-Vivies Base, Amsterdam Island, -374105+0773155, since 1950 +# Alfred-Faure Base, Crozet Islands, -462551+0515152, since 1964 +# Port-aux-Francais, Kerguelen Islands, -492110+0701303, since 1951; +# whaling & sealing station operated 1908/1914, 1920/1929, and 1951/1956 +# +# St Paul Island - near Amsterdam, uninhabited +# fishing stations operated variously 1819/1931 +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Kerguelen 0 - zzz 1950 # Port-aux-Francais + 5:00 - TFT # ISO code TF Time +# +# year-round base in the main continent +# Dumont-d'Urville, Ile des Petrels, -6640+14001, since 1956-11 +# +# Another base at Port-Martin, 50km east, began operation in 1947. +# It was destroyed by fire on 1952-01-14. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/DumontDUrville 0 - zzz 1947 + 10:00 - PMT 1952 Jan 14 # Port-Martin Time + 0 - zzz 1956 Nov + 10:00 - DDUT # Dumont-d'Urville Time +# Reference: +# +# Support and Development of Polar Research and Technology (1997-02-03) +# + + +# Germany - year-round base +# Georg von Neumayer + +# India - year-round base +# Dakshin Gangotri + +# Japan - year-round bases +# Dome Fuji +# Syowa +# +# From Hideyuki Suzuki (1999-02-06): +# In all Japanese stations, +0300 is used as the standard time. [See] +# [reference in Japanese] +# and information from KAMO Hiroyasu . +# +# Syowa station, which is the first antarctic station of Japan, +# was established on 1957-01-29. Since Syowa station is still the main +# station of Japan, it's appropriate for the principal location. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/Syowa 0 - zzz 1957 Jan 29 + 3:00 - SYOT # Syowa Time +# See: +# +# NIPR Antarctic Research Activities (1999-08-17) +# + +# S Korea - year-round base +# King Sejong, King George Island, since 1988 + +# New Zealand - claims +# Balleny Islands (never inhabited) +# Scott Island (never inhabited) +# +# year-round base +# Scott, Ross Island, since 1957-01, is like Antarctica/McMurdo. +# +# These rules for New Zealand are stolen from the `australasia' file. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule NZAQ 1974 only - Nov 3 2:00s 1:00 D +Rule NZAQ 1975 1988 - Oct lastSun 2:00s 1:00 D +Rule NZAQ 1989 only - Oct 8 2:00s 1:00 D +Rule NZAQ 1990 max - Oct Sun>=1 2:00s 1:00 D +Rule NZAQ 1975 only - Feb 23 2:00s 0 S +Rule NZAQ 1976 1989 - Mar Sun>=1 2:00s 0 S +Rule NZAQ 1990 max - Mar Sun>=15 2:00s 0 S + +# Norway - territories +# Bouvet (never inhabited) +# +# claims +# Peter I Island (never inhabited) + +# Poland - year-round base +# Arctowski, King George Island, -620945-0582745, since 1977 + +# Russia - year-round bases +# Bellingshausen, King George Island, -621159-0585337, since 1968-02-22 +# Mirny, Davis coast, -6633+09301, since 1956-02 +# Molodezhnaya, Alasheyev Bay, year-round from 1962-02 to 1999-07-01 +# Novolazarevskaya, Queen Maud Land, -7046+01150, +# year-round from 1960/61 to 1992 + +# Vostok, since 1957-12-16, temporarily closed 1994-02/1994-11 +# +# From Craig Mundell (1994-12-15): +# Vostok, which is one of the Russian stations, is set on the same +# time as Moscow, Russia. +# +# From Lee Hotz (2001-03-08): +# I queried the folks at Columbia who spent the summer at Vostok and this is +# what they had to say about time there: +# ``in the US Camp (East Camp) we have been on New Zealand (McMurdo) +# time, which is 12 hours ahead of GMT. The Russian Station Vostok was +# 6 hours behind that (although only 2 miles away, i.e. 6 hours ahead +# of GMT). This is a time zone I think two hours east of Moscow. The +# natural time zone is in between the two: 8 hours ahead of GMT.'' +# +# From Paul Eggert (2001-05-04): +# This seems to be hopelessly confusing, so I asked Lee Hotz about it +# in person. He said that some Antartic locations set their local +# time so that noon is the warmest part of the day, and that this +# changes during the year and does not necessarily correspond to mean +# solar noon. So the Vostok time might have been whatever the clocks +# happened to be during their visit. So we still don't really know what time +# it is at Vostok. But we'll guess UTC+6. +# +Zone Antarctica/Vostok 0 - zzz 1957 Dec 16 + 6:00 - VOST # Vostok time + +# S Africa - year-round bases +# Marion Island +# Sanae + +# UK +# +# British Antarctic Territories (BAT) claims +# South Orkney Islands +# scientific station from 1903 +# whaling station at Signy I 1920/1926 +# South Shetland Islands +# +# year-round bases +# Bird Island, South Georgia, -5400-03803, since 1983 +# Deception Island, -6259-06034, whaling station 1912/1931, +# scientific station 1943/1967, +# previously sealers and a scientific expedition wintered by accident, +# and a garrison was deployed briefly +# Halley, Coates Land, -7535-02604, since 1956-01-06 +# Halley is on a moving ice shelf and is periodically relocated +# so that it is never more than 10km from its nominal location. +# Rothera, Adelaide Island, -6734-6808, since 1976-12-01 +# +# From Paul Eggert (2002-10-22) +# says Rothera is -03 all year. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/Rothera 0 - zzz 1976 Dec 1 + -3:00 - ROTT # Rothera time + +# Uruguay - year round base +# Artigas, King George Island, -621104-0585107 + +# USA - year-round bases +# +# Palmer, Anvers Island, since 1965 (moved 2 miles in 1968) +# +# From Ethan Dicks (1996-10-06): +# It keeps the same time as Punta Arenas, Chile, because, just like us +# and the South Pole, that's the other end of their supply line.... +# I verified with someone who was there that since 1980, +# Palmer has followed Chile. Prior to that, before the Falklands War, +# Palmer used to be supplied from Argentina. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/Palmer 0 - zzz 1965 + -4:00 ArgAQ AR%sT 1969 Oct 5 + -3:00 ArgAQ AR%sT 1982 May + -4:00 ChileAQ CL%sT +# +# +# McMurdo, Ross Island, since 1955-12 +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Antarctica/McMurdo 0 - zzz 1956 + 12:00 NZAQ NZ%sT +# +# Amundsen-Scott, South Pole, continuously occupied since 1956-11-20 +# +# From Paul Eggert (1996-09-03): +# Normally it wouldn't have a separate entry, since it's like the +# larger Antarctica/McMurdo since 1970, but it's too famous to omit. +# +# From Chris Carrier <72157.3334@CompuServe.COM> (1996-06-27): +# Siple, the first commander of the South Pole station, +# stated that he would have liked to have kept GMT at the station, +# but that he found it more convenient to keep GMT+12 +# as supplies for the station were coming from McMurdo Sound, +# which was on GMT+12 because New Zealand was on GMT+12 all year +# at that time (1957). (Source: Siple's book 90 degrees SOUTH.) +# +# From Susan Smith +# http://www.cybertours.com/whs/pole10.html +# (1995-11-13 16:24:56 +1300, no longer available): +# We use the same time as McMurdo does. +# And they use the same time as Christchurch, NZ does.... +# One last quirk about South Pole time. +# All the electric clocks are usually wrong. +# Something about the generators running at 60.1hertz or something +# makes all of the clocks run fast. So every couple of days, +# we have to go around and set them back 5 minutes or so. +# Maybe if we let them run fast all of the time, we'd get to leave here sooner!! +# +Link Antarctica/McMurdo Antarctica/South_Pole diff --git a/src/timezone/data/asia b/src/timezone/data/asia new file mode 100644 index 0000000000..f501ff91e6 --- /dev/null +++ b/src/timezone/data/asia @@ -0,0 +1,1458 @@ +# @(#)asia 7.73 + +# This data is by no means authoritative; if you think you know better, +# go ahead and edit the file (and please send any changes to +# tz@elsie.nci.nih.gov for general use in the future). + +# From Paul Eggert (1999-03-22): +# +# A good source for time zone historical data outside the U.S. is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1990, +# and IATA SSIM is the source for entries after 1990. +# +# Another source occasionally used is Edward W. Whitman, World Time Differences, +# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which +# I found in the UCLA library. +# +# A reliable and entertaining source about time zones is +# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997). +# +# I invented the abbreviations marked `*' in the following table; +# the rest are from earlier versions of this file, or from other sources. +# Corrections are welcome! +# std dst +# LMT Local Mean Time +# 2:00 EET EEST Eastern European Time +# 2:00 IST IDT Israel +# 3:00 AST ADT Arabia* +# 3:30 IRST IRDT Iran +# 4:00 GST Gulf* +# 5:30 IST India +# 7:00 ICT Indochina* +# 7:00 WIT west Indonesia +# 8:00 CIT central Indonesia +# 8:00 CST China +# 9:00 CJT Central Japanese Time (1896/1937)* +# 9:00 EIT east Indonesia +# 9:00 JST Japan +# 9:00 KST Korea +# 9:30 CST (Australian) Central Standard Time +# +# See the `europe' file for Russia and Turkey in Asia. + +# From Guy Harris: +# Incorporates data for Singapore from Robert Elz' asia 1.1, as well as +# additional information from Tom Yap, Sun Microsystems Intercontinental +# Technical Support (including a page from the Official Airline Guide - +# Worldwide Edition). The names for time zones are guesses. + +############################################################################### + +# These rules are stolen from the `europe' file. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule EUAsia 1981 max - Mar lastSun 1:00u 1:00 S +Rule EUAsia 1996 max - Oct lastSun 1:00u 0 - +Rule E-EurAsia 1981 max - Mar lastSun 0:00 1:00 S +Rule E-EurAsia 1979 1995 - Sep lastSun 0:00 0 - +Rule E-EurAsia 1996 max - Oct lastSun 0:00 0 - +Rule RussiaAsia 1981 1984 - Apr 1 0:00 1:00 S +Rule RussiaAsia 1981 1983 - Oct 1 0:00 0 - +Rule RussiaAsia 1984 1991 - Sep lastSun 2:00s 0 - +Rule RussiaAsia 1985 1991 - Mar lastSun 2:00s 1:00 S +Rule RussiaAsia 1992 only - Mar lastSat 23:00 1:00 S +Rule RussiaAsia 1992 only - Sep lastSat 23:00 0 - +Rule RussiaAsia 1993 max - Mar lastSun 2:00s 1:00 S +Rule RussiaAsia 1993 1995 - Sep lastSun 2:00s 0 - +Rule RussiaAsia 1996 max - Oct lastSun 2:00s 0 - + +# Afghanistan +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Kabul 4:36:48 - LMT 1890 + 4:00 - AFT 1945 + 4:30 - AFT + +# Armenia +# From Paul Eggert (1999-10-29): +# Shanks has Yerevan switching to 3:00 (with Russian DST) in spring 1991, +# then to 4:00 with no DST in fall 1995, then readopting Russian DST in 1997. +# Go with Shanks, even when he disagrees with others. Edgar Der-Danieliantz +# reported (1996-05-04) that Yerevan probably wouldn't use DST +# in 1996, though it did use DST in 1995. IATA SSIM (1991/1998) reports that +# Armenia switched from 3:00 to 4:00 in 1998 and observed DST after 1991, +# but started switching at 3:00s in 1998. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Yerevan 2:58:00 - LMT 1924 May 2 + 3:00 - YERT 1957 Mar # Yerevan Time + 4:00 RussiaAsia YER%sT 1991 Mar 31 2:00s + 3:00 1:00 YERST 1991 Sep 23 # independence + 3:00 RussiaAsia AM%sT 1995 Sep 24 2:00s + 4:00 - AMT 1997 + 4:00 RussiaAsia AM%sT + +# Azerbaijan +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Azer 1997 max - Mar lastSun 1:00 1:00 S +Rule Azer 1997 max - Oct lastSun 1:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Baku 3:19:24 - LMT 1924 May 2 + 3:00 - BAKT 1957 Mar # Baku Time + 4:00 RussiaAsia BAK%sT 1991 Mar 31 2:00s + 3:00 1:00 BAKST 1991 Aug 30 # independence + 3:00 RussiaAsia AZ%sT 1992 Sep lastSun 2:00s + 4:00 - AZT 1996 # Azerbaijan time + 4:00 EUAsia AZ%sT 1997 + 4:00 Azer AZ%sT + +# Bahrain +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Bahrain 3:22:20 - LMT 1920 # Al Manamah + 4:00 - GST 1972 Jun + 3:00 - AST + +# Bangladesh +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Dhaka 6:01:40 - LMT 1890 + 5:53:20 - HMT 1941 Oct # Howrah Mean Time? + 6:30 - BURT 1942 May 15 # Burma Time + 5:30 - IST 1942 Sep + 6:30 - BURT 1951 Sep 30 + 6:00 - DACT 1971 Mar 26 # Dacca Time + 6:00 - BDT # Bangladesh Time + +# Bhutan +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Thimphu 5:58:36 - LMT 1947 Aug 15 # or Thimbu + 5:30 - IST 1987 Oct + 6:00 - BTT # Bhutan Time + +# British Indian Ocean Territory +# Whitman and the 1995 CIA time zone map say 5:00, but the +# 1997 and later maps say 6:00. Assume the switch occurred in 1996. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Chagos 5:00 - IOT 1996 # BIOT Time + 6:00 - IOT + +# Brunei +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Brunei 7:39:40 - LMT 1926 Mar # Bandar Seri Begawan + 7:30 - BNT 1933 + 8:00 - BNT + +# Burma / Myanmar +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Rangoon 6:24:40 - LMT 1880 # or Yangon + 6:24:36 - RMT 1920 # Rangoon Mean Time? + 6:30 - BURT 1942 May # Burma Time + 9:00 - JST 1945 May 3 + 6:30 - MMT # Myanmar Time + +# Cambodia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Phnom_Penh 6:59:40 - LMT 1906 Jun 9 + 7:06:20 - SMT 1911 Mar 11 0:01 # Saigon MT? + 7:00 - ICT 1912 May + 8:00 - ICT 1931 May + 7:00 - ICT + +# China + +# From Guy Harris: +# People's Republic of China. Yes, they really have only one time zone. + +# From Bob Devine (1988-01-28): +# No they don't. See TIME mag, 1986-02-17 p.52. Even though +# China is across 4 physical time zones, before Feb 1, 1986 only the +# Peking (Bejing) time zone was recognized. Since that date, China +# has two of 'em -- Peking's and Urumqi (named after the capital of +# the Xinjiang Uyghur Autonomous Region). I don't know about DST for it. +# +# . . .I just deleted the DST table and this editor makes it too +# painful to suck in another copy.. So, here is what I have for +# DST start/end dates for Peking's time zone (info from AP): +# +# 1986 May 4 - Sept 14 +# 1987 mid-April - ?? + +# From U. S. Naval Observatory (1989-01-19): +# CHINA 8 H AHEAD OF UTC ALL OF CHINA, INCL TAIWAN +# CHINA 9 H AHEAD OF UTC APR 17 - SEP 10 + +# From Paul Eggert (1995-12-19): +# Shanks writes that China has had a single time zone since 1980 May 1, +# observing summer DST from 1986 through 1991; this contradicts Devine's +# note about Time magazine, though apparently _something_ happened in 1986. +# Go with Shanks for now. I made up names for the other pre-1980 time zones. + +# From Shanks: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Shang 1940 only - Jun 3 0:00 1:00 D +Rule Shang 1940 1941 - Oct 1 0:00 0 S +Rule Shang 1941 only - Mar 16 0:00 1:00 D +Rule PRC 1949 only - Jan 1 0:00 0 S +Rule PRC 1986 only - May 4 0:00 1:00 D +Rule PRC 1986 1991 - Sep Sun>=11 0:00 0 S +Rule PRC 1987 1991 - Apr Sun>=10 0:00 1:00 D +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# +# From Anthony Fok (2001-12-20): +# BTW, I did some research on-line and found some info regarding these five +# historic timezones from some Taiwan websites. And yes, there are official +# Chinese names for these locales (before 1949): +# Changbai Time ("Long-white Time", Long-white = Heilongjiang area) +Zone Asia/Harbin 8:26:44 - LMT 1928 # or Haerbin + 8:30 - CHAT 1932 Mar # Changbai Time + 8:00 - CST 1940 + 9:00 - CHAT 1966 May + 8:30 - CHAT 1980 May + 8:00 PRC C%sT +# Zhongyuan Time ("Central plain Time") +Zone Asia/Shanghai 8:05:52 - LMT 1928 + 8:00 Shang C%sT 1949 + 8:00 PRC C%sT +# Long-shu Time (probably due to Long and Shu being two names of that area) +Zone Asia/Chongqing 7:06:20 - LMT 1928 # or Chungking + 7:00 - LONT 1980 May # Long-shu Time + 8:00 PRC C%sT +# Xin-zang Time ("Xinjiang-Tibet Time") +Zone Asia/Urumqi 5:50:20 - LMT 1928 # or Urumchi + 6:00 - URUT 1980 May # Urumqi Time + 8:00 PRC C%sT +# Kunlun Time +Zone Asia/Kashgar 5:03:56 - LMT 1928 # or Kashi or Kaxgar + 5:30 - KAST 1940 # Kashgar Time + 5:00 - KAST 1980 May + 8:00 PRC C%sT + +# Hong Kong (Xianggang) +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule HK 1946 only - Apr 20 3:30 1:00 S +Rule HK 1946 only - Dec 1 3:30 0 - +Rule HK 1947 only - Apr 13 3:30 1:00 S +Rule HK 1947 only - Dec 30 3:30 0 - +Rule HK 1948 only - May 2 3:30 1:00 S +Rule HK 1948 1952 - Oct lastSun 3:30 0 - +Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S +Rule HK 1953 only - Nov 1 3:30 0 - +Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S +Rule HK 1954 only - Oct 31 3:30 0 - +Rule HK 1955 1964 - Nov Sun>=1 3:30 0 - +Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S +Rule HK 1965 1977 - Oct Sun>=16 3:30 0 - +Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S +Rule HK 1979 1980 - Oct Sun>=16 3:30 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30 + 8:00 HK HK%sT + + +############################################################################### + +# Taiwan + +# Shanks writes that Taiwan observed DST during 1945, when it +# was still controlled by Japan. This is hard to believe, but we don't +# have any other information. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Taiwan 1945 1951 - May 1 0:00 1:00 D +Rule Taiwan 1945 1951 - Oct 1 0:00 0 S +Rule Taiwan 1952 only - Mar 1 0:00 1:00 D +Rule Taiwan 1952 1954 - Nov 1 0:00 0 S +Rule Taiwan 1953 1959 - Apr 1 0:00 1:00 D +Rule Taiwan 1955 1961 - Oct 1 0:00 0 S +Rule Taiwan 1960 1961 - Jun 1 0:00 1:00 D +Rule Taiwan 1974 1975 - Apr 1 0:00 1:00 D +Rule Taiwan 1974 1975 - Oct 1 0:00 0 S +Rule Taiwan 1980 only - Jun 30 0:00 1:00 D +Rule Taiwan 1980 only - Sep 30 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Taipei 8:06:00 - LMT 1896 # or Taibei or T'ai-pei + 8:00 Taiwan C%sT + +# Macau (Macao, Aomen) +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Macau 1961 1962 - Mar Sun>=16 3:30 1:00 S +Rule Macau 1961 1964 - Nov Sun>=1 3:30 0 - +Rule Macau 1963 only - Mar Sun>=16 0:00 1:00 S +Rule Macau 1964 only - Mar Sun>=16 3:30 1:00 S +Rule Macau 1965 only - Mar Sun>=16 0:00 1:00 S +Rule Macau 1965 only - Oct 31 0:00 0 - +Rule Macau 1966 1971 - Apr Sun>=16 3:30 1:00 S +Rule Macau 1966 1971 - Oct Sun>=16 3:30 0 - +Rule Macau 1972 1974 - Apr Sun>=15 0:00 1:00 S +Rule Macau 1972 1973 - Oct Sun>=15 0:00 0 - +Rule Macau 1974 1977 - Oct Sun>=15 3:30 0 - +Rule Macau 1975 1977 - Apr Sun>=15 3:30 1:00 S +Rule Macau 1978 1980 - Apr Sun>=15 0:00 1:00 S +Rule Macau 1978 1980 - Oct Sun>=15 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Macau 7:34:20 - LMT 1912 + 8:00 Macau MO%sT 1999 Dec 20 # return to China + 8:00 PRC C%sT + + +############################################################################### + +# Cyprus +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Cyprus 1975 only - Apr 13 0:00 1:00 S +Rule Cyprus 1975 only - Oct 12 0:00 0 - +Rule Cyprus 1976 only - May 15 0:00 1:00 S +Rule Cyprus 1976 only - Oct 11 0:00 0 - +Rule Cyprus 1977 1980 - Apr Sun>=1 0:00 1:00 S +Rule Cyprus 1977 only - Sep 25 0:00 0 - +Rule Cyprus 1978 only - Oct 2 0:00 0 - +Rule Cyprus 1979 1997 - Sep lastSun 0:00 0 - +Rule Cyprus 1981 1998 - Mar lastSun 0:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Nicosia 2:13:28 - LMT 1921 Nov 14 + 2:00 Cyprus EE%sT 1998 Sep + 2:00 EUAsia EE%sT +# IATA SSIM (1998-09) has Cyprus using EU rules for the first time. + +# Classically, Cyprus belongs to Asia; e.g. see Herodotus, Histories, I.72. +# However, for various reasons many users expect to find it under Europe. +Link Asia/Nicosia Europe/Nicosia + +# Georgia +# From Paul Eggert (1994-11-19): +# Today's _Economist_ (p 60) reports that Georgia moved its clocks forward +# an hour recently, due to a law proposed by Zurab Murvanidze, +# an MP who went on a hunger strike for 11 days to force discussion about it! +# We have no details, but we'll guess they didn't move the clocks back in fall. +# +# From Mathew Englander , quoting AP (1996-10-23 13:05-04): +# Instead of putting back clocks at the end of October, Georgia +# will stay on daylight savings time this winter to save energy, +# President Eduard Shevardnadze decreed Wednesday. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Tbilisi 2:59:16 - LMT 1880 + 2:59:16 - TBMT 1924 May 2 # Tbilisi Mean Time + 3:00 - TBIT 1957 Mar # Tbilisi Time + 4:00 RussiaAsia TBI%sT 1991 Mar 31 2:00s + 3:00 1:00 TBIST 1991 Apr 9 # independence + 3:00 RussiaAsia GE%sT 1992 # Georgia Time + 3:00 E-EurAsia GE%sT 1994 Sep lastSun + 4:00 E-EurAsia GE%sT 1996 Oct lastSun + 4:00 1:00 GEST 1997 Mar lastSun + 4:00 E-EurAsia GE%sT + +# East Timor + +# From Joao Carrascalao, brother of the former governor of East Timor, in +# +# East Timor may be late for its millennium +# (1999-12-26/31): +# Portugal tried to change the time forward in 1974 because the sun +# rises too early but the suggestion raised a lot of problems with the +# Timorese and I still don't think it would work today because it +# conflicts with their way of life. + +# From Paul Eggert (2000-12-04): +# We don't have any record of the above attempt. +# Most likely our records are incomplete, but we have no better data. + +# +# From Manoel de Almeida e Silva, Deputy Spokesman for the UN Secretary-General +# (2000-08-16): +# The Cabinet of the East Timor Transition Administration decided +# today to advance East Timor's time by one hour. The time change, +# which will be permanent, with no seasonal adjustment, will happen at +# midnight on Saturday, September 16. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Dili 8:22:20 - LMT 1912 + 8:00 - TPT 1942 Feb 21 23:00 # E Timor Time + 9:00 - JST 1945 Aug + 9:00 - TPT 1976 May 3 + 8:00 - CIT 2000 Sep 17 00:00 + 9:00 - TPT + +# India +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Calcutta 5:53:28 - LMT 1880 + 5:53:20 - HMT 1941 Oct # Howrah Mean Time? + 6:30 - BURT 1942 May 15 # Burma Time + 5:30 - IST 1942 Sep + 5:30 1:00 IST 1945 Oct 15 + 5:30 - IST +# The following are like Asia/Calcutta: +# Andaman Is +# Lakshadweep (Laccadive, Minicoy and Amindivi Is) +# Nicobar Is + +# Indonesia +# +# From Gwillim Law (2001-05-28), overriding Shanks: +# +# says that Indonesia's time zones changed on 1988-01-01. Looking at some +# time zone maps, I think that must refer to Western Borneo (Kalimantan Barat +# and Kalimantan Tengah) switching from UTC+8 to UTC+7. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Jakarta 7:07:12 - LMT 1867 Aug 10 +# Shanks says the next transition was at 1924 Jan 1 0:13, +# but this must be a typo. + 7:07:12 - JMT 1923 Dec 31 23:47:12 # Jakarta + 7:20 - JAVT 1932 Nov # Java Time + 7:30 - WIT 1942 Mar 23 + 9:00 - JST 1945 Aug + 7:30 - WIT 1948 May + 8:00 - WIT 1950 May + 7:30 - WIT 1964 + 7:00 - WIT +Zone Asia/Pontianak 7:17:20 - LMT 1908 May + 7:17:20 - PMT 1932 Nov # Pontianak MT + 7:30 - WIT 1942 Jan 29 + 9:00 - JST 1945 Aug + 7:30 - WIT 1948 May + 8:00 - WIT 1950 May + 7:30 - WIT 1964 + 8:00 - CIT 1988 Jan 1 + 7:00 - WIT +Zone Asia/Makassar 7:57:36 - LMT 1920 + 7:57:36 - MMT 1932 Nov # Macassar MT + 8:00 - CIT 1942 Feb 9 + 9:00 - JST 1945 Aug + 8:00 - CIT +Zone Asia/Jayapura 9:22:48 - LMT 1932 Nov + 9:00 - EIT 1944 + 9:30 - CST 1964 + 9:00 - EIT + +# Iran + +# From Roozbeh Pournader (2003-03-15): +# This is an English translation of what I just found (originally in Persian). +# The Gregorian dates in brackets are mine: +# +# Official Newspaper No. 13548-1370/6/25 [1991-09-16] +# No. 16760/T233 H 1370/6/10 [1991-09-01] +# +# The Rule About Change of the Official Time of the Country +# +# The Board of Ministers, in the meeting dated 1370/5/23 [1991-08-14], +# based on the suggestion number 2221/D dated 1370/4/22 [1991-07-13] +# of the Country's Organization for Official and Employment Affairs, +# and referring to the law for equating the working hours of workers +# and officers in the whole country dated 1359/4/23 [1980-07-14], and +# for synchronizing the official times of the country, agreed that: +# +# The official time of the country will should move forward one hour +# at the 24[:00] hours of the first day of Farvardin and should return +# to its previous state at the 24[:00] hours of the 30th day of +# Shahrivar. +# +# First Deputy to the President - Hassan Habibi +# +# From personal experience, that agrees with what has been followed +# for at least the last 5 years. Before that, for a few years, the +# date used was the first Thursday night of Farvardin and the last +# Thursday night of Shahrivar, but I can't give exact dates.... +# I have also changed the abbreviations to what is considered correct +# here in Iran, IRST for regular time and IRDT for daylight saving time. + +# From Paul Eggert (2003-03-15) +# Go with Shanks before September 1991, and with Pournader thereafter. +# I used Ed Reingold's cal-persia in GNU Emacs 21.2 to check Persian dates. +# The Persian calendar is based on the sun, and dates after around 2050 +# are approximate; stop after 2037 when 32-bit time_t's overflow. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Iran 1978 1980 - Mar 21 0:00 1:00 D +Rule Iran 1978 only - Oct 21 0:00 0 S +Rule Iran 1979 only - Sep 19 0:00 0 S +Rule Iran 1980 only - Sep 23 0:00 0 S +Rule Iran 1991 only - May 3 0:00 1:00 D +Rule Iran 1992 1995 - Mar 22 0:00 1:00 D +Rule Iran 1991 1995 - Sep 22 0:00 0 S +Rule Iran 1996 only - Mar 21 0:00 1:00 D +Rule Iran 1996 only - Sep 21 0:00 0 S +Rule Iran 1997 1999 - Mar 22 0:00 1:00 D +Rule Iran 1997 1999 - Sep 22 0:00 0 S +Rule Iran 2000 only - Mar 21 0:00 1:00 D +Rule Iran 2000 only - Sep 21 0:00 0 S +Rule Iran 2001 2003 - Mar 22 0:00 1:00 D +Rule Iran 2001 2003 - Sep 22 0:00 0 S +Rule Iran 2004 only - Mar 21 0:00 1:00 D +Rule Iran 2004 only - Sep 21 0:00 0 S +Rule Iran 2005 2007 - Mar 22 0:00 1:00 D +Rule Iran 2005 2007 - Sep 22 0:00 0 S +Rule Iran 2008 only - Mar 21 0:00 1:00 D +Rule Iran 2008 only - Sep 21 0:00 0 S +Rule Iran 2009 2011 - Mar 22 0:00 1:00 D +Rule Iran 2009 2011 - Sep 22 0:00 0 S +Rule Iran 2012 only - Mar 21 0:00 1:00 D +Rule Iran 2012 only - Sep 21 0:00 0 S +Rule Iran 2013 2015 - Mar 22 0:00 1:00 D +Rule Iran 2013 2015 - Sep 22 0:00 0 S +Rule Iran 2016 only - Mar 21 0:00 1:00 D +Rule Iran 2016 only - Sep 21 0:00 0 S +Rule Iran 2017 2019 - Mar 22 0:00 1:00 D +Rule Iran 2017 2019 - Sep 22 0:00 0 S +Rule Iran 2020 only - Mar 21 0:00 1:00 D +Rule Iran 2020 only - Sep 21 0:00 0 S +Rule Iran 2021 2023 - Mar 22 0:00 1:00 D +Rule Iran 2021 2023 - Sep 22 0:00 0 S +Rule Iran 2024 2025 - Mar 21 0:00 1:00 D +Rule Iran 2024 2025 - Sep 21 0:00 0 S +Rule Iran 2026 2027 - Mar 22 0:00 1:00 D +Rule Iran 2026 2027 - Sep 22 0:00 0 S +Rule Iran 2028 2029 - Mar 21 0:00 1:00 D +Rule Iran 2028 2029 - Sep 21 0:00 0 S +Rule Iran 2030 2031 - Mar 22 0:00 1:00 D +Rule Iran 2030 2031 - Sep 22 0:00 0 S +Rule Iran 2032 2033 - Mar 21 0:00 1:00 D +Rule Iran 2032 2033 - Sep 21 0:00 0 S +Rule Iran 2034 2035 - Mar 22 0:00 1:00 D +Rule Iran 2034 2035 - Sep 22 0:00 0 S +Rule Iran 2036 2037 - Mar 21 0:00 1:00 D +Rule Iran 2036 2037 - Sep 21 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Tehran 3:25:44 - LMT 1916 + 3:25:44 - TMT 1946 # Tehran Mean Time + 3:30 - IRST 1977 Nov + 4:00 Iran IR%sT 1979 + 3:30 Iran IR%sT + + +# Iraq +# +# From Jonathan Lennox (2000-06-12): +# An article in this week's Economist ("Inside the Saddam-free zone", p. 50 in +# the U.S. edition) on the Iraqi Kurds contains a paragraph: +# "The three northern provinces ... switched their clocks this spring and +# are an hour ahead of Baghdad." +# +# But Rives McDow (2000-06-18) quotes a contact in Iraqi-Kurdistan as follows: +# In the past, some Kurdish nationalists, as a protest to the Iraqi +# Government, did not adhere to daylight saving time. They referred +# to daylight saving as Saddam time. But, as of today, the time zone +# in Iraqi-Kurdistan is on standard time with Baghdad, Iraq. +# +# So we'll ignore the Economist's claim. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Iraq 1982 only - May 1 0:00 1:00 D +Rule Iraq 1982 1984 - Oct 1 0:00 0 S +Rule Iraq 1983 only - Mar 31 0:00 1:00 D +Rule Iraq 1984 1985 - Apr 1 0:00 1:00 D +Rule Iraq 1985 1990 - Sep lastSun 1:00s 0 S +Rule Iraq 1986 1990 - Mar lastSun 1:00s 1:00 D +# IATA SSIM (1991/1996) says Apr 1 12:01am UTC; guess the `:01' is a typo. +# Shanks says Iraq did not observe DST 1992/1997 or 1999 on; ignore this. +Rule Iraq 1991 max - Apr 1 3:00s 1:00 D +Rule Iraq 1991 max - Oct 1 3:00s 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Baghdad 2:57:40 - LMT 1890 + 2:57:36 - BMT 1918 # Baghdad Mean Time? + 3:00 - AST 1982 May + 3:00 Iraq A%sT + + +############################################################################### + +# Israel + +# From Ephraim Silverberg (2001-01-11): +# +# I coined "IST/IDT" circa 1988. Until then there were three +# different abbreviations in use: +# +# JST Jerusalem Standard Time [Danny Braniss, Hebrew University] +# IZT Israel Zonal (sic) Time [Prof. Haim Papo, Technion] +# EEST Eastern Europe Standard Time [used by almost everyone else] +# +# Since timezones should be called by country and not capital cities, +# I ruled out JST. As Israel is in Asia Minor and not Eastern Europe, +# EEST was equally unacceptable. Since "zonal" was not compatible with +# any other timezone abbreviation, I felt that 'IST' was the way to go +# and, indeed, it has received almost universal acceptance in timezone +# settings in Israeli computers. +# +# In any case, I am happy to share timezone abbreviations with India, +# high on my favorite-country list (and not only because my wife's +# family is from India). + +# From Shanks: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 1940 only - Jun 1 0:00 1:00 D +Rule Zion 1942 1944 - Nov 1 0:00 0 S +Rule Zion 1943 only - Apr 1 2:00 1:00 D +Rule Zion 1944 only - Apr 1 0:00 1:00 D +Rule Zion 1945 only - Apr 16 0:00 1:00 D +Rule Zion 1945 only - Nov 1 2:00 0 S +Rule Zion 1946 only - Apr 16 2:00 1:00 D +Rule Zion 1946 only - Nov 1 0:00 0 S +Rule Zion 1948 only - May 23 0:00 2:00 DD +Rule Zion 1948 only - Sep 1 0:00 1:00 D +Rule Zion 1948 1949 - Nov 1 2:00 0 S +Rule Zion 1949 only - May 1 0:00 1:00 D +Rule Zion 1950 only - Apr 16 0:00 1:00 D +Rule Zion 1950 only - Sep 15 3:00 0 S +Rule Zion 1951 only - Apr 1 0:00 1:00 D +Rule Zion 1951 only - Nov 11 3:00 0 S +Rule Zion 1952 only - Apr 20 2:00 1:00 D +Rule Zion 1952 only - Oct 19 3:00 0 S +Rule Zion 1953 only - Apr 12 2:00 1:00 D +Rule Zion 1953 only - Sep 13 3:00 0 S +Rule Zion 1954 only - Jun 13 0:00 1:00 D +Rule Zion 1954 only - Sep 12 0:00 0 S +Rule Zion 1955 only - Jun 11 2:00 1:00 D +Rule Zion 1955 only - Sep 11 0:00 0 S +Rule Zion 1956 only - Jun 3 0:00 1:00 D +Rule Zion 1956 only - Sep 30 3:00 0 S +Rule Zion 1957 only - Apr 29 2:00 1:00 D +Rule Zion 1957 only - Sep 22 0:00 0 S +Rule Zion 1974 only - Jul 7 0:00 1:00 D +Rule Zion 1974 only - Oct 13 0:00 0 S +Rule Zion 1975 only - Apr 20 0:00 1:00 D +Rule Zion 1975 only - Aug 31 0:00 0 S +Rule Zion 1985 only - Apr 14 0:00 1:00 D +Rule Zion 1985 only - Sep 15 0:00 0 S +Rule Zion 1986 only - May 18 0:00 1:00 D +Rule Zion 1986 only - Sep 7 0:00 0 S +Rule Zion 1987 only - Apr 15 0:00 1:00 D +Rule Zion 1987 only - Sep 13 0:00 0 S +Rule Zion 1988 only - Apr 9 0:00 1:00 D +Rule Zion 1988 only - Sep 3 0:00 0 S + +# From Ephraim Silverberg +# (1997-03-04, 1998-03-16, 1998-12-28, 2000-01-17 and 2000-07-25): + +# According to the Office of the Secretary General of the Ministry of +# Interior, there is NO set rule for Daylight-Savings/Standard time changes. +# One thing is entrenched in law, however: that there must be at least 150 +# days of daylight savings time annually. From 1993-1998, the change to +# daylight savings time was on a Friday morning from midnight IST to +# 1 a.m IDT; up until 1998, the change back to standard time was on a +# Saturday night from midnight daylight savings time to 11 p.m. standard +# time. 1996 is an exception to this rule where the change back to standard +# time took place on Sunday night instead of Saturday night to avoid +# conflicts with the Jewish New Year. In 1999, the change to +# daylight savings time was still on a Friday morning but from +# 2 a.m. IST to 3 a.m. IDT; furthermore, the change back to standard time +# was also on a Friday morning from 2 a.m. IDT to 1 a.m. IST for +# 1999 only. In the year 2000, the change to daylight savings time was +# similar to 1999, but although the change back will be on a Friday, it +# will take place from 1 a.m. IDT to midnight IST. Starting in 2001, all +# changes to/from will take place at 1 a.m. old time, but now there is no +# rule as to what day of the week it will take place in as the start date +# (except in 2003) is the night after the Passover Seder (i.e. the eve +# of the 16th of Nisan in the lunar Hebrew calendar) and the end date +# (except in 2002) is three nights before Yom Kippur [Day of Atonement] +# (the eve of the 7th of Tishrei in the lunar Hebrew calendar). + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 1989 only - Apr 30 0:00 1:00 D +Rule Zion 1989 only - Sep 3 0:00 0 S +Rule Zion 1990 only - Mar 25 0:00 1:00 D +Rule Zion 1990 only - Aug 26 0:00 0 S +Rule Zion 1991 only - Mar 24 0:00 1:00 D +Rule Zion 1991 only - Sep 1 0:00 0 S +Rule Zion 1992 only - Mar 29 0:00 1:00 D +Rule Zion 1992 only - Sep 6 0:00 0 S +Rule Zion 1993 only - Apr 2 0:00 1:00 D +Rule Zion 1993 only - Sep 5 0:00 0 S + +# The dates for 1994-1995 were obtained from Office of the Spokeswoman for the +# Ministry of Interior, Jerusalem, Israel. The spokeswoman can be reached by +# calling the office directly at 972-2-6701447 or 972-2-6701448. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 1994 only - Apr 1 0:00 1:00 D +Rule Zion 1994 only - Aug 28 0:00 0 S +Rule Zion 1995 only - Mar 31 0:00 1:00 D +Rule Zion 1995 only - Sep 3 0:00 0 S + +# The dates for 1996 were determined by the Minister of Interior of the +# time, Haim Ramon. The official announcement regarding 1996-1998 +# (with the dates for 1997-1998 no longer being relevant) can be viewed at: +# +# ftp://ftp.huji.ac.il/pub/tz/announcements/1996-1998.ramon.ps.gz +# +# The dates for 1997-1998 were altered by his successor, Rabbi Eli Suissa. +# +# The official announcements for the years 1997-1999 can be viewed at: +# +# ftp://ftp.huji.ac.il/pub/tz/announcements/YYYY.ps.gz +# +# where YYYY is the relevant year. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 1996 only - Mar 15 0:00 1:00 D +Rule Zion 1996 only - Sep 16 0:00 0 S +Rule Zion 1997 only - Mar 21 0:00 1:00 D +Rule Zion 1997 only - Sep 14 0:00 0 S +Rule Zion 1998 only - Mar 20 0:00 1:00 D +Rule Zion 1998 only - Sep 6 0:00 0 S +Rule Zion 1999 only - Apr 2 2:00 1:00 D +Rule Zion 1999 only - Sep 3 2:00 0 S + +# The Knesset Interior Committee has changed the dates for 2000 for +# the third time in just over a year and have set new dates for the +# years 2001-2004 as well. +# +# The official announcement for the start date of 2000 can be viewed at: +# +# ftp://ftp.huji.ac.il/pub/tz/announcements/2000-start.ps.gz +# +# The official announcement for the end date of 2000 and the dates +# for the years 2001-2004 can be viewed at: +# +# ftp://ftp.huji.ac.il/pub/tz/announcements/2000-2004.ps.gz + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 2000 only - Apr 14 2:00 1:00 D +Rule Zion 2000 only - Oct 6 1:00 0 S +Rule Zion 2001 only - Apr 9 1:00 1:00 D +Rule Zion 2001 only - Sep 24 1:00 0 S +Rule Zion 2002 only - Mar 29 1:00 1:00 D +Rule Zion 2002 only - Oct 7 1:00 0 S +Rule Zion 2003 only - Mar 28 1:00 1:00 D +Rule Zion 2003 only - Oct 3 1:00 0 S +Rule Zion 2004 only - Apr 7 1:00 1:00 D +Rule Zion 2004 only - Sep 22 1:00 0 S + +# From Paul Eggert (2000-07-25): +# Here are guesses for rules after 2004. +# They are probably wrong, but they are more likely than no DST at all. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Zion 2005 max - Apr 1 1:00 1:00 D +Rule Zion 2005 max - Oct 1 1:00 0 S + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Jerusalem 2:20:56 - LMT 1880 + 2:20:40 - JMT 1918 # Jerusalem Mean Time? + 2:00 Zion I%sT + +# From Ephraim Silverberg (2003-03-23): +# +# Minister of Interior Poraz has announced that he will respect the law +# passed in July 2000 (proposed at the time jointly by himself and +# then-MK David Azulai [Shas]) fixing the dates for 2000-2004. Hence, +# the dates for 2003 and 2004 remain unchanged.... +# +# As far as 2005 and beyond, no dates have been set. However, the +# minister has mentioned that he wishes to propose to move Israel's +# timezone in 2005 from GMT+2 to GMT+3 and upon that have DST during +# the summer months (i.e. GMT+4). However, no legislation in this +# direction is expected until the latter part of 2004 which is a long +# time off in terms of Israeli politics. + + + +############################################################################### + +# Japan + +# `9:00' and `JST' is from Guy Harris. + +# From Paul Eggert (1995-03-06): +# Today's _Asahi Evening News_ (page 4) reports that Japan had +# daylight saving between 1948 and 1951, but ``the system was discontinued +# because the public believed it would lead to longer working hours.'' +# Shanks writes that daylight saving in Japan during those years was as follows: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +#Rule Japan 1948 only - May Sun>=1 2:00 1:00 D +#Rule Japan 1948 1951 - Sep Sat>=8 2:00 0 S +#Rule Japan 1949 only - Apr Sun>=1 2:00 1:00 D +#Rule Japan 1950 1951 - May Sun>=1 2:00 1:00 D +# but the only locations using it were US military bases. +# We go with Shanks and omit daylight saving in those years for Asia/Tokyo. + +# From Hideyuki Suzuki (1998-11-09): +# 'Tokyo' usually stands for the former location of Tokyo Astronomical +# Observatory: E 139 44' 40".90 (9h 18m 58s.727), N 35 39' 16".0. +# This data is from 'Rika Nenpyou (Chronological Scientific Tables) 1996' +# edited by National Astronomical Observatory of Japan.... +# JST (Japan Standard Time) has been used since 1888-01-01 00:00 (JST). +# The law is enacted on 1886-07-07. + +# From Hideyuki Suzuki (1998-11-16): +# The ordinance No. 51 (1886) established "standard time" in Japan, +# which stands for the time on E 135 degree. +# In the ordinance No. 167 (1895), "standard time" was renamed to "central +# standard time". And the same ordinance also established "western standard +# time", which stands for the time on E 120 degree.... But "western standard +# time" was abolished in the ordinance No. 529 (1937). In the ordinance No. +# 167, there is no mention regarding for what place western standard time is +# standard.... +# +# I wrote "ordinance" above, but I don't know how to translate. +# In Japanese it's "chokurei", which means ordinance from emperor. + +# Shanks claims JST in use since 1896, and that a few places (e.g. Ishigaki) +# use +0800; go with Suzuki. Guess that all ordinances took effect on Jan 1. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Tokyo 9:18:59 - LMT 1887 Dec 31 15:00u + 9:00 - JST 1896 + 9:00 - CJT 1938 + 9:00 - JST +# Since 1938, all Japanese possessions have been like Asia/Tokyo. + +# Jordan +# +# From +# Jordan Week (1999-07-01) via Steffen Thorsen (1999-09-09): +# Clocks in Jordan were forwarded one hour on Wednesday at midnight, +# in accordance with the government's decision to implement summer time +# all year round. +# +# From +# Jordan Week (1999-09-30) via Steffen Thorsen (1999-11-09): +# Winter time starts today Thursday, 30 September. Clocks will be turned back +# by one hour. This is the latest government decision and it's final! +# The decision was taken because of the increase in working hours in +# government's departments from six to seven hours. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Jordan 1973 only - Jun 6 0:00 1:00 S +Rule Jordan 1973 1975 - Oct 1 0:00 0 - +Rule Jordan 1974 1977 - May 1 0:00 1:00 S +Rule Jordan 1976 only - Nov 1 0:00 0 - +Rule Jordan 1977 only - Oct 1 0:00 0 - +Rule Jordan 1978 only - Apr 30 0:00 1:00 S +Rule Jordan 1978 only - Sep 30 0:00 0 - +Rule Jordan 1985 only - Apr 1 0:00 1:00 S +Rule Jordan 1985 only - Oct 1 0:00 0 - +Rule Jordan 1986 1988 - Apr Fri>=1 0:00 1:00 S +Rule Jordan 1986 1990 - Oct Fri>=1 0:00 0 - +Rule Jordan 1989 only - May 8 0:00 1:00 S +Rule Jordan 1990 only - Apr 27 0:00 1:00 S +Rule Jordan 1991 only - Apr 17 0:00 1:00 S +Rule Jordan 1991 only - Sep 27 0:00 0 - +Rule Jordan 1992 only - Apr 10 0:00 1:00 S +Rule Jordan 1992 1993 - Oct Fri>=1 0:00 0 - +Rule Jordan 1993 1998 - Apr Fri>=1 0:00 1:00 S +Rule Jordan 1994 only - Sep Fri>=15 0:00 0 - +Rule Jordan 1995 1998 - Sep Fri>=15 0:00s 0 - +Rule Jordan 1999 only - Jul 1 0:00s 1:00 S +Rule Jordan 1999 max - Sep lastThu 0:00s 0 - +Rule Jordan 2000 max - Mar lastThu 0:00s 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Amman 2:23:44 - LMT 1931 + 2:00 Jordan EE%sT + +# Kazakhstan +# From Paul Eggert (1996-11-22): +# Andrew Evtichov (1996-04-13) writes that Kazakhstan +# stayed in sync with Moscow after 1990, and that Aqtobe (formerly Aktyubinsk) +# and Aqtau (formerly Shevchenko) are the largest cities in their zones. +# Guess that Aqtau and Aqtobe diverged in 1995, since that's the first time +# IATA SSIM mentions a third time zone in Kazakhstan. +# +# From Paul Eggert (2001-10-18): +# German Iofis, ELSI, Almaty (2001-10-09) reports that Kazakhstan uses +# RussiaAsia rules, instead of switching at 00:00 as the IATA has it. +# Go with Shanks, who has them always using RussiaAsia rules. +# Also go with the following claims of Shanks: +# +# - Kazakhstan did not observe DST in 1991. +# - Qyzylorda switched from +5:00 to +6:00 on 1992-01-19 02:00. +# - Oral switched from +5:00 to +4:00 in spring 1989. +# +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# +# Almaty (formerly Alma-Ata), representing most locations in Kazakhstan +Zone Asia/Almaty 5:07:48 - LMT 1924 May 2 # or Alma-Ata + 5:00 - ALMT 1930 Jun 21 # Alma-Ata Time + 6:00 RussiaAsia ALM%sT 1991 + 6:00 - ALMT 1992 + 6:00 RussiaAsia ALM%sT +# Qyzylorda (aka Kyzylorda, Kizilorda, Kzyl-Orda, etc.) +Zone Asia/Qyzylorda 4:21:52 - LMT 1924 May 2 + 4:00 - KIZT 1930 Jun 21 # Kizilorda Time + 5:00 - KIZT 1981 Apr 1 + 5:00 1:00 KIZST 1981 Oct 1 + 6:00 - KIZT 1982 Apr 1 + 5:00 RussiaAsia KIZ%sT 1991 + 5:00 - KIZT 1991 Dec 16 # independence + 5:00 - QYZT 1992 Jan 19 2:00 + 6:00 RussiaAsia QYZ%sT +# Aqtobe (aka Aktobe, formerly Akt'ubinsk) +Zone Asia/Aqtobe 3:48:40 - LMT 1924 May 2 + 4:00 - AKTT 1930 Jun 21 # Aktyubinsk Time + 5:00 - AKTT 1981 Apr 1 + 5:00 1:00 AKTST 1981 Oct 1 + 6:00 - AKTT 1982 Apr 1 + 5:00 RussiaAsia AKT%sT 1991 + 5:00 - AKTT 1991 Dec 16 # independence + 5:00 RussiaAsia AQT%sT # Aqtobe Time +# Mangghystau +# Aqtau was not founded until 1963, but it represents an inhabited region, +# so include time stamps before 1963. +Zone Asia/Aqtau 3:21:04 - LMT 1924 May 2 + 4:00 - FORT 1930 Jun 21 # Fort Shevchenko T + 5:00 - FORT 1963 + 5:00 - SHET 1981 Oct 1 # Shevchenko Time + 6:00 - SHET 1982 Apr 1 + 5:00 RussiaAsia SHE%sT 1991 + 5:00 - SHET 1991 Dec 16 # independence + 5:00 RussiaAsia AQT%sT 1995 Mar lastSun 2:00 # Aqtau Time + 4:00 RussiaAsia AQT%sT +# West Kazakhstan +Zone Asia/Oral 3:25:24 - LMT 1924 May 2 # or Ural'sk + 4:00 - URAT 1930 Jun 21 # Ural'sk time + 5:00 - URAT 1981 Apr 1 + 5:00 1:00 URAST 1981 Oct 1 + 6:00 - URAT 1982 Apr 1 + 5:00 RussiaAsia URA%sT 1989 Mar 26 2:00 + 4:00 RussiaAsia URA%sT 1991 + 4:00 - URAT 1991 Dec 16 # independence + 4:00 RussiaAsia ORA%sT # Oral Time + +# Kyrgyzstan (Kirgizstan) +# Transitions through 1991 are from Shanks. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Kirgiz 1992 1996 - Apr Sun>=7 0:00s 1:00 S +Rule Kirgiz 1992 1996 - Sep lastSun 0:00 0 - +Rule Kirgiz 1997 max - Mar lastSun 2:30 1:00 S +Rule Kirgiz 1997 max - Oct lastSun 2:30 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Bishkek 4:58:24 - LMT 1924 May 2 + 5:00 - FRUT 1930 Jun 21 # Frunze Time + 6:00 RussiaAsia FRU%sT 1991 Mar 31 2:00s + 5:00 1:00 FRUST 1991 Aug 31 2:00 # independence + 5:00 Kirgiz KG%sT # Kirgizstan Time + +############################################################################### + +# Korea (North and South) + +# From Guy Harris: +# According to someone at the Korean Times in San Francisco, +# Daylight Savings Time was not observed until 1987. He did not know +# at what time of day DST starts or ends. + +# From Shanks: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule ROK 1960 only - May 15 0:00 1:00 D +Rule ROK 1960 only - Sep 13 0:00 0 S +Rule ROK 1987 1988 - May Sun<=14 0:00 1:00 D +Rule ROK 1987 1988 - Oct Sun<=14 0:00 0 S + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Seoul 8:27:52 - LMT 1890 + 8:30 - KST 1904 Dec + 9:00 - KST 1928 + 8:30 - KST 1932 + 9:00 - KST 1954 Mar 21 + 8:00 ROK K%sT 1961 Aug 10 + 8:30 - KST 1968 Oct + 9:00 ROK K%sT +Zone Asia/Pyongyang 8:23:00 - LMT 1890 + 8:30 - KST 1904 Dec + 9:00 - KST 1928 + 8:30 - KST 1932 + 9:00 - KST 1954 Mar 21 + 8:00 - KST 1961 Aug 10 + 9:00 - KST + +############################################################################### + +# Kuwait +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Kuwait 3:11:56 - LMT 1950 + 3:00 - AST + +# Laos +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Vientiane 6:50:24 - LMT 1906 Jun 9 # or Viangchan + 7:06:20 - SMT 1911 Mar 11 0:01 # Saigon MT? + 7:00 - ICT 1912 May + 8:00 - ICT 1931 May + 7:00 - ICT + +# Lebanon +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Lebanon 1920 only - Mar 28 0:00 1:00 S +Rule Lebanon 1920 only - Oct 25 0:00 0 - +Rule Lebanon 1921 only - Apr 3 0:00 1:00 S +Rule Lebanon 1921 only - Oct 3 0:00 0 - +Rule Lebanon 1922 only - Mar 26 0:00 1:00 S +Rule Lebanon 1922 only - Oct 8 0:00 0 - +Rule Lebanon 1923 only - Apr 22 0:00 1:00 S +Rule Lebanon 1923 only - Sep 16 0:00 0 - +Rule Lebanon 1957 1961 - May 1 0:00 1:00 S +Rule Lebanon 1957 1961 - Oct 1 0:00 0 - +Rule Lebanon 1972 only - Jun 22 0:00 1:00 S +Rule Lebanon 1972 1977 - Oct 1 0:00 0 - +Rule Lebanon 1973 1977 - May 1 0:00 1:00 S +Rule Lebanon 1978 only - Apr 30 0:00 1:00 S +Rule Lebanon 1978 only - Sep 30 0:00 0 - +Rule Lebanon 1984 1987 - May 1 0:00 1:00 S +Rule Lebanon 1984 1991 - Oct 16 0:00 0 - +Rule Lebanon 1988 only - Jun 1 0:00 1:00 S +Rule Lebanon 1989 only - May 10 0:00 1:00 S +Rule Lebanon 1990 1992 - May 1 0:00 1:00 S +Rule Lebanon 1992 only - Oct 4 0:00 0 - +Rule Lebanon 1993 max - Mar lastSun 0:00 1:00 S +Rule Lebanon 1993 1998 - Sep lastSun 0:00 0 - +Rule Lebanon 1999 max - Oct lastSun 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Beirut 2:22:00 - LMT 1880 + 2:00 Lebanon EE%sT + +# Malaysia +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule NBorneo 1935 1941 - Sep 14 0:00 0:20 TS # one-Third Summer +Rule NBorneo 1935 1941 - Dec 14 0:00 0 - +# +# peninsular Malaysia +# From Paul Eggert (2003-11-01): +# The data here are taken from Mok Ly Yng (2003-10-30) +# . +# Before 1901, Penang, Malacca and Singapore each had their own time zone; +# assume Kuala Lumpur used Malaccan time. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Kuala_Lumpur 6:46:48 - LMT 1880 + 6:49:00 - MMT 1901 Jan 1 # Malacca Mean Time + 6:55:25 - SMT 1905 Jun 1 # Singapore M.T. + 7:00 - MALT 1933 Jan 1 # Malaya Time + 7:00 0:20 MALST 1936 + 7:20 - MALT 1941 Sep 1 + 7:30 - MALT 1942 Feb 16 + 9:00 - JST 1945 Sep 12 + 7:30 - MALT 1982 Jan 1 + 8:00 - MYT # Malaysia Time +# Sabah & Sarawak +# From Paul Eggert (2003-11-01): +# The data here are mostly from Shanks, but the 1942, 1945 and 1982 +# transition dates are from Mok Ly Yng. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Kuching 7:21:20 - LMT 1926 Mar + 7:30 - BORT 1933 # Borneo Time + 8:00 NBorneo BOR%sT 1942 Feb 16 + 9:00 - JST 1945 Sep 12 + 8:00 - BORT 1982 Jan 1 + 8:00 - MYT + +# Maldives +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Maldives 4:54:00 - LMT 1880 # Male + 4:54:00 - MMT 1960 # Male Mean Time + 5:00 - MVT # Maldives Time + +# Mongolia + +# Shanks says that Mongolia has three time zones, but usno1995 and the CIA map +# Standard Time Zones of the World (1997-01) +# both say that it has just one. + +# From Oscar van Vlijmen (1999-12-11): +# +# General Information Mongolia +# (1999-09) +# "Time: Mongolia has two time zones. Three westernmost provinces of +# Bayan-Ulgii, Uvs, and Hovd are one hour earlier than the capital city, and +# the rest of the country follows the Ulaanbaatar time, which is UTC/GMT plus +# eight hours." + +# From Rives McDow (1999-12-13): +# Mongolia discontinued the use of daylight savings time in 1999; 1998 +# being the last year it was implemented. The dates of implementation I am +# unsure of, but most probably it was similar to Russia, except for the time +# of implementation may have been different.... +# Some maps in the past have indicated that there was an additional time +# zone in the eastern part of Mongolia, including the provinces of Dornod, +# Suhbaatar, and possibly Khentij. + +# From Paul Eggert (1999-12-15): +# Naming and spelling is tricky in Mongolia. +# We'll use Hovd (also spelled Chovd and Khovd) to represent the west zone; +# the capital of the Hovd province is sometimes called Hovd, sometimes Dund-Us, +# and sometimes Jirgalanta (with variant spellings), but the name Hovd +# is good enough for our purposes. + +# From Rives McDow (2001-05-13): +# In addition to Mongolia starting daylight savings as reported earlier +# (adopted DST on 2001-04-27 02:00 local time, ending 2001-09-28), +# there are three time zones. +# +# Provinces [at 7:00]: Bayan-ulgii, Uvs, Khovd, Zavkhan, Govi-Altai +# Provinces [at 8:00]: Khovsgol, Bulgan, Arkhangai, Khentii, Tov, +# Bayankhongor, Ovorkhangai, Dundgovi, Dornogovi, Omnogovi +# Provinces [at 9:00]: Dornod, Sukhbaatar +# +# [The province of Selenge is omitted from the above lists.] + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Mongol 1983 1984 - Apr 1 0:00 1:00 S +Rule Mongol 1983 only - Oct 1 0:00 0 - +# IATA SSIM says 1990s switches occurred at 00:00, but Shanks (1995) lists +# them at 02:00s, and McDow says the 2001 switches also occurred at 02:00. +# Also, IATA SSIM (1996-09) says 1996-10-25. Go with Shanks through 1998. +Rule Mongol 1985 1998 - Mar lastSun 2:00s 1:00 S +Rule Mongol 1984 1998 - Sep lastSun 2:00s 0 - +# IATA SSIM (1999-09) says Mongolia no longer observes DST. +Rule Mongol 2001 only - Apr 27 2:00s 1:00 S +Rule Mongol 2001 only - Sep 28 2:00s 0 - + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# Hovd, a.k.a. Chovd, Dund-Us, Dzhargalant, Khovd, Jirgalanta +Zone Asia/Hovd 6:06:36 - LMT 1905 Aug + 6:00 - HOVT 1978 # Hovd Time + 7:00 Mongol HOV%sT +# Ulaanbaatar, a.k.a. Ulan Bataar, Ulan Bator, Urga +Zone Asia/Ulaanbaatar 7:07:32 - LMT 1905 Aug + 7:00 - ULAT 1978 # Ulaanbaatar Time + 8:00 Mongol ULA%sT +# Choibalsan, a.k.a. Bajan Tuemen, Bajan Tumen, Chojbalsan, +# Choybalsan, Sanbejse, Tchoibalsan +Zone Asia/Choibalsan 7:38:00 - LMT 1905 Aug + 7:00 - ULAT 1978 + 8:00 - ULAT 1983 Apr + 9:00 Mongol CHO%sT # Choibalsan Time + +# Nepal +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Katmandu 5:41:16 - LMT 1920 + 5:30 - IST 1986 + 5:45 - NPT # Nepal Time + +# Oman +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Muscat 3:54:20 - LMT 1920 + 4:00 - GST + +# Pakistan + +# From Rives McDow (2002-03-13): +# I have been advised that Pakistan has decided to adopt dst on a +# TRIAL basis for one year, starting 00:01 local time on April 7, 2002 +# and ending at 00:01 local time October 6, 2002. This is what I was +# told, but I believe that the actual time of change may be 00:00; the +# 00:01 was to make it clear which day it was on. + +# From Paul Eggert (2002-03-15): +# Jesper Norgaard found this URL: +# http://www.pak.gov.pk/public/news/app/app06_dec.htm +# (dated 2001-12-06) which says that the Cabinet adopted a scheme "to +# advance the clocks by one hour on the night between the first +# Saturday and Sunday of April and revert to the original position on +# 15th October each year". This agrees with McDow's 04-07 at 00:00, +# but disagrees about the October transition, and makes it sound like +# it's not on a trial basis. Also, the "between the first Saturday +# and Sunday of April" phrase, if taken literally, means that the +# transition takes place at 00:00 on the first Sunday on or after 04-02. + +# From Paul Eggert (2003-02-09): +# DAWN reported on 2002-10-05 +# that 2002 DST ended that day at midnight. Go with McDow for now. + +# From Steffen Thorsen (2003-03-14): +# According to http://www.dawn.com/2003/03/07/top15.htm +# there will be no DST in Pakistan this year: +# +# ISLAMABAD, March 6: Information and Media Development Minister Sheikh +# Rashid Ahmed on Thursday said the cabinet had reversed a previous +# decision to advance clocks by one hour in summer and put them back by +# one hour in winter with the aim of saving light hours and energy. +# +# The minister told a news conference that the experiment had rather +# shown 8 per cent higher consumption of electricity. + + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Pakistan 2002 only - Apr Sun>=2 0:01 1:00 S +Rule Pakistan 2002 only - Oct Sun>=2 0:01 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Karachi 4:28:12 - LMT 1907 + 5:30 - IST 1942 Sep + 5:30 1:00 IST 1945 Oct 15 + 5:30 - IST 1951 Sep 30 + 5:00 - KART 1971 Mar 26 # Karachi Time + 5:00 Pakistan PK%sT # Pakistan Time + +# Palestine + +# From Amos Shapir (1998-02-15): +# +# From 1917 until 1948-05-15, all of Palestine, including the parts now +# known as the Gaza Strip and the West Bank, was under British rule. +# Therefore the rules given for Israel for that period, apply there too... +# +# The Gaza Strip was under Egyptian rule between 1948-05-15 until 1967-06-05 +# (except a short occupation by Israel from 1956-11 till 1957-03, but no +# time zone was affected then). It was never formally annexed to Egypt, +# though. +# +# The rest of Palestine was under Jordanian rule at that time, formally +# annexed in 1950 as the West Bank (and the word "Trans" was dropped from +# the country's previous name of "the Hashemite Kingdom of the +# Trans-Jordan"). So the rules for Jordan for that time apply. Major +# towns in that area are Nablus (Shchem), El-Halil (Hebron), Ramallah, and +# East Jerusalem. +# +# Both areas were occupied by Israel in June 1967, but not annexed (except +# for East Jerusalem). They were on Israel time since then; there might +# have been a Military Governor's order about time zones, but I'm not aware +# of any (such orders may have been issued semi-annually whenever summer +# time was in effect, but maybe the legal aspect of time was just neglected). +# +# The Palestinian Authority was established in 1993, and got hold of most +# towns in the West Bank and Gaza by 1995. I know that in order to +# demonstrate...independence, they have been switching to +# summer time and back on a different schedule than Israel's, but I don't +# know when this was started, or what algorithm is used (most likely the +# Jordanian one). +# +# To summarize, the table should probably look something like that: +# +# Area \ when | 1918-1947 | 1948-1967 | 1967-1995 | 1996- +# ------------+-----------+-----------+-----------+----------- +# Israel | Zion | Zion | Zion | Zion +# West bank | Zion | Jordan | Zion | Jordan +# Gaza | Zion | Egypt | Zion | Jordan +# +# I guess more info may be available from the PA's web page (if/when they +# have one). + +# From Paul Eggert (1998-02-25): +# Shanks writes that Gaza did not observe DST until 1957, but we'll go +# with Shapir and assume that it observed DST from 1940 through 1947, +# and that it used Jordanian rules starting in 1996. +# We don't yet need a separate entry for the West Bank, since +# the only differences between it and Gaza that we know about +# occurred before our cutoff date of 1970. +# However, as we get more information, we may need to add entries +# for parts of the West Bank as they transitioned from Israel's rules +# to Palestine's rules. If you have more info about this, please +# send it to tz@elsie.nci.nih.gov for incorporation into future editions. + +# From IINS News Service - Israel - 1998-03-23 10:38:07 Israel time, +# forwarded by Ephraim Silverberg: +# +# Despite the fact that Israel changed over to daylight savings time +# last week, the PLO Authority (PA) has decided not to turn its clocks +# one-hour forward at this time. As a sign of independence from Israeli rule, +# the PA has decided to implement DST in April. + +# From Paul Eggert (1999-09-20): +# Daoud Kuttab writes in +# +# Holiday havoc +# (Jerusalem Post, 1999-04-22) that +# the Palestinian National Authority changed to DST on 1999-04-15. +# I vaguely recall that they switch back in October (sorry, forgot the source). +# For now, let's assume that the spring switch was at 24:00, +# and that they switch at 0:00 on the 3rd Fridays of April and October. + +# The rules for Egypt are stolen from the `africa' file. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule EgyptAsia 1957 only - May 10 0:00 1:00 S +Rule EgyptAsia 1957 1958 - Oct 1 0:00 0 - +Rule EgyptAsia 1958 only - May 1 0:00 1:00 S +Rule EgyptAsia 1959 1967 - May 1 1:00 1:00 S +Rule EgyptAsia 1959 1965 - Sep 30 3:00 0 - +Rule EgyptAsia 1966 only - Oct 1 3:00 0 - + +Rule Palestine 1999 max - Apr Fri>=15 0:00 1:00 S +Rule Palestine 1999 max - Oct Fri>=15 0:00 0 - + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Gaza 2:17:52 - LMT 1900 Oct + 2:00 Zion EET 1948 May 15 + 2:00 EgyptAsia EE%sT 1967 Jun 5 + 2:00 Zion I%sT 1996 + 2:00 Jordan EE%sT 1999 + 2:00 Palestine EE%sT + +# Paracel Is +# no information + +# Philippines +# On 1844-08-16, Narciso Claveria, governor-general of the +# Philippines, issued a proclamation announcing that 1844-12-30 was to +# be immediately followed by 1845-01-01. Robert H. van Gent has a +# transcript of the decree in . +# The rest of this data is from Shanks. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Phil 1936 only - Nov 1 0:00 1:00 S +Rule Phil 1937 only - Feb 1 0:00 0 - +Rule Phil 1954 only - Apr 12 0:00 1:00 S +Rule Phil 1954 only - Jul 1 0:00 0 - +Rule Phil 1978 only - Mar 22 0:00 1:00 S +Rule Phil 1978 only - Sep 21 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Manila -15:56:00 - LMT 1844 Dec 31 + 8:04:00 - LMT 1899 May 11 + 8:00 Phil PH%sT 1942 May + 9:00 - JST 1944 Nov + 8:00 Phil PH%sT + +# Qatar +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Qatar 3:26:08 - LMT 1920 # Al Dawhah / Doha + 4:00 - GST 1972 Jun + 3:00 - AST + +# Saudi Arabia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Riyadh 3:06:52 - LMT 1950 + 3:00 - AST + +# Singapore +# The data here are taken from Mok Ly Yng (2003-10-30) +# . +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Singapore 6:55:25 - LMT 1880 + 6:55:25 - SMT 1905 Jun 1 # Singapore M.T. + 7:00 - MALT 1933 Jan 1 # Malaya Time + 7:00 0:20 MALST 1936 + 7:20 - MALT 1941 Sep 1 + 7:30 - MALT 1942 Feb 16 + 9:00 - JST 1945 Sep 12 + 7:30 - MALT 1965 Aug 9 # independence + 7:30 - SGT 1982 Jan 1 # Singapore Time + 8:00 - SGT + +# Spratly Is +# no information + +# Sri Lanka +# From Paul Eggert (1996-09-03): +# "Sri Lanka advances clock by an hour to avoid blackout" +# (www.virtual-pc.com/lankaweb/news/items/240596-2.html, 1996-05-24, +# no longer available as of 1999-08-17) +# reported ``the country's standard time will be put forward by one hour at +# midnight Friday (1830 GMT) `in the light of the present power crisis'.'' +# +# From Dharmasiri Senanayake, Sri Lanka Media Minister (1996-10-24), as quoted +# by Shamindra in +# +# Daily News - Hot News Section (1996-10-26) +# : +# With effect from 12.30 a.m. on 26th October 1996 +# Sri Lanka will be six (06) hours ahead of GMT. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Colombo 5:19:24 - LMT 1880 + 5:19:32 - MMT 1906 # Moratuwa Mean Time + 5:30 - IST 1942 Jan 5 + 5:30 0:30 IHST 1942 Sep + 5:30 1:00 IST 1945 Oct 16 2:00 + 5:30 - IST 1996 May 25 0:00 + 6:30 - LKT 1996 Oct 26 0:30 + 6:00 - LKT + +# Syria +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Syria 1920 1923 - Apr Sun>=15 2:00 1:00 S +Rule Syria 1920 1923 - Oct Sun>=1 2:00 0 - +Rule Syria 1962 only - Apr 29 2:00 1:00 S +Rule Syria 1962 only - Oct 1 2:00 0 - +Rule Syria 1963 1965 - May 1 2:00 1:00 S +Rule Syria 1963 only - Sep 30 2:00 0 - +Rule Syria 1964 only - Oct 1 2:00 0 - +Rule Syria 1965 only - Sep 30 2:00 0 - +Rule Syria 1966 only - Apr 24 2:00 1:00 S +Rule Syria 1966 1976 - Oct 1 2:00 0 - +Rule Syria 1967 1978 - May 1 2:00 1:00 S +Rule Syria 1977 1978 - Sep 1 2:00 0 - +Rule Syria 1983 1984 - Apr 9 2:00 1:00 S +Rule Syria 1983 1984 - Oct 1 2:00 0 - +Rule Syria 1986 only - Feb 16 2:00 1:00 S +Rule Syria 1986 only - Oct 9 2:00 0 - +Rule Syria 1987 only - Mar 1 2:00 1:00 S +Rule Syria 1987 1988 - Oct 31 2:00 0 - +Rule Syria 1988 only - Mar 15 2:00 1:00 S +Rule Syria 1989 only - Mar 31 2:00 1:00 S +Rule Syria 1989 only - Oct 1 2:00 0 - +Rule Syria 1990 only - Apr 1 2:00 1:00 S +Rule Syria 1990 only - Sep 30 2:00 0 - +Rule Syria 1991 only - Apr 1 0:00 1:00 S +Rule Syria 1991 1992 - Oct 1 0:00 0 - +Rule Syria 1992 only - Apr 8 0:00 1:00 S +Rule Syria 1993 only - Mar 26 0:00 1:00 S +Rule Syria 1993 only - Sep 25 0:00 0 - +# IATA SSIM (1998-02) says 1998-04-02; +# (1998-09) says 1999-03-29 and 1999-09-29; (1999-02) says 1999-04-02, +# 2000-04-02, and 2001-04-02; (1999-09) says 2000-03-31 and 2001-03-31; +# ignore all these claims and go with Shanks. +Rule Syria 1994 1996 - Apr 1 0:00 1:00 S +Rule Syria 1994 max - Oct 1 0:00 0 - +Rule Syria 1997 1998 - Mar lastMon 0:00 1:00 S +Rule Syria 1999 max - Apr 1 0:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq + 2:00 Syria EE%sT + +# Tajikistan +# From Shanks. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Dushanbe 4:35:12 - LMT 1924 May 2 + 5:00 - DUST 1930 Jun 21 # Dushanbe Time + 6:00 RussiaAsia DUS%sT 1991 Mar 31 2:00s + 5:00 1:00 DUSST 1991 Sep 9 2:00s + 5:00 - TJT # Tajikistan Time + +# Thailand +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Bangkok 6:42:04 - LMT 1880 + 6:42:04 - BMT 1920 Apr # Bangkok Mean Time + 7:00 - ICT + +# Turkmenistan +# From Shanks. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Ashgabat 3:53:32 - LMT 1924 May 2 # or Ashkhabad + 4:00 - ASHT 1930 Jun 21 # Ashkhabad Time + 5:00 RussiaAsia ASH%sT 1991 Mar 31 2:00 + 4:00 RussiaAsia ASH%sT 1991 Oct 27 # independence + 4:00 RussiaAsia TM%sT 1992 Jan 19 2:00 + 5:00 - TMT + +# United Arab Emirates +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Dubai 3:41:12 - LMT 1920 + 4:00 - GST + +# Uzbekistan +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Samarkand 4:27:12 - LMT 1924 May 2 + 4:00 - SAMT 1930 Jun 21 # Samarkand Time + 5:00 - SAMT 1981 Apr 1 + 5:00 1:00 SAMST 1981 Oct 1 + 6:00 RussiaAsia TAS%sT 1991 Mar 31 2:00 # Tashkent Time + 5:00 RussiaAsia TAS%sT 1991 Sep 1 # independence + 5:00 RussiaAsia UZ%sT 1992 + 5:00 RussiaAsia UZ%sT 1993 + 5:00 - UZT +Zone Asia/Tashkent 4:37:12 - LMT 1924 May 2 + 5:00 - TAST 1930 Jun 21 # Tashkent Time + 6:00 RussiaAsia TAS%sT 1991 Mar 31 2:00s + 5:00 RussiaAsia TAS%sT 1991 Sep 1 # independence + 5:00 RussiaAsia UZ%sT 1992 + 5:00 RussiaAsia UZ%sT 1993 + 5:00 - UZT + +# Vietnam +# From Paul Eggert (1993-11-18): +# Saigon's official name is Thanh-Pho Ho Chi Minh, but it's too long. +# We'll stick with the traditional name for now. +# From Shanks: +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Saigon 7:06:40 - LMT 1906 Jun 9 + 7:06:20 - SMT 1911 Mar 11 0:01 # Saigon MT? + 7:00 - ICT 1912 May + 8:00 - ICT 1931 May + 7:00 - ICT + +# Yemen +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Asia/Aden 3:00:48 - LMT 1950 + 3:00 - AST diff --git a/src/timezone/data/australasia b/src/timezone/data/australasia new file mode 100644 index 0000000000..d8a8e36d53 --- /dev/null +++ b/src/timezone/data/australasia @@ -0,0 +1,1338 @@ +# @(#)australasia 7.69 +# This file also includes Pacific islands. + +# Notes are at the end of this file + +############################################################################### + +# Australia + +# Please see the notes below for the controversy about "EST" versus "AEST" etc. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Aus 1917 only - Jan 1 0:01 1:00 - +Rule Aus 1917 only - Mar 25 2:00 0 - +Rule Aus 1942 only - Jan 1 2:00 1:00 - +Rule Aus 1942 only - Mar 29 2:00 0 - +Rule Aus 1942 only - Sep 27 2:00 1:00 - +Rule Aus 1943 1944 - Mar lastSun 2:00 0 - +Rule Aus 1943 only - Oct 3 2:00 1:00 - +# Go with Whitman and the Australian National Standards Commission, which +# says W Australia didn't use DST in 1943/1944. Ignore Whitman's claim that +# 1944/1945 was just like 1943/1944. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# Northern Territory +Zone Australia/Darwin 8:43:20 - LMT 1895 Feb + 9:00 - CST 1899 May + 9:30 Aus CST +# Western Australia +Zone Australia/Perth 7:43:24 - LMT 1895 Dec + 8:00 Aus WST 1943 Jul + 8:00 - WST 1974 Oct lastSun 2:00s + 8:00 1:00 WST 1975 Mar Sun>=1 2:00s + 8:00 - WST 1983 Oct lastSun 2:00s + 8:00 1:00 WST 1984 Mar Sun>=1 2:00s + 8:00 - WST 1991 Nov 17 2:00s + 8:00 1:00 WST 1992 Mar Sun>=1 2:00s + 8:00 - WST +# Queensland +# +# From Alex Livingston (1996-11-01): +# I have heard or read more than once that some resort islands off the coast +# of Queensland chose to keep observing daylight-saving time even after +# Queensland ceased to. +# +# From Paul Eggert (1996-11-22): +# IATA SSIM (1993-02/1994-09) say that the Holiday Islands (Hayman, Lindeman, +# Hamilton) observed DST for two years after the rest of Queensland stopped. +# Hamilton is the largest, but there is also a Hamilton in Victoria, +# so use Lindeman. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule AQ 1971 only - Oct lastSun 2:00s 1:00 - +Rule AQ 1972 only - Feb lastSun 2:00s 0 - +Rule AQ 1989 1991 - Oct lastSun 2:00s 1:00 - +Rule AQ 1990 1992 - Mar Sun>=1 2:00s 0 - +Rule Holiday 1992 1993 - Oct lastSun 2:00s 1:00 - +Rule Holiday 1993 1994 - Mar Sun>=1 2:00s 0 - +Zone Australia/Brisbane 10:12:08 - LMT 1895 + 10:00 Aus EST 1971 + 10:00 AQ EST +Zone Australia/Lindeman 9:55:56 - LMT 1895 + 10:00 Aus EST 1971 + 10:00 AQ EST 1992 Jul + 10:00 Holiday EST + +# South Australia +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule AS 1971 1985 - Oct lastSun 2:00s 1:00 - +Rule AS 1986 only - Oct 19 2:00s 1:00 - +Rule AS 1987 max - Oct lastSun 2:00s 1:00 - +Rule AS 1972 only - Feb 27 2:00s 0 - +Rule AS 1973 1985 - Mar Sun>=1 2:00s 0 - +Rule AS 1986 1989 - Mar Sun>=15 2:00s 0 - +Rule AS 1990 only - Mar Sun>=18 2:00s 0 - +Rule AS 1991 only - Mar Sun>=1 2:00s 0 - +Rule AS 1992 only - Mar Sun>=18 2:00s 0 - +Rule AS 1993 only - Mar Sun>=1 2:00s 0 - +Rule AS 1994 only - Mar Sun>=18 2:00s 0 - +Rule AS 1995 max - Mar lastSun 2:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Australia/Adelaide 9:14:20 - LMT 1895 Feb + 9:00 - CST 1899 May + 9:30 Aus CST 1971 + 9:30 AS CST + +# Tasmania +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule AT 1967 only - Oct Sun>=1 2:00s 1:00 - +Rule AT 1968 only - Mar lastSun 2:00s 0 - +Rule AT 1968 1985 - Oct lastSun 2:00s 1:00 - +Rule AT 1969 1971 - Mar Sun>=8 2:00s 0 - +Rule AT 1972 only - Feb lastSun 2:00s 0 - +Rule AT 1973 1981 - Mar Sun>=1 2:00s 0 - +Rule AT 1982 1983 - Mar lastSun 2:00s 0 - +Rule AT 1984 1986 - Mar Sun>=1 2:00s 0 - +Rule AT 1986 only - Oct Sun>=15 2:00s 1:00 - +Rule AT 1987 1990 - Mar Sun>=15 2:00s 0 - +Rule AT 1987 only - Oct Sun>=22 2:00s 1:00 - +Rule AT 1988 1990 - Oct lastSun 2:00s 1:00 - +Rule AT 1991 1999 - Oct Sun>=1 2:00s 1:00 - +Rule AT 1991 max - Mar lastSun 2:00s 0 - +Rule AT 2000 only - Aug lastSun 2:00s 1:00 - +Rule AT 2001 max - Oct Sun>=1 2:00s 1:00 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Australia/Hobart 9:49:16 - LMT 1895 Sep + 10:00 - EST 1916 Oct 1 2:00 + 10:00 1:00 EST 1917 Feb + 10:00 Aus EST 1967 + 10:00 AT EST + +# Victoria +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule AV 1971 1985 - Oct lastSun 2:00s 1:00 - +Rule AV 1972 only - Feb lastSun 2:00s 0 - +Rule AV 1973 1985 - Mar Sun>=1 2:00s 0 - +Rule AV 1986 1990 - Mar Sun>=15 2:00s 0 - +Rule AV 1986 1987 - Oct Sun>=15 2:00s 1:00 - +Rule AV 1988 1999 - Oct lastSun 2:00s 1:00 - +Rule AV 1991 1994 - Mar Sun>=1 2:00s 0 - +Rule AV 1995 max - Mar lastSun 2:00s 0 - +Rule AV 2000 only - Aug lastSun 2:00s 1:00 - +Rule AV 2001 max - Oct lastSun 2:00s 1:00 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Australia/Melbourne 9:39:52 - LMT 1895 Feb + 10:00 Aus EST 1971 + 10:00 AV EST + +# New South Wales +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule AN 1971 1985 - Oct lastSun 2:00s 1:00 - +Rule AN 1972 only - Feb 27 2:00s 0 - +Rule AN 1973 1981 - Mar Sun>=1 2:00s 0 - +Rule AN 1982 only - Apr Sun>=1 2:00s 0 - +Rule AN 1983 1985 - Mar Sun>=1 2:00s 0 - +Rule AN 1986 1989 - Mar Sun>=15 2:00s 0 - +Rule AN 1986 only - Oct 19 2:00s 1:00 - +Rule AN 1987 1999 - Oct lastSun 2:00s 1:00 - +Rule AN 1990 1995 - Mar Sun>=1 2:00s 0 - +Rule AN 1996 max - Mar lastSun 2:00s 0 - +Rule AN 2000 only - Aug lastSun 2:00s 1:00 - +Rule AN 2001 max - Oct lastSun 2:00s 1:00 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Australia/Sydney 10:04:52 - LMT 1895 Feb + 10:00 Aus EST 1971 + 10:00 AN EST +Zone Australia/Broken_Hill 9:25:48 - LMT 1895 Feb + 10:00 - EST 1896 Aug 23 + 9:00 - CST 1899 May + 9:30 Aus CST 1971 + 9:30 AN CST 2000 + 9:30 AS CST + +# Lord Howe Island +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule LH 1981 1984 - Oct lastSun 2:00 1:00 - +Rule LH 1982 1985 - Mar Sun>=1 2:00 0 - +Rule LH 1985 only - Oct lastSun 2:00 0:30 - +Rule LH 1986 1989 - Mar Sun>=15 2:00 0 - +Rule LH 1986 only - Oct 19 2:00 0:30 - +Rule LH 1987 1999 - Oct lastSun 2:00 0:30 - +Rule LH 1990 1995 - Mar Sun>=1 2:00 0 - +Rule LH 1996 max - Mar lastSun 2:00 0 - +Rule LH 2000 only - Aug lastSun 2:00 0:30 - +Rule LH 2001 max - Oct lastSun 2:00 0:30 - +Zone Australia/Lord_Howe 10:36:20 - LMT 1895 Feb + 10:00 - EST 1981 Mar + 10:30 LH LHST + +# Australian miscellany +# +# Ashmore Is, Cartier +# no indigenous inhabitants; only seasonal caretakers +# like Australia/Perth, says Turner +# +# Coral Sea Is +# no indigenous inhabitants; only meteorologists +# no information +# +# Macquarie +# permanent occupation (scientific station) since 1948; +# sealing and penguin oil station operated 1888/1917 +# like Australia/Hobart, says Turner + +# Christmas +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Christmas 7:02:52 - LMT 1895 Feb + 7:00 - CXT # Christmas Island Time + +# Cook Is +# From Shanks: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Cook 1978 only - Nov 12 0:00 0:30 HS +Rule Cook 1979 1991 - Mar Sun>=1 0:00 0 - +Rule Cook 1979 1990 - Oct lastSun 0:00 0:30 HS +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Rarotonga -10:39:04 - LMT 1901 # Avarua + -10:30 - CKT 1978 Nov 12 # Cook Is Time + -10:00 Cook CK%sT + +# Cocos +# From USNO (1989): +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Indian/Cocos 6:30 - CCT # Cocos Islands Time + +# Fiji +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Fiji 1998 1999 - Nov Sun>=1 2:00 1:00 S +Rule Fiji 1999 2000 - Feb lastSun 3:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Fiji 11:53:40 - LMT 1915 Oct 26 # Suva + 12:00 Fiji FJ%sT # Fiji Time + +# French Polynesia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Gambier -8:59:48 - LMT 1912 Oct # Rikitea + -9:00 - GAMT # Gambier Time +Zone Pacific/Marquesas -9:18:00 - LMT 1912 Oct + -9:30 - MART # Marquesas Time +Zone Pacific/Tahiti -9:58:16 - LMT 1912 Oct # Papeete + -10:00 - TAHT # Tahiti Time +# Clipperton (near North America) is administered from French Polynesia; +# it is uninhabited. + +# Guam +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Guam -14:21:00 - LMT 1844 Dec 31 + 9:39:00 - LMT 1901 # Agana + 10:00 - GST 2000 Dec 23 # Guam + 10:00 - ChST # Chamorro Standard Time + +# Kiribati +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Tarawa 11:32:04 - LMT 1901 # Bairiki + 12:00 - GILT # Gilbert Is Time +Zone Pacific/Enderbury -11:24:20 - LMT 1901 + -12:00 - PHOT 1979 Oct # Phoenix Is Time + -11:00 - PHOT 1995 + 13:00 - PHOT +Zone Pacific/Kiritimati -10:29:20 - LMT 1901 + -10:40 - LINT 1979 Oct # Line Is Time + -10:00 - LINT 1995 + 14:00 - LINT + +# N Mariana Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Saipan -14:17:00 - LMT 1844 Dec 31 + 9:43:00 - LMT 1901 + 9:00 - MPT 1969 Oct # N Mariana Is Time + 10:00 - MPT 2000 Dec 23 + 10:00 - ChST # Chamorro Standard Time + +# Marshall Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Majuro 11:24:48 - LMT 1901 + 11:00 - MHT 1969 Oct # Marshall Islands Time + 12:00 - MHT +Zone Pacific/Kwajalein 11:09:20 - LMT 1901 + 11:00 - MHT 1969 Oct + -12:00 - KWAT 1993 Aug 20 # Kwajalein Time + 12:00 - MHT + +# Micronesia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Yap 9:12:32 - LMT 1901 # Colonia + 9:00 - YAPT 1969 Oct # Yap Time + 10:00 - YAPT +Zone Pacific/Truk 10:07:08 - LMT 1901 + 10:00 - TRUT # Truk Time +Zone Pacific/Ponape 10:32:52 - LMT 1901 # Kolonia + 11:00 - PONT # Ponape Time +Zone Pacific/Kosrae 10:51:56 - LMT 1901 + 11:00 - KOST 1969 Oct # Kosrae Time + 12:00 - KOST 1999 + 11:00 - KOST + +# Nauru +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Nauru 11:07:40 - LMT 1921 Jan 15 # Uaobe + 11:30 - NRT 1942 Mar 15 # Nauru Time + 9:00 - JST 1944 Aug 15 + 11:30 - NRT 1979 May + 12:00 - NRT + +# New Caledonia +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule NC 1977 1978 - Dec Sun>=1 0:00 1:00 S +Rule NC 1978 1979 - Feb 27 0:00 0 - +Rule NC 1996 only - Dec 1 2:00s 1:00 S +# Shanks says the following was at 2:00; go with IATA. +Rule NC 1997 only - Mar 2 2:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Noumea 11:05:48 - LMT 1912 Jan 13 + 11:00 NC NC%sT + + +############################################################################### + +# New Zealand + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule NZ 1927 only - Nov 6 2:00 1:00 S +Rule NZ 1928 only - Mar 4 2:00 0 M +Rule NZ 1928 1933 - Oct Sun>=8 2:00 0:30 S +Rule NZ 1929 1933 - Mar Sun>=15 2:00 0 M +Rule NZ 1934 1940 - Apr lastSun 2:00 0 M +Rule NZ 1934 1940 - Sep lastSun 2:00 0:30 S +Rule NZ 1946 only - Jan 1 0:00 0 S +# Since 1957 Chatham has been 45 minutes ahead of NZ, but there's no +# convenient notation for this so we must duplicate the Rule lines. +Rule NZ 1974 only - Nov Sun>=1 2:00s 1:00 D +Rule Chatham 1974 only - Nov Sun>=1 2:45s 1:00 D +Rule NZ 1975 only - Feb lastSun 2:00s 0 S +Rule Chatham 1975 only - Feb lastSun 2:45s 0 S +Rule NZ 1975 1988 - Oct lastSun 2:00s 1:00 D +Rule Chatham 1975 1988 - Oct lastSun 2:45s 1:00 D +Rule NZ 1976 1989 - Mar Sun>=1 2:00s 0 S +Rule Chatham 1976 1989 - Mar Sun>=1 2:45s 0 S +Rule NZ 1989 only - Oct Sun>=8 2:00s 1:00 D +Rule Chatham 1989 only - Oct Sun>=8 2:45s 1:00 D +Rule NZ 1990 max - Oct Sun>=1 2:00s 1:00 D +Rule Chatham 1990 max - Oct Sun>=1 2:45s 1:00 D +Rule NZ 1990 max - Mar Sun>=15 2:00s 0 S +Rule Chatham 1990 max - Mar Sun>=15 2:45s 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Auckland 11:39:04 - LMT 1868 Nov 2 + 11:30 NZ NZ%sT 1946 Jan 1 + 12:00 NZ NZ%sT +Zone Pacific/Chatham 12:13:48 - LMT 1957 Jan 1 + 12:45 Chatham CHA%sT + + +# Auckland Is +# uninhabited; Maori and Moriori, colonial settlers, pastoralists, sealers, +# and scientific personnel have wintered + +# Campbell I +# minor whaling stations operated 1909/1914 +# scientific station operated 1941/1995; +# previously whalers, sealers, pastoralists, and scientific personnel wintered +# was probably like Pacific/Auckland + +############################################################################### + + +# Niue +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Niue -11:19:40 - LMT 1901 # Alofi + -11:20 - NUT 1951 # Niue Time + -11:30 - NUT 1978 Oct 1 + -11:00 - NUT + +# Norfolk +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Norfolk 11:11:52 - LMT 1901 # Kingston + 11:12 - NMT 1951 # Norfolk Mean Time + 11:30 - NFT # Norfolk Time + +# Palau (Belau) +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Palau 8:57:56 - LMT 1901 # Koror + 9:00 - PWT # Palau Time + +# Papua New Guinea +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Port_Moresby 9:48:40 - LMT 1880 + 9:48:32 - PMMT 1895 # Port Moresby Mean Time + 10:00 - PGT # Papua New Guinea Time + +# Pitcairn +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Pitcairn -8:40:20 - LMT 1901 # Adamstown + -8:30 - PNT 1998 Apr 27 00:00 + -8:00 - PST # Pitcairn Standard Time + +# American Samoa +Zone Pacific/Pago_Pago 12:37:12 - LMT 1879 Jul 5 + -11:22:48 - LMT 1911 + -11:30 - SAMT 1950 # Samoa Time + -11:00 - NST 1967 Apr # N=Nome + -11:00 - BST 1983 Nov 30 # B=Bering + -11:00 - SST # S=Samoa + +# W Samoa +Zone Pacific/Apia 12:33:04 - LMT 1879 Jul 5 + -11:26:56 - LMT 1911 + -11:30 - SAMT 1950 # Samoa Time + -11:00 - WST # W Samoa Time + +# Solomon Is +# excludes Bougainville, for which see Papua New Guinea +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Guadalcanal 10:39:48 - LMT 1912 Oct # Honiara + 11:00 - SBT # Solomon Is Time + +# Tokelau Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Fakaofo -11:24:56 - LMT 1901 + -10:00 - TKT # Tokelau Time + +# Tonga +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Tonga 1999 only - Oct 7 2:00s 1:00 S +Rule Tonga 2000 only - Mar 19 2:00s 0 - +Rule Tonga 2000 2001 - Nov Sun>=1 2:00 1:00 S +Rule Tonga 2001 2002 - Jan lastSun 2:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Tongatapu 12:19:20 - LMT 1901 + 12:20 - TOT 1941 # Tonga Time + 13:00 - TOT 1999 + 13:00 Tonga TO%sT + +# Tuvalu +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Funafuti 11:56:52 - LMT 1901 + 12:00 - TVT # Tuvalu Time + + +# US minor outlying islands + +# Howland, Baker +# uninhabited since World War II +# no information; was probably like Pacific/Pago_Pago + +# Jarvis +# uninhabited since 1958 +# no information; was probably like Pacific/Kiritimati + +# Johnston +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Johnston -10:00 - HST + +# Kingman +# uninhabited + +# Midway +Zone Pacific/Midway -11:49:28 - LMT 1901 + -11:00 - NST 1956 Jun 3 + -11:00 1:00 NDT 1956 Sep 2 + -11:00 - NST 1967 Apr # N=Nome + -11:00 - BST 1983 Nov 30 # B=Bering + -11:00 - SST # S=Samoa + +# Palmyra +# uninhabited since World War II; was probably like Pacific/Kiritimati + +# Wake +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Wake 11:06:28 - LMT 1901 + 12:00 - WAKT # Wake Time + + +# Vanuatu +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Vanuatu 1983 only - Sep 25 0:00 1:00 S +Rule Vanuatu 1984 1991 - Mar Sun>=23 0:00 0 - +Rule Vanuatu 1984 only - Oct 23 0:00 1:00 S +Rule Vanuatu 1985 1991 - Sep Sun>=23 0:00 1:00 S +Rule Vanuatu 1992 1993 - Jan Sun>=23 0:00 0 - +Rule Vanuatu 1992 only - Oct Sun>=23 0:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Efate 11:13:16 - LMT 1912 Jan 13 # Vila + 11:00 Vanuatu VU%sT # Vanuatu Time + +# Wallis and Futuna +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Pacific/Wallis 12:15:20 - LMT 1901 + 12:00 - WFT # Wallis & Futuna Time + +############################################################################### + +# NOTES + +# This data is by no means authoritative; if you think you know better, +# go ahead and edit the file (and please send any changes to +# tz@elsie.nci.nih.gov for general use in the future). + +# From Paul Eggert (1999-10-29): +# A good source for time zone historical data outside the U.S. is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1990, +# and IATA SSIM is the source for entries after 1990. +# +# Another source occasionally used is Edward W. Whitman, World Time Differences, +# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), which +# I found in the UCLA library. +# +# A reliable and entertaining source about time zones is +# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997). +# +# I invented the abbreviations marked `*' in the following table; +# the rest are from earlier versions of this file, or from other sources. +# Corrections are welcome! +# std dst +# LMT Local Mean Time +# 8:00 WST WST Western Australia +# 9:00 JST Japan +# 9:30 CST CST Central Australia +# 10:00 EST EST Eastern Australia +# 10:00 ChST Chamorro +# 10:30 LHST LHST Lord Howe* +# 11:30 NZMT NZST New Zealand through 1945 +# 12:00 NZST NZDT New Zealand 1946-present +# 12:45 CHAST CHADT Chatham* +# -11:00 SST Samoa +# -10:00 HST Hawaii +# - 8:00 PST Pitcairn* +# +# See the `northamerica' file for Hawaii. +# See the `southamerica' file for Easter I and the Galapagos Is. + +############################################################################### + +# Australia + +# +# Australia's Daylight Saving Times +# , by Margaret Turner, summarizes daylight saving issues in Australia. + +# From John Mackin (1991-03-06): +# We in Australia have _never_ referred to DST as `daylight' time. +# It is called `summer' time. Now by a happy coincidence, `summer' +# and `standard' happen to start with the same letter; hence, the +# abbreviation does _not_ change... +# The legislation does not actually define abbreviations, at least +# in this State, but the abbreviation is just commonly taken to be the +# initials of the phrase, and the legislation here uniformly uses +# the phrase `summer time' and does not use the phrase `daylight +# time'. +# Announcers on the Commonwealth radio network, the ABC (for Australian +# Broadcasting Commission), use the phrases `Eastern Standard Time' +# or `Eastern Summer Time'. (Note, though, that as I say in the +# current australasia file, there is really no such thing.) Announcers +# on its overseas service, Radio Australia, use the same phrases +# prefixed by the word `Australian' when referring to local times; +# time announcements on that service, naturally enough, are made in UTC. + +# From Arthur David Olson (1992-03-08): +# Given the above, what's chosen for year-round use is: +# CST for any place operating at a GMTOFF of 9:30 +# WST for any place operating at a GMTOFF of 8:00 +# EST for any place operating at a GMTOFF of 10:00 + +# From Paul Eggert (2001-04-05), summarizing a long discussion about "EST" +# versus "AEST" etc.: +# +# I see the following points of dispute: +# +# * How important are unique time zone abbreviations? +# +# Here I tend to agree with the point (most recently made by Chris +# Newman) that unique abbreviations should not be essential for proper +# operation of software. We have other instances of ambiguity +# (e.g. "IST" denoting both "Israel Standard Time" and "Indian +# Standard Time"), and they are not likely to go away any time soon. +# In the old days, some software mistakenly relied on unique +# abbreviations, but this is becoming less true with time, and I don't +# think it's that important to cater to such software these days. +# +# On the other hand, there is another motivation for unambiguous +# abbreviations: it cuts down on human confusion. This is +# particularly true for Australia, where "EST" can mean one thing for +# time T and a different thing for time T plus 1 second. +# +# * Does the relevant legislation indicate which abbreviations should be used? +# +# Here I tend to think that things are a mess, just as they are in +# many other countries. We Americans are currently disagreeing about +# which abbreviation to use for the newly legislated Chamorro Standard +# Time, for example. +# +# Personally, I would prefer to use common practice; I would like to +# refer to legislation only for examples of common practice, or as a +# tiebreaker. +# +# * Do Australians more often use "Eastern Daylight Time" or "Eastern +# Summer Time"? Do they typically prefix the time zone names with +# the word "Australian"? +# +# My own impression is that both "Daylight Time" and "Summer Time" are +# common and are widely understood, but that "Summer Time" is more +# popular; and that the leading "A" is also common but is omitted more +# often than not. I just used AltaVista advanced search and got the +# following count of page hits: +# +# 1,103 "Eastern Summer Time" AND domain:au +# 971 "Australian Eastern Summer Time" AND domain:au +# 613 "Eastern Daylight Time" AND domain:au +# 127 "Australian Eastern Daylight Time" AND domain:au +# +# Here "Summer" seems quite a bit more popular than "Daylight", +# particularly when we know the time zone is Australian and not US, +# say. The "Australian" prefix seems to be popular for Eastern Summer +# Time, but unpopular for Eastern Daylight Time. +# +# For abbreviations, tools like AltaVista are less useful because of +# ambiguity. Many hits are not really time zones, unfortunately, and +# many hits denote US time zones and not Australian ones. But here +# are the hit counts anyway: +# +# 161,304 "EST" and domain:au +# 25,156 "EDT" and domain:au +# 18,263 "AEST" and domain:au +# 10,416 "AEDT" and domain:au +# +# 14,538 "CST" and domain:au +# 5,728 "CDT" and domain:au +# 176 "ACST" and domain:au +# 29 "ACDT" and domain:au +# +# 7,539 "WST" and domain:au +# 68 "AWST" and domain:au +# +# This data suggest that Australians tend to omit the "A" prefix in +# practice. The situation for "ST" versus "DT" is less clear, given +# the ambiguities involved. +# +# * How do Australians feel about the abbreviations in the tz database? +# +# If you just count Australians on this list, I count 2 in favor and 3 +# against. One of the "against" votes (David Keegel) counseled delay, +# saying that both AEST/AEDT and EST/EST are widely used and +# understood in Australia. + +# From Paul Eggert (1995-12-19): +# Shanks reports 2:00 for all autumn changes in Australia and New Zealand. +# Mark Prior writes that his newspaper +# reports that NSW's fall 1995 change will occur at 2:00, +# but Robert Elz says it's been 3:00 in Victoria since 1970 +# and perhaps the newspaper's `2:00' is referring to standard time. +# For now we'll continue to assume 2:00s for changes since 1960. + +# From Eric Ulevik (1998-01-05): +# +# Here are some URLs to Australian time legislation. These URLs are stable, +# and should probably be included in the data file. There are probably more +# relevant entries in this database. +# +# NSW (including LHI and Broken Hill): +# +# Standard Time Act 1987 (updated 1995-04-04) +# +# ACT +# +# Standard Time and Summer Time Act 1972 +# +# SA +# +# Standard Time Act, 1898 +# + +# Northern Territory + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # The NORTHERN TERRITORY.. [ Courtesy N.T. Dept of the Chief Minister ] +# # [ Nov 1990 ] +# # N.T. have never utilised any DST due to sub-tropical/tropical location. +# ... +# Zone Australia/North 9:30 - CST + +# From Bradley White (1991-03-04): +# A recent excerpt from an Australian newspaper... +# the Northern Territory do[es] not have daylight saving. + +# Western Australia + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # The state of WESTERN AUSTRALIA.. [ Courtesy W.A. dept Premier+Cabinet ] +# # [ Nov 1990 ] +# # W.A. suffers from a great deal of public and political opposition to +# # DST in principle. A bill is brought before parliament in most years, but +# # usually defeated either in the upper house, or in party caucus +# # before reaching parliament. +# ... +# Zone Australia/West 8:00 AW %sST +# ... +# Rule AW 1974 only - Oct lastSun 2:00 1:00 D +# Rule AW 1975 only - Mar Sun>=1 3:00 0 W +# Rule AW 1983 only - Oct lastSun 2:00 1:00 D +# Rule AW 1984 only - Mar Sun>=1 3:00 0 W + +# From Bradley White (1991-03-04): +# A recent excerpt from an Australian newspaper... +# Western Australia...do[es] not have daylight saving. + +# From John D. Newman via Bradley White (1991-11-02): +# Western Australia is still on "winter time". Some DH in Sydney +# rang me at home a few days ago at 6.00am. (He had just arrived at +# work at 9.00am.) +# W.A. is switching to Summer Time on Nov 17th just to confuse +# everybody again. + +# From Arthur David Olson (1992-03-08): +# The 1992 ending date used in the rules is a best guess; +# it matches what was used in the past. + +# +# The Australian Bureau of Meteorology FAQ +# (1999-09-27) writes that Giles Meteorological Station uses +# South Australian time even though it's located in Western Australia. + +# Queensland +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # The state of QUEENSLAND.. [ Courtesy Qld. Dept Premier Econ&Trade Devel ] +# # [ Dec 1990 ] +# ... +# Zone Australia/Queensland 10:00 AQ %sST +# ... +# Rule AQ 1971 only - Oct lastSun 2:00 1:00 D +# Rule AQ 1972 only - Feb lastSun 3:00 0 E +# Rule AQ 1989 max - Oct lastSun 2:00 1:00 D +# Rule AQ 1990 max - Mar Sun>=1 3:00 0 E + +# From Bradley White (1989-12-24): +# "Australia/Queensland" now observes daylight time (i.e. from +# October 1989). + +# From Bradley White (1991-03-04): +# A recent excerpt from an Australian newspaper... +# ...Queensland...[has] agreed to end daylight saving +# at 3am tomorrow (March 3)... + +# From John Mackin (1991-03-06): +# I can certainly confirm for my part that Daylight Saving in NSW did in fact +# end on Sunday, 3 March. I don't know at what hour, though. (It surprised +# me.) + +# From Bradley White (1992-03-08): +# ...there was recently a referendum in Queensland which resulted +# in the experimental daylight saving system being abandoned. So, ... +# ... +# Rule QLD 1989 1991 - Oct lastSun 2:00 1:00 D +# Rule QLD 1990 1992 - Mar Sun>=1 3:00 0 S +# ... + +# From Arthur David Olson (1992-03-08): +# The chosen rules the union of the 1971/1972 change and the 1989-1992 changes. + +# From Rives McDow (2002-04-09): +# The most interesting region I have found consists of three towns on the +# southern coast of Australia, population 10 at last report, along with +# 50,000 sheep, about 100 kilometers long and 40 kilometers into the +# continent. The primary town is Madura, with the other towns being +# Mundrabilla and Eucla. According to the sheriff of Madura, the +# residents got tired of having to change the time so often, as they are +# located in a strip overlapping the border of South Australia and Western +# Australia. South Australia observes daylight saving time; Western +# Australia does not. The two states are one and a half hours apart. The +# residents decided to forget about this nonsense of changing the clock so +# much and set the local time 20 hours and 45 minutes from the +# international date line, or right in the middle of the time of South +# Australia and Western Australia. As it only affects about 10 people and +# tourists staying at the Madura Motel, it has never really made as big an +# impact as Broken Hill. However, as tourist visiting there or anyone +# calling the local sheriff will attest, they do keep time in this way. +# +# From Paul Eggert (2002-04-09): +# This is confirmed by the section entitled +# "What's the deal with time zones???" in +# , +# which says a few other things: +# +# * Border Village, SA also is 45 minutes ahead of Perth. +# * The locals call this time zone "central W.A. Time" (presumably "CWAT"). +# * The locals also call Western Australia time "Perth time". +# +# It's not clear from context whether everyone in Western Australia +# knows of this naming convention, or whether it's just the people in +# this subregion. + +# South Australia, Tasmania, Victoria + +# From Arthur David Olson (1992-03-08): +# The rules from version 7.1 follow. +# There are lots of differences between these rules and +# the Shepherd et al. rules. Since the Shepherd et al. rules +# and Bradley White's newspaper article are in agreement on +# current DST ending dates, no worries. +# +# Rule Oz 1971 1985 - Oct lastSun 2:00 1:00 - +# Rule Oz 1986 max - Oct Sun<=24 2:00 1:00 - +# Rule Oz 1972 only - Feb 27 3:00 0 - +# Rule Oz 1973 1986 - Mar Sun>=1 3:00 0 - +# Rule Oz 1987 max - Mar Sun<=21 3:00 0 - +# Zone Australia/Tasmania 10:00 Oz EST +# Zone Australia/South 9:30 Oz CST +# Zone Australia/Victoria 10:00 Oz EST 1985 Oct lastSun 2:00 +# 10:00 1:00 EST 1986 Mar Sun<=21 3:00 +# 10:00 Oz EST + +# From Robert Elz (1991-03-06): +# I believe that the current start date for DST is "lastSun" in Oct... +# that changed Oct 89. That is, we're back to the +# original rule, and that rule currently applies in all the states +# that have dst, incl Qld. (Certainly it was true in Vic). +# The file I'm including says that happened in 1988, I think +# that's incorrect, but I'm not 100% certain. + +# South Australia + +# From Bradley White (1991-03-04): +# A recent excerpt from an Australian newspaper... +# ...South Australia...[has] agreed to end daylight saving +# at 3am tomorrow (March 3)... + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # The state of SOUTH AUSTRALIA....[ Courtesy of S.A. Dept of Labour ] +# # [ Nov 1990 ] +# ... +# Zone Australia/South 9:30 AS %sST +# ... +# Rule AS 1971 max - Oct lastSun 2:00 1:00 D +# Rule AS 1972 1985 - Mar Sun>=1 3:00 0 C +# Rule AS 1986 1990 - Mar Sun<=21 3:00 0 C +# Rule AS 1991 max - Mar Sun>=1 3:00 0 C + +# From Bradley White (1992-03-11): +# Recent correspondence with a friend in Adelaide +# contained the following exchange: "Due to the Adelaide Festival, +# South Australia delays setting back our clocks for a few weeks." + +# From Robert Elz (1992-03-13): +# I heard that apparently (or at least, it appears that) +# South Aus will have an extra 3 weeks daylight saving every even +# numbered year (from 1990). That's when the Adelaide Festival +# is on... + +# From Robert Elz (1992-03-16, 00:57:07 +1000): +# DST didn't end in Adelaide today (yesterday).... +# But whether it's "4th Sunday" or "2nd last Sunday" I have no idea whatever... +# (it's just as likely to be "the Sunday we pick for this year"...). + +# From Bradley White (1994-04-11): +# If Sun, 15 March, 1992 was at +1030 as kre asserts, but yet Sun, 20 March, +# 1994 was at +0930 as John Connolly's customer seems to assert, then I can +# only conclude that the actual rule is more complicated.... + +# From John Warburton (1994-10-07): +# The new Daylight Savings dates for South Australia ... +# was gazetted in the Government Hansard on Sep 26 1994.... +# start on last Sunday in October and end in last sunday in March. + +# Tasmania + +# The rules for 1967 through 1991 were reported by George Shepherd +# via Simon Woodhead via Robert Elz (1991-03-06): +# # The state of TASMANIA.. [Courtesy Tasmanian Dept of Premier + Cabinet ] +# # [ Nov 1990 ] + +# From Bill Hart via Guy Harris (1991-10-10): +# Oh yes, the new daylight savings rules are uniquely tasmanian, we have +# 6 weeks a year now when we are out of sync with the rest of Australia +# (but nothing new about that). + +# From Alex Livingston (1999-10-04): +# I heard on the ABC (Australian Broadcasting Corporation) radio news on the +# (long) weekend that Tasmania, which usually goes its own way in this regard, +# has decided to join with most of NSW, the ACT, and most of Victoria +# (Australia) and start daylight saving on the last Sunday in August in 2000 +# instead of the first Sunday in October. + +# Sim Alam (2000-07-03) reported a legal citation for the 2000/2001 rules: +# http://www.thelaw.tas.gov.au/fragview/42++1968+GS3A@EN+2000070300 + +# Victoria + +# The rules for 1971 through 1991 were reported by George Shepherd +# via Simon Woodhead via Robert Elz (1991-03-06): +# # The state of VICTORIA.. [ Courtesy of Vic. Dept of Premier + Cabinet ] +# # [ Nov 1990 ] + +# From Scott Harrington (2001-08-29): +# On KQED's "City Arts and Lectures" program last night I heard an +# interesting story about daylight savings time. Dr. John Heilbron was +# discussing his book "The Sun in the Church: Cathedrals as Solar +# Observatories"[1], and in particular the Shrine of Remembrance[2] located +# in Melbourne, Australia. +# +# Apparently the shrine's main purpose is a beam of sunlight which +# illuminates a special spot on the floor at the 11th hour of the 11th day +# of the 11th month (Remembrance Day) every year in memory of Australia's +# fallen WWI soldiers. And if you go there on Nov. 11, at 11am local time, +# you will indeed see the sunbeam illuminate the special spot at the +# expected time. +# +# However, that is only because of some special mirror contraption that had +# to be employed, since due to daylight savings time, the true solar time of +# the remembrance moment occurs one hour later (or earlier?). Perhaps +# someone with more information on this jury-rig can tell us more. +# +# [1] http://www.hup.harvard.edu/catalog/HEISUN.html +# [2] http://www.shrine.org.au + +# New South Wales + +# From Arthur David Olson: +# New South Wales and subjurisdictions have their own ideas of a fun time. +# Based on law library research by John Mackin (john@basser.cs.su.oz), +# who notes: +# In Australia, time is not legislated federally, but rather by the +# individual states. Thus, while such terms as ``Eastern Standard Time'' +# [I mean, of course, Australian EST, not any other kind] are in common +# use, _they have NO REAL MEANING_, as they are not defined in the +# legislation. This is very important to understand. +# I have researched New South Wales time only... + +# From Paul Eggert (1999-09-27): +# The Information Service of the Australian National Standards Commission +# +# Daylight Saving +# page (1995-04) has an excellent overall history of Australian DST. +# The Community Relations Division of the NSW Attorney General's Department +# publishes a history of daylight saving in NSW. See: +# +# Lawlink NSW: Daylight Saving in New South Wales +# + +# From Eric Ulevik (1999-05-26): +# DST will start in NSW on the last Sunday of August, rather than the usual +# October in 2000. [See: Matthew Moore, +# +# Two months more daylight saving +# +# Sydney Morning Herald (1999-05-26).] + +# From Paul Eggert (1999-09-27): +# See the following official NSW source: +# +# Daylight Saving in New South Wales. +# +# +# Narrabri Shire (NSW) council has announced it will ignore the extension of +# daylight saving next year. See: +# +# Narrabri Council to ignore daylight saving +# (1999-07-22). For now, we'll wait to see if this really happens. +# +# Victoria will following NSW. See: +# +# Vic to extend daylight saving +# (1999-07-28). +# +# However, South Australia rejected the DST request. See: +# +# South Australia rejects Olympics daylight savings request +# (1999-07-19). +# +# Queensland also will not observe DST for the Olympics. See: +# +# Qld says no to daylight savings for Olympics +# (1999-06-01), which quotes Queensland Premier Peter Beattie as saying +# ``Look you've got to remember in my family when this came up last time +# I voted for it, my wife voted against it and she said to me it's all very +# well for you, you don't have to worry about getting the children out of +# bed, getting them to school, getting them to sleep at night. +# I've been through all this argument domestically...my wife rules.'' +# +# Broken Hill will stick with South Australian time in 2000. See: +# +# Broken Hill to be behind the times +# (1999-07-21). + +# IATA SSIM (1998-09) says that the spring 2000 change for Australian +# Capital Territory, New South Wales except Lord Howe Island and Broken +# Hill, and Victoria will be August 27, presumably due to the Sydney Olympics. + +# From Eric Ulevik, referring to Sydney's Sun Herald (2000-08-13), page 29: +# The Queensland Premier Peter Beattie is encouraging northern NSW +# towns to use Queensland time. + +# Yancowinna + +# From John Mackin (1989-01-04): +# `Broken Hill' means the County of Yancowinna. + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # YANCOWINNA.. [ Confirmation courtesy of Broken Hill Postmaster ] +# # [ Dec 1990 ] +# ... +# # Yancowinna uses Central Standard Time, despite [its] location on the +# # New South Wales side of the S.A. border. Most business and social dealings +# # are with CST zones, therefore CST is legislated by local government +# # although the switch to Summer Time occurs in line with N.S.W. There have +# # been years when this did not apply, but the historical data is not +# # presently available. +# Zone Australia/Yancowinna 9:30 AY %sST +# ... +# Rule AY 1971 1985 - Oct lastSun 2:00 1:00 D +# Rule AY 1972 only - Feb lastSun 3:00 0 C +# [followed by other Rules] + +# Lord Howe Island + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# LHI... [ Courtesy of Pauline Van Winsen.. pauline@Aus ] +# [ Dec 1990 ] +# Lord Howe Island is located off the New South Wales coast, and is half an +# hour ahead of NSW time. + +# From James Lonergan, Secretary, Lord Howe Island Board (2000-01-27): +# Lord Howe Island summer time in 2000/2001 will commence on the same +# date as the rest of NSW (i.e. 2000-08-27). For your information the +# Lord Howe Island Board (controlling authority for the Island) is +# seeking the community's views on various options for summer time +# arrangements on the Island, e.g. advance clocks by 1 full hour +# instead of only 30 minutes. Dependant on the wishes of residents +# the Board may approach the NSW government to change the existing +# arrangements. The starting date for summer time on the Island will +# however always coincide with the rest of NSW. + +# From James Lonergan, Secretary, Lord Howe Island Board (2000-10-25): +# Lord Howe Island advances clocks by 30 minutes during DST in NSW and retards +# clocks by 30 minutes when DST finishes. Since DST was most recently +# introduced in NSW, the "changeover" time on the Island has been 02:00 as +# shown on clocks on LHI. I guess this means that for 30 minutes at the start +# of DST, LHI is actually 1 hour ahead of the rest of NSW. + +# From Paul Eggert (2001-02-09): +# For Lord Howe dates we use Shanks through 1989, and Lonergan thereafter. +# For times we use Lonergan. + +############################################################################### + +# New Zealand + +# From Mark Davies (1990-10-03): +# the 1989/90 year was a trial of an extended "daylight saving" period. +# This trial was deemed successful and the extended period adopted for +# subsequent years (with the addition of a further week at the start). +# source -- phone call to Ministry of Internal Affairs Head Office. + +# From George Shepherd via Simon Woodhead via Robert Elz (1991-03-06): +# # The Country of New Zealand (Australia's east island -) Gee they hate that! +# # or is Australia the west island of N.Z. +# # [ courtesy of Geoff Tribble.. Geofft@Aus.. Auckland N.Z. ] +# # [ Nov 1990 ] +# ... +# Rule NZ 1974 1988 - Oct lastSun 2:00 1:00 D +# Rule NZ 1989 max - Oct Sun>=1 2:00 1:00 D +# Rule NZ 1975 1989 - Mar Sun>=1 3:00 0 S +# Rule NZ 1990 max - Mar lastSun 3:00 0 S +# ... +# Zone NZ 12:00 NZ NZ%sT # New Zealand +# Zone NZ-CHAT 12:45 - NZ-CHAT # Chatham Island + +# From Arthur David Olson (1992-03-08): +# The chosen rules use the Davies October 8 values for the start of DST in 1989 +# rather than the October 1 value. + +# From Paul Eggert (1995-12-19); +# Shanks reports 2:00 for all autumn changes in Australia and New Zealand. +# Robert Uzgalis writes that the New Zealand Daylight +# Savings Time Order in Council dated 1990-06-18 specifies 2:00 standard +# time on both the first Sunday in October and the third Sunday in March. +# As with Australia, we'll assume the tradition is 2:00s, not 2:00. +# +# From Paul Eggert (2003-05-26): +# The Department of Internal Affairs (DIA) maintains a brief history, +# as does Carol Squires; see tz-link.htm for the full references. +# Use these sources in preference to Shanks. +# +# For Chatham, IATA SSIM (1991/1999) gives the NZ rules but with +# transitions at 2:45 local standard time; this confirms that Chatham +# is always exactly 45 minutes ahead of Auckland. + +############################################################################### + + +# Fiji + +# Howse writes (p 153) that in 1879 the British governor of Fiji +# enacted an ordinance standardizing the islands on Antipodean Time +# instead of the American system (which was one day behind). + +# From Rives McDow (1998-10-08): +# Fiji will introduce DST effective 0200 local time, 1998-11-01 +# until 0300 local time 1999-02-28. Each year the DST period will +# be from the first Sunday in November until the last Sunday in February. + +# From Paul Eggert (2000-01-08): +# IATA SSIM (1999-09) says DST ends 0100 local time. Go with McDow. + +# From the BBC World Service (1998-10-31 11:32 UTC): +# The Fijiian government says the main reasons for the time change is to +# improve productivity and reduce road accidents. But correspondents say it +# also hopes the move will boost Fiji's ability to compete with other pacific +# islands in the effort to attract tourists to witness the dawning of the new +# millenium. + +# http://www.fiji.gov.fj/press/2000_09/2000_09_13-05.shtml (2000-09-13) +# reports that Fiji has discontinued DST. + +# Johnston + +# Johnston data is from usno1995. + + +# Kiribati + +# From Paul Eggert (1996-01-22): +# Today's _Wall Street Journal_ (page 1) reports that Kiribati +# ``declared it the same day throught the country as of Jan. 1, 1995'' +# as part of the competition to be first into the 21st century. + + +# Kwajalein + +# In comp.risks 14.87 (26 August 1993), Peter Neumann writes: +# I wonder what happened in Kwajalein, where there was NO Friday, +# 1993-08-20. Thursday night at midnight Kwajalein switched sides with +# respect to the International Date Line, to rejoin its fellow islands, +# going from 11:59 p.m. Thursday to 12:00 m. Saturday in a blink. + + +# N Mariana Is, Guam + +# Howse writes (p 153) ``The Spaniards, on the other hand, reached the +# Philippines and the Ladrones from America,'' and implies that the Ladrones +# (now called the Marianas) kept American date for quite some time. +# For now, we assume the Ladrones switched at the same time as the Philippines; +# see Asia/Manila. + +# US Public Law 106-564 (2000-12-23) made UTC+10 the official standard time, +# under the name "Chamorro Standard Time". There is no official abbreviation, +# but Congressman Robert A. Underwood, author of the bill that became law, +# wrote in a press release (2000-12-27) that he will seek the use of "ChST". + + +# Micronesia + +# Alan Eugene Davis writes (1996-03-16), +# ``I am certain, having lived there for the past decade, that "Truk" +# (now properly known as Chuuk) ... is in the time zone GMT+10.'' +# +# Shanks writes that Truk switched from UTC+10 to UTC+11 on 1978-10-01; +# ignore this for now. + +# From Paul Eggert (1999-10-29): +# The Federated States of Micronesia Visitors Board writes in +# +# The Federated States of Micronesia - Visitor Information +# (1999-01-26) +# that Truk and Yap are UTC+10, and Ponape and Kosrae are UTC+11. +# We don't know when Kosrae switched from UTC+12; assume January 1 for now. + + +# Midway + +# From Charles T O'Connor, KMTH DJ (1956), +# quoted in the KTMH section of the Radio Heritage Collection +# (2002-12-31): +# For the past two months we've been on what is known as Daylight +# Saving Time. This time has put us on air at 5am in the morning, +# your time down there in New Zealand. Starting September 2, 1956 +# we'll again go back to Standard Time. This'll mean that we'll go to +# air at 6am your time. +# +# From Paul Eggert (2003-03-23): +# We don't know the date of that quote, but we'll guess they +# started DST on June 3. Possibly DST was observed other years +# in Midway, but we have no record of it. + + +# Pitcairn + +# From Rives McDow (1999-11-08): +# A Proclamation was signed by the Governor of Pitcairn on the 27th March 1998 +# with regard to Pitcairn Standard Time. The Proclamation is as follows. +# +# The local time for general purposes in the Islands shall be +# Co-ordinated Universal time minus 8 hours and shall be known +# as Pitcairn Standard Time. +# +# ... I have also seen Pitcairn listed as UTC minus 9 hours in several +# references, and can only assume that this was an error in interpretation +# somehow in light of this proclamation. + +# From Rives McDow (1999-11-09): +# The Proclamation regarding Pitcairn time came into effect on 27 April 1998 +# ... at midnight. + +# From Howie Phelps (1999-11-10), who talked to a Pitcairner via shortwave: +# Betty Christian told me yesterday that their local time is the same as +# Pacific Standard Time. They used to be 1/2 hour different from us here in +# Sacramento but it was changed a couple of years ago. + + +# Samoa + +# Howse writes (p 153, citing p 10 of the 1883-11-18 New York Herald) +# that in 1879 the King of Samoa decided to change +# ``the date in his kingdom from the Antipodean to the American system, +# ordaining -- by a masterpiece of diplomatic flattery -- that +# the Fourth of July should be celebrated twice in that year.'' + + +# Tonga + +# From Paul Eggert (1996-01-22): +# Today's _Wall Street Journal_ (p 1) reports that ``Tonga has been plotting +# to sneak ahead of [New Zealanders] by introducing daylight-saving time.'' +# Since Kiribati has moved the Date Line it's not clear what Tonga will do. + +# Don Mundell writes in the 1997-02-20 Tonga Chronicle +# +# How Tonga became `The Land where Time Begins' +# : + +# Until 1941 Tonga maintained a standard time 50 minutes ahead of NZST +# 12 hours and 20 minutes ahead of GMT. When New Zealand adjusted its +# standard time in 1940s, Tonga had the choice of subtracting from its +# local time to come on the same standard time as New Zealand or of +# advancing its time to maintain the differential of 13 degrees +# (approximately 50 minutes ahead of New Zealand time). +# +# Because His Majesty King Taufa'ahau Tupou IV, then Crown Prince +# Tungi, preferred to ensure Tonga's title as the land where time +# begins, the Legislative Assembly approved the latter change. +# +# But some of the older, more conservative members from the outer +# islands objected. "If at midnight on Dec. 31, we move ahead 40 +# minutes, as your Royal Highness wishes, what becomes of the 40 +# minutes we have lost?" +# +# The Crown Prince, presented an unanswerable argument: "Remember that +# on the World Day of Prayer, you would be the first people on Earth +# to say your prayers in the morning." + +# From Paul Eggert (1999-08-12): +# Shanks says the transition was on 1968-10-01; go with Mundell. + +# From Eric Ulevik (1999-05-03): +# Tonga's director of tourism, who is also secretary of the National Millenium +# Committee, has a plan to get Tonga back in front. +# He has proposed a one-off move to tropical daylight saving for Tonga from +# October to March, which has won approval in principle from the Tongan +# Government. + +# From Steffen Thorsen [straen@thorsen.priv.no] (1999-09-09): +# * Tonga will introduce DST in November +# +# I was given this link by John Letts : +# +# http://news.bbc.co.uk/hi/english/world/asia-pacific/newsid_424000/424764.stm +# +# +# I have not been able to find exact dates for the transition in November +# yet. By reading this article it seems like Fiji will be 14 hours ahead +# of UTC as well, but as far as I know Fiji will only be 13 hours ahead +# (12 + 1 hour DST). + +# From Arthur David Olson [arthur_david_olson@nih.gov] (1999-09-20): +# According to (1999-10-29): +# A good source for time zone historical data outside the U.S. is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1991, +# and IATA SSIM is the source for entries afterwards. +# +# Other sources occasionally used include: +# +# Edward W. Whitman, World Time Differences, +# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), +# which I found in the UCLA library. +# +# +# William Willett, The Waste of Daylight, 19th edition +# (1914-03) +# +# Brazil's Departamento Servico da Hora (DSH), +# +# History of Summer Time +# (1998-09-21, in Portuguese) + +# +# I invented the abbreviations marked `*' in the following table; +# the rest are from earlier versions of this file, or from other sources. +# Corrections are welcome! +# std dst 2dst +# LMT Local Mean Time +# -4:00 AST ADT Atlantic +# -3:00 WGT WGST Western Greenland* +# -1:00 EGT EGST Eastern Greenland* +# 0:00 GMT BST BDST Greenwich, British Summer +# 0:00 GMT IST Greenwich, Irish Summer +# 0:00 WET WEST WEMT Western Europe +# 0:19:32.13 AMT NST Amsterdam, Netherlands Summer (1835-1937)* +# 0:20 NET NEST Netherlands (1937-1940)* +# 1:00 CET CEST CEMT Central Europe +# 1:00:14 SET Swedish (1879-1899)* +# 2:00 EET EEST Eastern Europe +# 3:00 MSK MSD Moscow +# +# A reliable and entertaining source about time zones, especially in Britain, +# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997). + +# From Peter Ilieve (1994-12-04), +# The original six [EU members]: Belgium, France, (West) Germany, Italy, +# Luxembourg, the Netherlands. +# Plus, from 1 Jan 73: Denmark, Ireland, United Kingdom. +# Plus, from 1 Jan 81: Greece. +# Plus, from 1 Jan 86: Spain, Portugal. +# Plus, from 1 Jan 95: Austria, Finland, Sweden. (Norway negotiated terms for +# entry but in a referendum on 28 Nov 94 the people voted No by 52.2% to 47.8% +# on a turnout of 88.6%. This was almost the same result as Norway's previous +# referendum in 1972, they are the only country to have said No twice. +# Referendums in the other three countries voted Yes.) +# ... +# Estonia ... uses EU dates but not at 01:00 GMT, they use midnight GMT. +# I don't think they know yet what they will do from 1996 onwards. +# ... +# There shouldn't be any [current members who are not using EU rules]. +# A Directive has the force of law, member states are obliged to enact +# national law to implement it. The only contentious issue was the +# different end date for the UK and Ireland, and this was always allowed +# in the Directive. + + +############################################################################### + +# Britain (United Kingdom) and Ireland (Eire) + +# From Peter Ilieve (1994-07-06): +# +# On 17 Jan 1994 the Independent, a UK quality newspaper, had a piece about +# historical vistas along the Thames in west London. There was a photo +# and a sketch map showing some of the sightlines involved. One paragraph +# of the text said: +# +# `An old stone obelisk marking a forgotten terrestrial meridian stands +# beside the river at Kew. In the 18th century, before time and longitude +# was standardised by the Royal Observatory in Greenwich, scholars observed +# this stone and the movement of stars from Kew Observatory nearby. They +# made their calculations and set the time for the Horse Guards and Parliament, +# but now the stone is obscured by scrubwood and can only be seen by walking +# along the towpath within a few yards of it.' +# +# I have a one inch to one mile map of London and my estimate of the stone's +# position is 51 deg. 28' 30" N, 0 deg. 18' 45" W. The longitude should +# be within about +-2". The Ordnance Survey grid reference is TQ172761. +# +# [This yields GMTOFF = -0:01:15 for London LMT in the 18th century.] + +# From Paul Eggert (1993-11-18): +# +# Howse writes that Britain was the first country to use standard time. +# The railways cared most about the inconsistencies of local mean time, +# and it was they who forced a uniform time on the country. +# The original idea was credited to Dr. William Hyde Wollaston (1766-1828) +# and was popularized by Abraham Follett Osler (1808-1903). +# The first railway to adopt London time was the Great Western Railway +# in November 1840; other railways followed suit, and by 1847 most +# (though not all) railways used London time. On 1847-09-22 the +# Railway Clearing House, an industry standards body, recommended that GMT be +# adopted at all stations as soon as the General Post Office permitted it. +# The transition occurred on 12-01 for the L&NW, the Caledonian, +# and presumably other railways; the January 1848 Bradshaw's lists many +# railways as using GMT. By 1855 the vast majority of public +# clocks in Britain were set to GMT (though some, like the great clock +# on Tom Tower at Christ Church, Oxford, were fitted with two minute hands, +# one for local time and one for GMT). The last major holdout was the legal +# system, which stubbornly stuck to local time for many years, leading +# to oddities like polls opening at 08:13 and closing at 16:13. +# The legal system finally switched to GMT when the Statutes (Definition +# of Time) Act took effect; it received the Royal Assent on 1880-08-02. +# +# In the tables below, we condense this complicated story into a single +# transition date for London, namely 1847-12-01. We don't know as much +# about Dublin, so we use 1880-08-02, the legal transition time. + +# From Paul Eggert (2003-09-27): +# Summer Time was first seriously proposed by William Willett (1857-1915), +# a London builder and member of the Royal Astronomical Society +# who circulated a pamphlet ``The Waste of Daylight'' (1907) +# that proposed advancing clocks 20 minutes on each of four Sundays in April, +# and retarding them by the same amount on four Sundays in September. +# A bill was drafted in 1909 and introduced in Parliament several times, +# but it met with ridicule and opposition, especially from farming interests. +# Later editions of the pamphlet proposed one-hour summer time, and +# it was eventually adopted as a wartime measure in 1916. +# See: Summer Time Arrives Early, The Times (2000-05-18). +# A monument to Willett was unveiled on 1927-05-21, in an open space in +# a 45-acre wood near Chislehurst, Kent that was purchased by popular +# subscription and open to the public. On the south face of the monolith, +# designed by G. W. Miller, is the the William Willett Memorial Sundial, +# which is permanently set to Summer Time. + +# From Winston Churchill (1934-04-28): +# It is one of the paradoxes of history that we should owe the boon of +# summer time, which gives every year to the people of this country +# between 160 and 170 hours more daylight leisure, to a war which +# plunged Europe into darkness for four years, and shook the +# foundations of civilization throughout the world. +# -- +# "A Silent Toast to William Willett", Pictorial Weekly +# + +# From Paul Eggert (1996-09-03): +# The OED Supplement says that the English originally said ``Daylight Saving'' +# when they were debating the adoption of DST in 1908; but by 1916 this +# term appears only in quotes taken from DST's opponents, whereas the +# proponents (who eventually won the argument) are quoted as using ``Summer''. + +# From Arthur David Olson (1989-01-19): +# +# A source at the British Information Office in New York avers that it's +# known as "British" Summer Time in all parts of the United Kingdom. + +# Date: 4 Jan 89 08:57:25 GMT (Wed) +# From: Jonathan Leffler +# [British Summer Time] is fixed annually by Act of Parliament. +# If you can predict what Parliament will do, you should be in +# politics making a fortune, not computing. + +# From Chris Carrier <72157.3334@CompuServe.COM> (1996-06-14): +# I remember reading in various wartime issues of the London Times the +# acronym BDST for British Double Summer Time. Look for the published +# time of sunrise and sunset in The Times, when BDST was in effect, and +# if you find a zone reference it will say, "All times B.D.S.T." + +# From Joseph S. Myers (1999-09-02): +# ... some military cables (WO 219/4100 - this is a copy from the +# main SHAEF archives held in the US National Archives, SHAEF/5252/8/516) +# agree that the usage is BDST (this appears in a message dated 17 Feb 1945). + +# From Joseph S. Myers (2000-10-03): +# On 18th April 1941, Sir Stephen Tallents of the BBC wrote to Sir +# Alexander Maxwell of the Home Office asking whether there was any +# official designation; the reply of the 21st was that there wasn't +# but he couldn't think of anything better than the "Double British +# Summer Time" that the BBC had been using informally. +# http://student.cusu.cam.ac.uk/~jsm28/british-time/bbc-19410418.png +# http://student.cusu.cam.ac.uk/~jsm28/british-time/ho-19410421.png + +# From Sir Alexander Maxwell in the above-mentioned letter (1941-04-21): +# [N]o official designation has as far as I know been adopted for the time +# which is to be introduced in May.... +# I cannot think of anything better than "Double British Summer Time" +# which could not be said to run counter to any official description. + +# From Paul Eggert (2000-10-02): +# Howse writes (p 157) `DBST' too, but `BDST' seems to have been common +# and follows the more usual convention of putting the location name first, +# so we use `BDST'. + +# Peter Ilieve (1998-04-19) described at length +# the history of summer time legislation in the United Kingdom. +# Since 1998 Joseph S. Myers has been updating +# and extending this list, which can be found in +# +# History of legal time in Britain +# + +# From Joseph S. Myers (1998-01-06): +# +# The legal time in the UK outside of summer time is definitely GMT, not UTC; +# see Lord Tanlaw's speech +# +# (Lords Hansard 11 June 1997 columns 964 to 976) +# . + +# From Paul Eggert (2001-07-18): +# +# For lack of other data, we'll follow Shanks for Eire in 1940-1948. +# +# Given Ilieve and Myers's data, the following claims by Shanks are incorrect: +# * Wales did not switch from GMT to daylight saving time until +# 1921 Apr 3, when they began to conform with the rest of Great Britain. +# Actually, Wales was identical after 1880. +# * Eire had two transitions on 1916 Oct 1. +# It actually just had one transition. +# * Northern Ireland used single daylight saving time throughout WW II. +# Actually, it conformed to Britain. +# * GB-Eire changed standard time to 1 hour ahead of GMT on 1968-02-18. +# Actually, that date saw the usual switch to summer time. +# Standard time was not changed until 1968-10-27 (the clocks didn't change). +# +# Here is another incorrect claim by Shanks: +# * Jersey, Guernsey, and the Isle of Man did not switch from GMT +# to daylight saving time until 1921 Apr 3, when they began to +# conform with Great Britain. +# S.R.&O. 1916, No. 382 and HO 45/10811/312364 (quoted above) say otherwise. +# +# The following claim by Shanks is possible though doubtful; +# we'll ignore it for now. +# * Dublin's 1971-10-31 switch was at 02:00, even though London's was 03:00. +# +# +# Whitman says Dublin Mean Time was -0:25:21, which is more precise than Shanks. +# Perhaps this was Dunsink Observatory Time, as Dunsink Observatory +# (8 km NW of Dublin's center) seemingly was to Dublin as Greenwich was +# to London. For example: +# +# "Timeball on the ballast office is down. Dunsink time." +# -- James Joyce, Ulysses + +# From Paul Eggert (1999-03-28): +# Clive Feather (, 1997-03-31) +# reports that Folkestone (Cheriton) Shuttle Terminal uses Concession Time +# (CT), equivalent to French civil time. +# Julian Hill (, 1998-09-30) reports that +# trains between Dollands Moor (the freight facility next door) +# and Frethun run in CT. +# My admittedly uninformed guess is that the terminal has two authorities, +# the French concession operators and the British civil authorities, +# and that the time depends on who you're talking to. +# If, say, the British police were called to the station for some reason, +# I would expect the official police report to use GMT/BST and not CET/CEST. +# This is a borderline case, but for now let's stick to GMT/BST. + +# From an anonymous contributor (1996-06-02): +# The law governing time in Ireland is under Statutory Instrument SI 395/94, +# which gives force to European Union 7th Council Directive # 94/21/EC. +# Under this directive, the Minister for Justice in Ireland makes appropriate +# regulations. I spoke this morning with the Secretary of the Department of +# Justice (tel +353 1 678 9711) who confirmed to me that the correct name is +# "Irish Summer Time", abbreviated to "IST". + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Summer Time Act, 1916 +Rule GB-Eire 1916 only - May 21 2:00s 1:00 BST +Rule GB-Eire 1916 only - Oct 1 2:00s 0 GMT +# S.R.&O. 1917, No. 358 +Rule GB-Eire 1917 only - Apr 8 2:00s 1:00 BST +Rule GB-Eire 1917 only - Sep 17 2:00s 0 GMT +# S.R.&O. 1918, No. 274 +Rule GB-Eire 1918 only - Mar 24 2:00s 1:00 BST +Rule GB-Eire 1918 only - Sep 30 2:00s 0 GMT +# S.R.&O. 1919, No. 297 +Rule GB-Eire 1919 only - Mar 30 2:00s 1:00 BST +Rule GB-Eire 1919 only - Sep 29 2:00s 0 GMT +# S.R.&O. 1920, No. 458 +Rule GB-Eire 1920 only - Mar 28 2:00s 1:00 BST +# S.R.&O. 1920, No. 1844 +Rule GB-Eire 1920 only - Oct 25 2:00s 0 GMT +# S.R.&O. 1921, No. 363 +Rule GB-Eire 1921 only - Apr 3 2:00s 1:00 BST +Rule GB-Eire 1921 only - Oct 3 2:00s 0 GMT +# S.R.&O. 1922, No. 264 +Rule GB-Eire 1922 only - Mar 26 2:00s 1:00 BST +Rule GB-Eire 1922 only - Oct 8 2:00s 0 GMT +# The Summer Time Act, 1922 +Rule GB-Eire 1923 only - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1923 1924 - Sep Sun>=16 2:00s 0 GMT +Rule GB-Eire 1924 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1925 1926 - Apr Sun>=16 2:00s 1:00 BST +# The Summer Time Act, 1925 +Rule GB-Eire 1925 1938 - Oct Sun>=2 2:00s 0 GMT +Rule GB-Eire 1927 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1928 1929 - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1930 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1931 1932 - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1933 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1934 only - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1935 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1936 1937 - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1938 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1939 only - Apr Sun>=16 2:00s 1:00 BST +# S.R.&O. 1939, No. 1379 +Rule GB-Eire 1939 only - Nov Sun>=16 2:00s 0 GMT +# S.R.&O. 1940, No. 172 and No. 1883 +Rule GB-Eire 1940 only - Feb Sun>=23 2:00s 1:00 BST +# S.R.&O. 1941, No. 476 +Rule GB-Eire 1941 only - May Sun>=2 1:00s 2:00 BDST +Rule GB-Eire 1941 1943 - Aug Sun>=9 1:00s 1:00 BST +# S.R.&O. 1942, No. 506 +Rule GB-Eire 1942 1944 - Apr Sun>=2 1:00s 2:00 BDST +# S.R.&O. 1944, No. 932 +Rule GB-Eire 1944 only - Sep Sun>=16 1:00s 1:00 BST +# S.R.&O. 1945, No. 312 +Rule GB-Eire 1945 only - Apr Mon>=2 1:00s 2:00 BDST +Rule GB-Eire 1945 only - Jul Sun>=9 1:00s 1:00 BST +# S.R.&O. 1945, No. 1208 +Rule GB-Eire 1945 1946 - Oct Sun>=2 2:00s 0 GMT +Rule GB-Eire 1946 only - Apr Sun>=9 2:00s 1:00 BST +# The Summer Time Act, 1947 +Rule GB-Eire 1947 only - Mar 16 2:00s 1:00 BST +Rule GB-Eire 1947 only - Apr 13 1:00s 2:00 BDST +Rule GB-Eire 1947 only - Aug 10 1:00s 1:00 BST +Rule GB-Eire 1947 only - Nov 2 2:00s 0 GMT +# Summer Time Order, 1948 (S.I. 1948/495) +Rule GB-Eire 1948 only - Mar 14 2:00s 1:00 BST +Rule GB-Eire 1948 only - Oct 31 2:00s 0 GMT +# Summer Time Order, 1949 (S.I. 1949/373) +Rule GB-Eire 1949 only - Apr 3 2:00s 1:00 BST +Rule GB-Eire 1949 only - Oct 30 2:00s 0 GMT +# Summer Time Order, 1950 (S.I. 1950/518) +# Summer Time Order, 1951 (S.I. 1951/430) +# Summer Time Order, 1952 (S.I. 1952/451) +Rule GB-Eire 1950 1952 - Apr Sun>=14 2:00s 1:00 BST +Rule GB-Eire 1950 1952 - Oct Sun>=21 2:00s 0 GMT +# revert to the rules of the Summer Time Act, 1925 +Rule GB-Eire 1953 only - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1953 1960 - Oct Sun>=2 2:00s 0 GMT +Rule GB-Eire 1954 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1955 1956 - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1957 only - Apr Sun>=9 2:00s 1:00 BST +Rule GB-Eire 1958 1959 - Apr Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1960 only - Apr Sun>=9 2:00s 1:00 BST +# Summer Time Order, 1961 (S.I. 1961/71) +# Summer Time (1962) Order, 1961 (S.I. 1961/2465) +# Summer Time Order, 1963 (S.I. 1963/81) +Rule GB-Eire 1961 1963 - Mar lastSun 2:00s 1:00 BST +Rule GB-Eire 1961 1968 - Oct Sun>=23 2:00s 0 GMT +# Summer Time (1964) Order, 1963 (S.I. 1963/2101) +# Summer Time Order, 1964 (S.I. 1964/1201) +# Summer Time Order, 1967 (S.I. 1967/1148) +Rule GB-Eire 1964 1967 - Mar Sun>=19 2:00s 1:00 BST +# Summer Time Order, 1968 (S.I. 1968/117) +Rule GB-Eire 1968 only - Feb 18 2:00s 1:00 BST +# The British Standard Time Act, 1968 +# (no summer time) +# The Summer Time Act, 1972 +Rule GB-Eire 1972 1980 - Mar Sun>=16 2:00s 1:00 BST +Rule GB-Eire 1972 1980 - Oct Sun>=23 2:00s 0 GMT +# Summer Time Order, 1980 (S.I. 1980/1089) +# Summer Time Order, 1982 (S.I. 1982/1673) +# Summer Time Order, 1986 (S.I. 1986/223) +# Summer Time Order, 1988 (S.I. 1988/931) +Rule GB-Eire 1981 1995 - Mar lastSun 1:00u 1:00 BST +Rule GB-Eire 1981 1989 - Oct Sun>=23 1:00u 0 GMT +# Summer Time Order, 1989 (S.I. 1989/985) +# Summer Time Order, 1992 (S.I. 1992/1729) +# Summer Time Order 1994 (S.I. 1994/2798) +Rule GB-Eire 1990 1995 - Oct Sun>=22 1:00u 0 GMT +# Summer Time Order 1997 (S.I. 1997/2982) +# See EU for rules starting in 1996. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/London -0:01:15 - LMT 1847 Dec 1 + 0:00 GB-Eire %s 1968 Oct 27 + 1:00 - BST 1971 Oct 31 2:00u + 0:00 GB-Eire %s 1996 + 0:00 EU GMT/BST +Zone Europe/Belfast -0:23:40 - LMT 1880 Aug 2 + -0:25:21 - DMT 1916 May 21 2:00 # Dublin/Dunsink MT + -0:25:21 1:00 IST 1916 Oct 1 2:00s # Irish Summer Time + 0:00 GB-Eire %s 1968 Oct 27 + 1:00 - BST 1971 Oct 31 2:00u + 0:00 GB-Eire %s 1996 + 0:00 EU GMT/BST +Zone Europe/Dublin -0:25:00 - LMT 1880 Aug 2 + -0:25:21 - DMT 1916 May 21 2:00 + -0:25:21 1:00 IST 1916 Oct 1 2:00s + 0:00 GB-Eire %s 1921 Dec 6 # independence + 0:00 GB-Eire GMT/IST 1940 Feb 25 2:00 + 0:00 1:00 IST 1946 Oct 6 2:00 + 0:00 - GMT 1947 Mar 16 2:00 + 0:00 1:00 IST 1947 Nov 2 2:00 + 0:00 - GMT 1948 Apr 18 2:00 + 0:00 GB-Eire GMT/IST 1968 Oct 27 + 1:00 - IST 1971 Oct 31 2:00u + 0:00 GB-Eire GMT/IST 1996 + 0:00 EU GMT/IST + +############################################################################### + +# Continental Europe + +# EU rules are for the European Union, previously known as the EC, EEC, +# Common Market, etc. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule EU 1977 1980 - Apr Sun>=1 1:00u 1:00 S +Rule EU 1977 only - Sep lastSun 1:00u 0 - +Rule EU 1978 only - Oct 1 1:00u 0 - +Rule EU 1979 1995 - Sep lastSun 1:00u 0 - +Rule EU 1981 max - Mar lastSun 1:00u 1:00 S +Rule EU 1996 max - Oct lastSun 1:00u 0 - +# The most recent directive covers the years starting in 2002. See: +# + +# W-Eur differs from EU only in that W-Eur uses standard time. +Rule W-Eur 1977 1980 - Apr Sun>=1 1:00s 1:00 S +Rule W-Eur 1977 only - Sep lastSun 1:00s 0 - +Rule W-Eur 1978 only - Oct 1 1:00s 0 - +Rule W-Eur 1979 1995 - Sep lastSun 1:00s 0 - +Rule W-Eur 1981 max - Mar lastSun 1:00s 1:00 S +Rule W-Eur 1996 max - Oct lastSun 1:00s 0 - + +# Older C-Eur rules are for convenience in the tables. +# From 1977 on, C-Eur differs from EU only in that C-Eur uses standard time. +Rule C-Eur 1916 only - Apr 30 23:00 1:00 S +Rule C-Eur 1916 only - Oct 1 1:00 0 - +Rule C-Eur 1917 1918 - Apr Mon>=15 2:00s 1:00 S +Rule C-Eur 1917 1918 - Sep Mon>=15 2:00s 0 - +Rule C-Eur 1940 only - Apr 1 2:00s 1:00 S +Rule C-Eur 1942 only - Nov 2 2:00s 0 - +Rule C-Eur 1943 only - Mar 29 2:00s 1:00 S +Rule C-Eur 1943 only - Oct 4 2:00s 0 - +Rule C-Eur 1944 only - Apr 3 2:00s 1:00 S +# Whitman gives 1944 Oct 7; go with Shanks. +Rule C-Eur 1944 only - Oct 2 2:00s 0 - +Rule C-Eur 1977 1980 - Apr Sun>=1 2:00s 1:00 S +Rule C-Eur 1977 only - Sep lastSun 2:00s 0 - +Rule C-Eur 1978 only - Oct 1 2:00s 0 - +Rule C-Eur 1979 1995 - Sep lastSun 2:00s 0 - +Rule C-Eur 1981 max - Mar lastSun 2:00s 1:00 S +Rule C-Eur 1996 max - Oct lastSun 2:00s 0 - + +# E-Eur differs from EU only in that E-Eur switches at midnight local time. +Rule E-Eur 1977 1980 - Apr Sun>=1 0:00 1:00 S +Rule E-Eur 1977 only - Sep lastSun 0:00 0 - +Rule E-Eur 1978 only - Oct 1 0:00 0 - +Rule E-Eur 1979 1995 - Sep lastSun 0:00 0 - +Rule E-Eur 1981 max - Mar lastSun 0:00 1:00 S +Rule E-Eur 1996 max - Oct lastSun 0:00 0 - + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Russia 1917 only - Jul 1 23:00 1:00 MST # Moscow Summer Time +Rule Russia 1917 only - Dec 28 0:00 0 MMT # Moscow Mean Time +Rule Russia 1918 only - May 31 22:00 2:00 MDST # Moscow Double Summer Time +Rule Russia 1918 only - Sep 16 1:00 1:00 MST +Rule Russia 1919 only - May 31 23:00 2:00 MDST +Rule Russia 1919 only - Jul 1 2:00 1:00 S +Rule Russia 1919 only - Aug 16 0:00 0 - +Rule Russia 1921 only - Feb 14 23:00 1:00 S +Rule Russia 1921 only - Mar 20 23:00 2:00 M # Midsummer +Rule Russia 1921 only - Sep 1 0:00 1:00 S +Rule Russia 1921 only - Oct 1 0:00 0 - +# Act No.925 of the Council of Ministers of the USSR (1980-10-24): +Rule Russia 1981 1984 - Apr 1 0:00 1:00 S +Rule Russia 1981 1983 - Oct 1 0:00 0 - +# Act No.967 of the Council of Ministers of the USSR (1984-09-13), repeated in +# Act No.227 of the Council of Ministers of the USSR (1989-03-14): +Rule Russia 1984 1991 - Sep lastSun 2:00s 0 - +Rule Russia 1985 1991 - Mar lastSun 2:00s 1:00 S +# +Rule Russia 1992 only - Mar lastSat 23:00 1:00 S +Rule Russia 1992 only - Sep lastSat 23:00 0 - +Rule Russia 1993 max - Mar lastSun 2:00s 1:00 S +Rule Russia 1993 1995 - Sep lastSun 2:00s 0 - +Rule Russia 1996 max - Oct lastSun 2:00s 0 - + +# These are for backward compatibility with older versions. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone WET 0:00 EU WE%sT +Zone CET 1:00 C-Eur CE%sT +Zone MET 1:00 C-Eur ME%sT +Zone EET 2:00 EU EE%sT + +# Previous editions of this database used abbreviations like MET DST +# for Central European Summer Time, but this didn't agree with common usage. + +# From Markus Kuhn (1996-07-12): +# The official German names ... are +# +# Mitteleuropaeische Zeit (MEZ) = UTC+01:00 +# Mitteleuropaeische Sommerzeit (MESZ) = UTC+02:00 +# +# as defined in the German Time Act (Gesetz ueber die Zeitbestimmung (ZeitG), +# 1978-07-25, Bundesgesetzblatt, Jahrgang 1978, Teil I, S. 1110-1111).... +# I wrote ... to the German Federal Physical-Technical Institution +# +# Physikalisch-Technische Bundesanstalt (PTB) +# Laboratorium 4.41 "Zeiteinheit" +# Postfach 3345 +# D-38023 Braunschweig +# phone: +49 531 592-0 +# +# ... I received today an answer letter from Dr. Peter Hetzel, head of the PTB +# department for time and frequency transmission. He explained that the +# PTB translates MEZ and MESZ into English as +# +# Central European Time (CET) = UTC+01:00 +# Central European Summer Time (CEST) = UTC+02:00 + + +# Albania +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Albania 1940 only - Jun 16 0:00 1:00 S +Rule Albania 1942 only - Nov 2 3:00 0 - +Rule Albania 1943 only - Mar 29 2:00 1:00 S +Rule Albania 1943 only - Apr 10 3:00 0 - +Rule Albania 1974 only - May 4 0:00 1:00 S +Rule Albania 1974 only - Oct 2 0:00 0 - +Rule Albania 1975 only - May 1 0:00 1:00 S +Rule Albania 1975 only - Oct 2 0:00 0 - +Rule Albania 1976 only - May 2 0:00 1:00 S +Rule Albania 1976 only - Oct 3 0:00 0 - +Rule Albania 1977 only - May 8 0:00 1:00 S +Rule Albania 1977 only - Oct 2 0:00 0 - +Rule Albania 1978 only - May 6 0:00 1:00 S +Rule Albania 1978 only - Oct 1 0:00 0 - +Rule Albania 1979 only - May 5 0:00 1:00 S +Rule Albania 1979 only - Sep 30 0:00 0 - +Rule Albania 1980 only - May 3 0:00 1:00 S +Rule Albania 1980 only - Oct 4 0:00 0 - +Rule Albania 1981 only - Apr 26 0:00 1:00 S +Rule Albania 1981 only - Sep 27 0:00 0 - +Rule Albania 1982 only - May 2 0:00 1:00 S +Rule Albania 1982 only - Oct 3 0:00 0 - +Rule Albania 1983 only - Apr 18 0:00 1:00 S +Rule Albania 1983 only - Oct 1 0:00 0 - +Rule Albania 1984 only - Apr 1 0:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Tirane 1:19:20 - LMT 1914 + 1:00 - CET 1940 Jun 16 + 1:00 Albania CE%sT 1984 Jul + 1:00 EU CE%sT + +# Andorra +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Andorra 0:06:04 - LMT 1901 + 0:00 - WET 1946 Sep 30 + 1:00 - CET 1985 Mar 31 2:00 + 1:00 EU CE%sT + +# Austria + +# From Paul Eggert (2003-02-28): Shanks gives 1918-06-16 and +# 1945-11-18, but the Austrian Federal Office of Metrology and +# Surveying (BEV) gives 1918-09-16 and for Vienna gives the "alleged" +# date of 1945-04-12 with no time. For the 1980-04-06 transition +# Shanks gives 02:00, the BEV 00:00. Go with the BEV, and guess 02:00 +# for 1945-04-12. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Austria 1920 only - Apr 5 2:00s 1:00 S +Rule Austria 1920 only - Sep 13 2:00s 0 - +Rule Austria 1946 only - Apr 14 2:00s 1:00 S +Rule Austria 1946 1948 - Oct Sun>=1 2:00s 0 - +Rule Austria 1947 only - Apr 6 2:00s 1:00 S +Rule Austria 1948 only - Apr 18 2:00s 1:00 S +Rule Austria 1980 only - Apr 6 0:00 1:00 S +Rule Austria 1980 only - Sep 28 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Vienna 1:05:20 - LMT 1893 Apr + 1:00 C-Eur CE%sT 1920 + 1:00 Austria CE%sT 1940 Apr 1 2:00s + 1:00 C-Eur CE%sT 1945 Apr 2 2:00s + 1:00 1:00 CEST 1945 Apr 12 2:00s + 1:00 - CET 1946 + 1:00 Austria CE%sT 1981 + 1:00 EU CE%sT + +# Belarus +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Minsk 1:50:16 - LMT 1880 + 1:50 - MMT 1924 May 2 # Minsk Mean Time + 2:00 - EET 1930 Jun 21 + 3:00 - MSK 1941 Jun 28 + 1:00 C-Eur CE%sT 1944 Jul 3 + 3:00 Russia MSK/MSD 1990 + 3:00 - MSK 1991 Mar 31 2:00s + 2:00 1:00 EEST 1991 Sep 29 2:00s + 2:00 - EET 1992 Mar 29 0:00s + 2:00 1:00 EEST 1992 Sep 27 0:00s + 2:00 Russia EE%sT + +# Belgium +# +# From Paul Eggert (1997-07-02): +# Entries from 1918 through 1991 are taken from: +# Annuaire de L'Observatoire Royal de Belgique, +# Avenue Circulaire, 3, B-1180 BRUXELLES, CLVIIe annee, 1991 +# (Imprimerie HAYEZ, s.p.r.l., Rue Fin, 4, 1080 BRUXELLES, MCMXC), +# pp 8-9. +# LMT before 1892 was 0:17:30, according to the official journal of Belgium: +# Moniteur Belge, Samedi 30 Avril 1892, N.121. +# Thanks to Pascal Delmoitie for these references. +# The 1918 rules are listed for completeness; they apply to unoccupied Belgium. +# Assume Brussels switched to WET in 1918 when the armistice took effect. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Belgium 1918 only - Mar 9 0:00s 1:00 S +Rule Belgium 1918 1919 - Oct Sat>=1 23:00s 0 - +Rule Belgium 1919 only - Mar 1 23:00s 1:00 S +Rule Belgium 1920 only - Feb 14 23:00s 1:00 S +Rule Belgium 1920 only - Oct 23 23:00s 0 - +Rule Belgium 1921 only - Mar 14 23:00s 1:00 S +Rule Belgium 1921 only - Oct 25 23:00s 0 - +Rule Belgium 1922 only - Mar 25 23:00s 1:00 S +Rule Belgium 1922 1927 - Oct Sat>=1 23:00s 0 - +Rule Belgium 1923 only - Apr 21 23:00s 1:00 S +Rule Belgium 1924 only - Mar 29 23:00s 1:00 S +Rule Belgium 1925 only - Apr 4 23:00s 1:00 S +# DSH writes that a royal decree of 1926-02-22 specified the Sun following 3rd +# Sat in Apr (except if it's Easter, in which case it's one Sunday earlier), +# to Sun following 1st Sat in Oct, and that a royal decree of 1928-09-15 +# changed the transition times to 02:00 GMT. +Rule Belgium 1926 only - Apr 17 23:00s 1:00 S +Rule Belgium 1927 only - Apr 9 23:00s 1:00 S +Rule Belgium 1928 only - Apr 14 23:00s 1:00 S +Rule Belgium 1928 1938 - Oct Sun>=2 2:00s 0 - +Rule Belgium 1929 only - Apr 21 2:00s 1:00 S +Rule Belgium 1930 only - Apr 13 2:00s 1:00 S +Rule Belgium 1931 only - Apr 19 2:00s 1:00 S +Rule Belgium 1932 only - Apr 3 2:00s 1:00 S +Rule Belgium 1933 only - Mar 26 2:00s 1:00 S +Rule Belgium 1934 only - Apr 8 2:00s 1:00 S +Rule Belgium 1935 only - Mar 31 2:00s 1:00 S +Rule Belgium 1936 only - Apr 19 2:00s 1:00 S +Rule Belgium 1937 only - Apr 4 2:00s 1:00 S +Rule Belgium 1938 only - Mar 27 2:00s 1:00 S +Rule Belgium 1939 only - Apr 16 2:00s 1:00 S +Rule Belgium 1939 only - Nov 19 2:00s 0 - +Rule Belgium 1940 only - Feb 25 2:00s 1:00 S +Rule Belgium 1944 only - Sep 17 2:00s 0 - +Rule Belgium 1945 only - Apr 2 2:00s 1:00 S +Rule Belgium 1945 only - Sep 16 2:00s 0 - +Rule Belgium 1946 only - May 19 2:00s 1:00 S +Rule Belgium 1946 only - Oct 7 2:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Brussels 0:17:30 - LMT 1880 + 0:17:30 - BMT 1892 May 1 12:00 # Brussels MT + 0:00 - WET 1914 Nov 8 + 1:00 - CET 1916 May 1 0:00 + 1:00 C-Eur CE%sT 1918 Nov 11 11:00u + 0:00 Belgium WE%sT 1940 May 20 2:00s + 1:00 C-Eur CE%sT 1944 Sep 3 + 1:00 Belgium CE%sT 1977 + 1:00 EU CE%sT + +# Bosnia and Herzegovina +# see Serbia and Montenegro + +# Bulgaria +# +# From Plamen Simenov via Steffen Thorsen (1999-09-09): +# A document of Government of Bulgaria (No.94/1997) says: +# EET --> EETDST is in 03:00 Local time in last Sunday of March ... +# EETDST --> EET is in 04:00 Local time in last Sunday of October +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Bulg 1979 only - Mar 31 23:00 1:00 S +Rule Bulg 1979 only - Oct 1 1:00 0 - +Rule Bulg 1980 1982 - Apr Sat<=7 23:00 1:00 S +Rule Bulg 1980 only - Sep 29 1:00 0 - +Rule Bulg 1981 only - Sep 27 2:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Sofia 1:33:16 - LMT 1880 + 1:56:56 - IMT 1894 Nov 30 # Istanbul MT? + 2:00 - EET 1942 Nov 2 3:00 + 1:00 C-Eur CE%sT 1945 Apr 2 3:00 + 2:00 - EET 1979 Mar 31 23:00 + 2:00 Bulg EE%sT 1982 Sep 26 2:00 + 2:00 C-Eur EE%sT 1991 + 2:00 E-Eur EE%sT 1997 + 2:00 EU EE%sT + +# Croatia +# see Serbia and Montenegro + +# Czech Republic +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Czech 1945 only - Apr 8 2:00s 1:00 S +Rule Czech 1945 only - Nov 18 2:00s 0 - +Rule Czech 1946 only - May 6 2:00s 1:00 S +Rule Czech 1946 1949 - Oct Sun>=1 2:00s 0 - +Rule Czech 1947 only - Apr 20 2:00s 1:00 S +Rule Czech 1948 only - Apr 18 2:00s 1:00 S +Rule Czech 1949 only - Apr 9 2:00s 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Prague 0:57:44 - LMT 1850 + 0:57:44 - PMT 1891 Oct # Prague Mean Time + 1:00 C-Eur CE%sT 1944 Sep 17 2:00s + 1:00 Czech CE%sT 1979 + 1:00 EU CE%sT + +# Denmark, Faeroe Islands, and Greenland +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Denmark 1916 only - May 14 23:00 1:00 S +Rule Denmark 1916 only - Sep 30 23:00 0 - +Rule Denmark 1940 only - May 15 0:00 1:00 S +Rule Denmark 1945 only - Apr 2 2:00s 1:00 S +Rule Denmark 1945 only - Aug 15 2:00s 0 - +Rule Denmark 1946 only - May 1 2:00s 1:00 S +Rule Denmark 1946 only - Sep 1 2:00s 0 - +Rule Denmark 1947 only - May 4 2:00s 1:00 S +Rule Denmark 1947 only - Aug 10 2:00s 0 - +Rule Denmark 1948 only - May 9 2:00s 1:00 S +Rule Denmark 1948 only - Aug 8 2:00s 0 - +# Whitman also gives 1949 Apr 9 to 1949 Oct 1, and disagrees in minor ways +# about many of the above dates; go with Shanks. +# +# For 1894, Shanks says Jan, Whitman Apr; go with Whitman. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Copenhagen 0:50:20 - LMT 1890 + 0:50:20 - CMT 1894 Apr # Copenhagen Mean Time + 1:00 Denmark CE%sT 1942 Nov 2 2:00s + 1:00 C-Eur CE%sT 1945 Apr 2 2:00 + 1:00 Denmark CE%sT 1980 + 1:00 EU CE%sT +Zone Atlantic/Faeroe -0:27:04 - LMT 1908 Jan 11 # Torshavn + 0:00 - WET 1981 + 0:00 EU WE%sT +# +# From Paul Eggert (1996-11-22): +# Greenland joined the EU as part of Denmark, obtained home rule on 1979-05-01, +# and left the EU on 1985-02-01. It therefore should have been using EU +# rules at least through 1984. Shanks says Scoresbysund and Godthab +# used C-Eur rules after 1980, but IATA SSIM (1991/1996) says they use EU +# rules since at least 1991. Assume EU rules since 1980. + +# From Gwillin Law (2001-06-06), citing +# (2001-03-15), +# and with translations corrected by Steffen Thorsen: +# +# Greenland has four local times, and the relation to UTC +# is according to the following time line: +# +# The military zone near Thule UTC-4 +# Standard Greenland time UTC-3 +# Scoresbysund UTC-1 +# Danmarkshavn UTC +# +# In the military area near Thule and in Danmarkshavn DST will not be +# introduced. + +# From Rives McDow (2001-11-01): +# +# I correspond regularly with the Dansk Polarcenter, and wrote them at +# the time to clarify the situation in Thule. Unfortunately, I have +# not heard back from them regarding my recent letter. [But I have +# info from earlier correspondence.] +# +# According to the center, a very small local time zone around Thule +# Air Base keeps the time according to UTC-4, implementing daylight +# savings using North America rules, changing the time at 02:00 local time.... +# +# The east coast of Greenland north of the community of Scoresbysund +# uses UTC in the same way as in Iceland, year round, with no dst. +# There are just a few stations on this coast, including the +# Danmarkshavn ICAO weather station mentioned in your September 29th +# email. The other stations are two sledge patrol stations in +# Mestersvig and Daneborg, the air force base at Station Nord, and the +# DPC research station at Zackenberg. +# +# Scoresbysund and two small villages nearby keep time UTC-1 and use +# the same daylight savings time period as in West Greenland (Godthab). +# +# The rest of Greenland, including Godthab (this area, although it +# includes central Greenland, is known as west Greenland), keeps time +# UTC-3, with daylight savings methods according to European rules. +# +# It is common procedure to use UTC 0 in the wilderness of East and +# North Greenland, because it is mainly Icelandic aircraft operators +# maintaining traffic in these areas. However, the official status of +# this area is that it sticks with Godthab time. This area might be +# considered a dual time zone in some respects because of this. + +# From Rives McDow (2001-11-19): +# I heard back from someone stationed at Thule; the time change took place +# there at 2:00 AM. + +# From Paul Eggert (2001-11-19): +# The 1997 CIA map shows Danmarkshavn on GMT; the 1995 map as like Godthab. +# For lack of better info, assume they were like Godthab before 1996. +# startkart.no says Thule does not observe DST, but this is clearly an error, +# so go with Shanks for all Thule transitions. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Thule 1991 1992 - Mar lastSun 2:00 1:00 D +Rule Thule 1991 1992 - Sep lastSun 2:00 0 S +Rule Thule 1993 max - Apr Sun>=1 2:00 1:00 D +Rule Thule 1993 max - Oct lastSun 2:00 0 S +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Danmarkshavn -1:14:40 - LMT 1916 Jul 28 + -3:00 - WGT 1980 Apr 6 2:00 + -3:00 EU WG%sT 1996 + 0:00 - GMT +Zone America/Scoresbysund -1:29:00 - LMT 1916 Jul 28 # Ittoqqortoormiit + -2:00 - CGT 1980 Apr 6 2:00 + -2:00 C-Eur CG%sT 1981 Mar 29 + -1:00 EU EG%sT +Zone America/Godthab -3:26:56 - LMT 1916 Jul 28 # Nuuk + -3:00 - WGT 1980 Apr 6 2:00 + -3:00 EU WG%sT +Zone America/Thule -4:35:08 - LMT 1916 Jul 28 # Pituffik air base + -4:00 Thule A%sT + +# Estonia +# From Peter Ilieve (1994-10-15): +# A relative in Tallinn confirms the accuracy of the data for 1989 onwards +# [through 1994] and gives the legal authority for it, +# a regulation of the Government of Estonia, No. 111 of 1989.... +# +# From Peter Ilieve (1996-10-28): +# [IATA SSIM (1992/1996) claims that the Baltic republics switch at 01:00s, +# but a relative confirms that Estonia still switches at 02:00s, writing:] +# ``I do not [know] exactly but there are some little different +# (confusing) rules for International Air and Railway Transport Schedules +# conversion in Sunday connected with end of summer time in Estonia.... +# A discussion is running about the summer time efficiency and effect on +# human physiology. It seems that Estonia maybe will not change to +# summer time next spring.'' + +# From Peter Ilieve (1998-11-04), heavily edited: +# +# The 1998-09-22 Estonian time law +# +# refers to the Eighth Directive and cites the association agreement between +# the EU and Estonia, ratified by the Estonian law (RT II 1995, 22--27, 120). +# +# I also asked [my relative] whether they use any standard abbreviation +# for their standard and summer times. He says no, they use "suveaeg" +# (summer time) and "talveaeg" (winter time). + +# From The Baltic Times (1999-09-09) +# via Steffen Thorsen: +# This year will mark the last time Estonia shifts to summer time, +# a council of the ruling coalition announced Sept. 6.... +# But what this could mean for Estonia's chances of joining the European +# Union are still unclear. In 1994, the EU declared summer time compulsory +# for all member states until 2001. Brussels has yet to decide what to do +# after that. + +# From Mart Oruaas (2000-01-29): +# Regulation no. 301 (1999-10-12) obsoletes previous regulation +# no. 206 (1998-09-22) and thus sticks Estonia to +02:00 GMT for all +# the year round. The regulation is effective 1999-11-01. + +# From Toomas Soome (2002-02-21): +# The Estonian government has changed once again timezone politics. +# Now we are using again EU rules. +# +# From Urmet Jaanes (2002-03-28): +# The legislative reference is Government decree No. 84 on 2002-02-21. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Tallinn 1:39:00 - LMT 1880 + 1:39:00 - TMT 1918 Feb # Tallinn Mean Time + 1:00 C-Eur CE%sT 1919 Jul + 1:39:00 - TMT 1921 May + 2:00 - EET 1940 Aug 6 + 3:00 - MSK 1941 Sep 15 + 1:00 C-Eur CE%sT 1944 Sep 22 + 3:00 Russia MSK/MSD 1989 Mar 26 2:00s + 2:00 1:00 EEST 1989 Sep 24 2:00s + 2:00 C-Eur EE%sT 1998 Sep 22 + 2:00 EU EE%sT 1999 Nov 1 + 2:00 - EET 2002 Feb 21 + 2:00 EU EE%sT + +# Finland +# +# From Hannu Strang (25 Sep 1994 06:03:37 UTC): +# Well, here in Helsinki we're just changing from summer time to regular one, +# and it's supposed to change at 4am... +# +# From Paul Eggert (25 Sep 1994): +# Shanks says Finland has switched at 02:00 standard time since 1981. +# Go with Strang instead. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Finland 1942 only - Apr 3 0:00 1:00 S +Rule Finland 1942 only - Oct 3 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Helsinki 1:39:52 - LMT 1878 May 31 + 1:39:52 - HMT 1921 May # Helsinki Mean Time + 2:00 Finland EE%sT 1981 Mar 29 2:00 + 2:00 EU EE%sT + +# France + +# From Ciro Discepolo (2000-12-20): +# +# Henri Le Corre, Regimes Horaires pour le monde entier, Editions +# Traditionnelles - Paris 2 books, 1993 +# +# Gabriel, Traite de l'heure dans le monde, Guy Tredaniel editeur, +# Paris, 1991 +# +# Francoise Gauquelin, Problemes de l'heure resolus en astrologie, +# Guy tredaniel, Paris 1987 + + +# +# Shanks seems to use `24:00' ambiguously; we resolve it with Whitman. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule France 1916 only - Jun 14 23:00s 1:00 S +Rule France 1916 1919 - Oct Sun>=1 23:00s 0 - +Rule France 1917 only - Mar 24 23:00s 1:00 S +Rule France 1918 only - Mar 9 23:00s 1:00 S +Rule France 1919 only - Mar 1 23:00s 1:00 S +Rule France 1920 only - Feb 14 23:00s 1:00 S +Rule France 1920 only - Oct 23 23:00s 0 - +Rule France 1921 only - Mar 14 23:00s 1:00 S +Rule France 1921 only - Oct 25 23:00s 0 - +Rule France 1922 only - Mar 25 23:00s 1:00 S +# DSH writes that a law of 1923-05-24 specified 3rd Sat in Apr at 23:00 to 1st +# Sat in Oct at 24:00; and that in 1930, because of Easter, the transitions +# were Apr 12 and Oct 5. Go with Shanks. +Rule France 1922 1938 - Oct Sat>=1 23:00s 0 - +Rule France 1923 only - May 26 23:00s 1:00 S +Rule France 1924 only - Mar 29 23:00s 1:00 S +Rule France 1925 only - Apr 4 23:00s 1:00 S +Rule France 1926 only - Apr 17 23:00s 1:00 S +Rule France 1927 only - Apr 9 23:00s 1:00 S +Rule France 1928 only - Apr 14 23:00s 1:00 S +Rule France 1929 only - Apr 20 23:00s 1:00 S +Rule France 1930 only - Apr 12 23:00s 1:00 S +Rule France 1931 only - Apr 18 23:00s 1:00 S +Rule France 1932 only - Apr 2 23:00s 1:00 S +Rule France 1933 only - Mar 25 23:00s 1:00 S +Rule France 1934 only - Apr 7 23:00s 1:00 S +Rule France 1935 only - Mar 30 23:00s 1:00 S +Rule France 1936 only - Apr 18 23:00s 1:00 S +Rule France 1937 only - Apr 3 23:00s 1:00 S +Rule France 1938 only - Mar 26 23:00s 1:00 S +Rule France 1939 only - Apr 15 23:00s 1:00 S +Rule France 1939 only - Nov 18 23:00s 0 - +Rule France 1940 only - Feb 25 2:00 1:00 S +# The French rules for 1941-1944 were not used in Paris, but Shanks writes +# that they were used in Monaco and in many French locations. +# Le Corre writes that the upper limit of the free zone was Arneguy, Orthez, +# Mont-de-Marsan, Bazas, Langon, Lamotte-Montravel, Marouil, La +# Rochefoucault, Champagne-Mouton, La Roche-Posay, La Haye-Decartes, +# Loches, Montrichard, Vierzon, Bourges, Moulins, Digoin, +# Paray-le-Monial, Montceau-les-Mines, Chalons-sur-Saone, Arbois, +# Dole, Morez, St-Claude, and Collognes (Haute-Savioe). +Rule France 1941 only - May 5 0:00 2:00 M # Midsummer +# Shanks says this transition occurred at Oct 6 1:00, +# but go with Denis.Excoffier@ens.fr (1997-12-12), +# who quotes the Ephemerides Astronomiques for 1998 from Bureau des Longitudes +# as saying 5/10/41 22hUT. +Rule France 1941 only - Oct 6 0:00 1:00 S +Rule France 1942 only - Mar 9 0:00 2:00 M +Rule France 1942 only - Nov 2 3:00 1:00 S +Rule France 1943 only - Mar 29 2:00 2:00 M +Rule France 1943 only - Oct 4 3:00 1:00 S +Rule France 1944 only - Apr 3 2:00 2:00 M +Rule France 1944 only - Oct 8 1:00 1:00 S +Rule France 1945 only - Apr 2 2:00 2:00 M +Rule France 1945 only - Sep 16 3:00 0 - +# Shanks gives Mar 28 2:00 and Sep 26 3:00; +# go with Excoffier's 28/3/76 0hUT and 25/9/76 23hUT. +Rule France 1976 only - Mar 28 1:00 1:00 S +Rule France 1976 only - Sep 26 1:00 0 - +# Shanks gives 0:09 for Paris Mean Time, and Whitman gives 0:09:05, +# but Howse quotes the actual French legislation as saying 0:09:21. +# Go with Howse. Howse writes that the time in France was officially based +# on PMT-0:09:21 until 1978-08-09, when the time base finally switched to UTC. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Paris 0:09:21 - LMT 1891 Mar 15 0:01 + 0:09:21 - PMT 1911 Mar 11 0:01 # Paris MT +# Shanks gives 1940 Jun 14 0:00; go with Excoffier and Le Corre. + 0:00 France WE%sT 1940 Jun 14 23:00 +# Le Corre says Paris stuck with occupied-France time after the liberation; +# go with Shanks. + 1:00 C-Eur CE%sT 1944 Aug 25 + 0:00 France WE%sT 1945 Sep 16 3:00 + 1:00 France CE%sT 1977 + 1:00 EU CE%sT + +# Germany + +# From Markus Kuhn (1998-09-29): +# The German time zone web site by the Physikalisch-Technische +# Bundesanstalt contains DST information back to 1916. +# [See tz-link.htm for the URL.] + +# From Joerg Schilling (2002-10-23): +# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by +# General [Nikolai] Bersarin. + +# From Paul Eggert (2003-03-08): +# +# says that Bersarin issued an order to use Moscow time on May 20. +# However, Moscow did not observe daylight saving in 1945, so +# this was equivalent to CEMT (GMT+3), not GMT+4. + + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Germany 1945 only - Apr 2 2:00s 1:00 S +Rule Germany 1945 only - May 24 2:00 2:00 M # Midsummer +Rule Germany 1945 only - Sep 24 3:00 1:00 S +Rule Germany 1945 only - Nov 18 2:00s 0 - +Rule Germany 1946 only - Apr 14 2:00s 1:00 S +Rule Germany 1946 only - Oct 7 2:00s 0 - +Rule Germany 1947 1949 - Oct Sun>=1 2:00s 0 - +Rule Germany 1947 only - Apr 6 2:00s 1:00 S +Rule Germany 1947 only - May 11 2:00s 2:00 M +Rule Germany 1947 only - Jun 29 3:00 1:00 S +Rule Germany 1948 only - Apr 18 2:00s 1:00 S +Rule Germany 1949 only - Apr 10 2:00s 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Berlin 0:53:28 - LMT 1893 Apr + 1:00 C-Eur CE%sT 1945 Apr 2 2:00 + 1:00 Germany CE%sT 1980 + 1:00 EU CE%sT + +# Gibraltar +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Gibraltar -0:21:24 - LMT 1880 Aug 2 + 0:00 GB-Eire %s 1957 Apr 14 2:00 + 1:00 - CET 1982 + 1:00 EU CE%sT + +# Greece +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Whitman gives 1932 Jul 5 - Nov 1; go with Shanks. +Rule Greece 1932 only - Jul 7 0:00 1:00 S +Rule Greece 1932 only - Sep 1 0:00 0 - +# Whitman gives 1941 Apr 25 - ?; go with Shanks. +Rule Greece 1941 only - Apr 7 0:00 1:00 S +# Whitman gives 1942 Feb 2 - ?; go with Shanks. +Rule Greece 1942 only - Nov 2 3:00 0 - +Rule Greece 1943 only - Mar 30 0:00 1:00 S +Rule Greece 1943 only - Oct 4 0:00 0 - +# Whitman gives 1944 Oct 3 - Oct 31; go with Shanks. +Rule Greece 1952 only - Jul 1 0:00 1:00 S +Rule Greece 1952 only - Nov 2 0:00 0 - +Rule Greece 1975 only - Apr 12 0:00s 1:00 S +Rule Greece 1975 only - Nov 26 0:00s 0 - +Rule Greece 1976 only - Apr 11 2:00s 1:00 S +Rule Greece 1976 only - Oct 10 2:00s 0 - +Rule Greece 1977 1978 - Apr Sun>=1 2:00s 1:00 S +Rule Greece 1977 only - Sep 26 2:00s 0 - +Rule Greece 1978 only - Sep 24 4:00 0 - +Rule Greece 1979 only - Apr 1 9:00 1:00 S +Rule Greece 1979 only - Sep 29 2:00 0 - +Rule Greece 1980 only - Apr 1 0:00 1:00 S +Rule Greece 1980 only - Sep 28 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Athens 1:34:52 - LMT 1895 Sep 14 + 1:34:52 - AMT 1916 Jul 28 0:01 # Athens MT + 2:00 Greece EE%sT 1941 Apr 30 + 1:00 Greece CE%sT 1944 Apr 4 + 2:00 Greece EE%sT 1981 + # Shanks says they switched to C-Eur in 1981; + # go with EU instead, since Greece joined it on Jan 1. + 2:00 EU EE%sT + +# Hungary +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Hungary 1918 only - Apr 1 3:00 1:00 S +Rule Hungary 1918 only - Sep 29 3:00 0 - +Rule Hungary 1919 only - Apr 15 3:00 1:00 S +Rule Hungary 1919 only - Sep 15 3:00 0 - +Rule Hungary 1920 only - Apr 5 3:00 1:00 S +Rule Hungary 1920 only - Sep 30 3:00 0 - +Rule Hungary 1945 only - May 1 23:00 1:00 S +Rule Hungary 1945 only - Nov 3 0:00 0 - +Rule Hungary 1946 only - Mar 31 2:00s 1:00 S +Rule Hungary 1946 1949 - Oct Sun>=1 2:00s 0 - +Rule Hungary 1947 1949 - Apr Sun>=4 2:00s 1:00 S +Rule Hungary 1950 only - Apr 17 2:00s 1:00 S +Rule Hungary 1950 only - Oct 23 2:00s 0 - +Rule Hungary 1954 1955 - May 23 0:00 1:00 S +Rule Hungary 1954 1955 - Oct 3 0:00 0 - +Rule Hungary 1956 only - Jun Sun>=1 0:00 1:00 S +Rule Hungary 1956 only - Sep lastSun 0:00 0 - +Rule Hungary 1957 only - Jun Sun>=1 1:00 1:00 S +Rule Hungary 1957 only - Sep lastSun 3:00 0 - +Rule Hungary 1980 only - Apr 6 1:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Budapest 1:16:20 - LMT 1890 Oct + 1:00 C-Eur CE%sT 1918 + 1:00 Hungary CE%sT 1941 Apr 6 2:00 + 1:00 C-Eur CE%sT 1945 May 1 23:00 + 1:00 Hungary CE%sT 1980 Sep 28 2:00s + 1:00 EU CE%sT + +# Iceland +# +# From Adam David (1993-11-06): +# The name of the timezone in Iceland for system / mail / news purposes is GMT. +# +# (1993-12-05): +# This material is paraphrased from the 1988 edition of the University of +# Iceland Almanak. +# +# From January 1st, 1908 the whole of Iceland was standardised at 1 hour +# behind GMT. Previously, local mean solar time was used in different parts +# of Iceland, the almanak had been based on Reykjavik mean solar time which +# was 1 hour and 28 minutes behind GMT. +# +# "first day of winter" referred to [below] means the first day of the 26 weeks +# of winter, according to the old icelandic calendar that dates back to the +# time the norsemen first settled Iceland. The first day of winter is always +# Saturday, but is not dependent on the Julian or Gregorian calendars. +# +# (1993-12-10): +# I have a reference from the Oxford Icelandic-English dictionary for the +# beginning of winter, which ties it to the ecclesiastical calendar (and thus +# to the julian/gregorian calendar) over the period in question. +# the winter begins on the Saturday next before St. Luke's day +# (old style), or on St. Luke's day, if a Saturday. +# St. Luke's day ought to be traceable from ecclesiastical sources. "old style" +# might be a reference to the Julian calendar as opposed to Gregorian, or it +# might mean something else (???). +# +# From Paul Eggert (1999-10-29): +# The Iceland Almanak, Shanks and Whitman disagree on many points. +# We go with the Almanak, except for one claim from Shanks, namely that +# Reykavik was 21W57 from 1837 to 1908, local mean time before that. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Iceland 1917 1918 - Feb 19 23:00 1:00 S +Rule Iceland 1917 only - Oct 21 1:00 0 - +Rule Iceland 1918 only - Nov 16 1:00 0 - +Rule Iceland 1939 only - Apr 29 23:00 1:00 S +Rule Iceland 1939 only - Nov 29 2:00 0 - +Rule Iceland 1940 only - Feb 25 2:00 1:00 S +Rule Iceland 1940 only - Nov 3 2:00 0 - +Rule Iceland 1941 only - Mar 2 1:00s 1:00 S +Rule Iceland 1941 only - Nov 2 1:00s 0 - +Rule Iceland 1942 only - Mar 8 1:00s 1:00 S +Rule Iceland 1942 only - Oct 25 1:00s 0 - +# 1943-1946 - first Sunday in March until first Sunday in winter +Rule Iceland 1943 1946 - Mar Sun>=1 1:00s 1:00 S +Rule Iceland 1943 1948 - Oct Sun>=22 1:00s 0 - +# 1947-1967 - first Sunday in April until first Sunday in winter +Rule Iceland 1947 1967 - Apr Sun>=1 1:00s 1:00 S +# 1949 Oct transition delayed by 1 week +Rule Iceland 1949 only - Oct 30 1:00s 0 - +Rule Iceland 1950 1966 - Oct Sun>=22 1:00s 0 - +Rule Iceland 1967 only - Oct 29 1:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/Reykjavik -1:27:24 - LMT 1837 + -1:27:48 - RMT 1908 # Reykjavik Mean Time? + -1:00 Iceland IS%sT 1968 Apr 7 1:00s + 0:00 - GMT + +# Italy +# +# From Paul Eggert (2001-03-06): +# Sicily and Sardinia each had their own time zones from 1866 to 1893, +# called Palermo Time (+00:53:28) and Cagliari Time (+00:36:32). +# During World War II, German-controlled Italy used German time. +# But these events all occurred before the 1970 cutoff, +# so record only the time in Rome. +# +# From Paul Eggert (1996-05-06): +# For Italian DST we have three sources: Shanks, Whitman, and F. Pollastri +# +# Day-light Saving Time in Italy (1996-03-14) +# +# (`FP' below), taken from an Italian National Electrotechnical Institute +# publication. When the three sources disagree, guess who's right, as follows: +# +# year FP Shanks (S) Whitman (W) Go with: +# 1916 06-03 06-03 24:00 06-03 00:00 FP & W +# 09-30 09-30 24:00 09-30 01:00 FP; guess 24:00s +# 1917 04-01 03-31 24:00 03-31 00:00 FP & S +# 09-30 09-29 24:00 09-30 01:00 FP & W +# 1918 03-09 03-09 24:00 03-09 00:00 FP & S +# 10-06 10-05 24:00 10-06 01:00 FP & W +# 1919 03-01 03-01 24:00 03-01 00:00 FP & S +# 10-04 10-04 24:00 10-04 01:00 FP; guess 24:00s +# 1920 03-20 03-20 24:00 03-20 00:00 FP & S +# 09-18 09-18 24:00 10-01 01:00 FP; guess 24:00s +# 1944 04-02 04-03 02:00 S (see C-Eur) +# 09-16 10-02 03:00 FP; guess 24:00s +# 1945 09-14 09-16 24:00 FP; guess 24:00s +# 1970 05-21 05-31 00:00 S +# 09-20 09-27 00:00 S +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Italy 1916 only - Jun 3 0:00s 1:00 S +Rule Italy 1916 only - Oct 1 0:00s 0 - +Rule Italy 1917 only - Apr 1 0:00s 1:00 S +Rule Italy 1917 only - Sep 30 0:00s 0 - +Rule Italy 1918 only - Mar 10 0:00s 1:00 S +Rule Italy 1918 1919 - Oct Sun>=1 0:00s 0 - +Rule Italy 1919 only - Mar 2 0:00s 1:00 S +Rule Italy 1920 only - Mar 21 0:00s 1:00 S +Rule Italy 1920 only - Sep 19 0:00s 0 - +Rule Italy 1940 only - Jun 15 0:00s 1:00 S +Rule Italy 1944 only - Sep 17 0:00s 0 - +Rule Italy 1945 only - Apr 2 2:00 1:00 S +Rule Italy 1945 only - Sep 15 0:00s 0 - +Rule Italy 1946 only - Mar 17 2:00s 1:00 S +Rule Italy 1946 only - Oct 6 2:00s 0 - +Rule Italy 1947 only - Mar 16 0:00s 1:00 S +Rule Italy 1947 only - Oct 5 0:00s 0 - +Rule Italy 1948 only - Feb 29 2:00s 1:00 S +Rule Italy 1948 only - Oct 3 2:00s 0 - +Rule Italy 1966 1968 - May Sun>=22 0:00 1:00 S +Rule Italy 1966 1969 - Sep Sun>=22 0:00 0 - +Rule Italy 1969 only - Jun 1 0:00 1:00 S +Rule Italy 1970 only - May 31 0:00 1:00 S +Rule Italy 1970 only - Sep lastSun 0:00 0 - +Rule Italy 1971 1972 - May Sun>=22 0:00 1:00 S +Rule Italy 1971 only - Sep lastSun 1:00 0 - +Rule Italy 1972 only - Oct 1 0:00 0 - +Rule Italy 1973 only - Jun 3 0:00 1:00 S +Rule Italy 1973 1974 - Sep lastSun 0:00 0 - +Rule Italy 1974 only - May 26 0:00 1:00 S +Rule Italy 1975 only - Jun 1 0:00s 1:00 S +Rule Italy 1975 1977 - Sep lastSun 0:00s 0 - +Rule Italy 1976 only - May 30 0:00s 1:00 S +Rule Italy 1977 1979 - May Sun>=22 0:00s 1:00 S +Rule Italy 1978 only - Oct 1 0:00s 0 - +Rule Italy 1979 only - Sep 30 0:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Rome 0:49:56 - LMT 1866 Sep 22 + 0:49:56 - RMT 1893 Nov # Rome Mean Time + 1:00 Italy CE%sT 1942 Nov 2 2:00s + 1:00 C-Eur CE%sT 1944 Jul + 1:00 Italy CE%sT 1980 + 1:00 EU CE%sT + +Link Europe/Rome Europe/Vatican +Link Europe/Rome Europe/San_Marino + +# Latvia + +# From Liene Kanepe (1998-09-17): + +# I asked about this matter Scientific Secretary of the Institute of Astronomy +# of The University of Latvia Dr. paed Mr. Ilgonis Vilks. I also searched the +# correct data in juridical acts and I found some juridical documents about +# changes in the counting of time in Latvia from 1981.... +# +# Act No.35 of the Council of Ministers of Latvian SSR of 1981-01-22 ... +# according to the Act No.925 of the Council of Ministers of USSR of 1980-10-24 +# ...: all year round the time of 2nd time zone + 1 hour, in addition turning +# the hands of the clock 1 hour forward on 1 April at 00:00 (GMT 31 March 21:00) +# and 1 hour backward on the 1 October at 00:00 (GMT 30 September 20:00). +# +# Act No.592 of the Council of Ministers of Latvian SSR of 1984-09-24 ... +# according to the Act No.967 of the Council of Ministers of USSR of 1984-09-13 +# ...: all year round the time of 2nd time zone + 1 hour, in addition turning +# the hands of the clock 1 hour forward on the last Sunday of March at 02:00 +# (GMT 23:00 on the previous day) and 1 hour backward on the last Sunday of +# September at 03:00 (GMT 23:00 on the previous day). +# +# Act No.81 of the Council of Ministers of Latvian SSR of 1989-03-22 ... +# according to the Act No.227 of the Council of Ministers of USSR of 1989-03-14 +# ...: since the last Sunday of March 1989 in Lithuanian SSR, Latvian SSR, +# Estonian SSR and Kaliningrad region of Russian Federation all year round the +# time of 2nd time zone (Moscow time minus one hour). On the territory of Latvia +# transition to summer time is performed on the last Sunday of March at 02:00 +# (GMT 00:00), turning the hands of the clock 1 hour forward. The end of +# daylight saving time is performed on the last Sunday of September at 03:00 +# (GMT 00:00), turning the hands of the clock 1 hour backward. Exception is +# 1989-03-26, when we must not turn the hands of the clock.... +# +# The Regulations of the Cabinet of Ministers of the Republic of Latvia of +# 1997-01-21 on transition to Summer time ... established the same order of +# daylight savings time settings as in the States of the European Union. + +# From Andrei Ivanov (2000-03-06): +# This year Latvia will not switch to Daylight Savings Time (as specified in +# +# The Regulations of the Cabinet of Ministers of the Rep. of Latvia of +# 29-Feb-2000 (#79), in Latvian for subscribers only). + +# +# From RFE/RL Newsline (2001-01-03), noted after a heads-up by Rives McDow: +# +# The Latvian government on 2 January decided that the country will +# institute daylight-saving time this spring, LETA reported. +# Last February the three Baltic states decided not to turn back their +# clocks one hour in the spring.... +# Minister of Economy Aigars Kalvitis noted that Latvia had too few +# daylight hours and thus decided to comply with a draft European +# Commission directive that provides for instituting daylight-saving +# time in EU countries between 2002 and 2006. The Latvian government +# urged Lithuania and Estonia to adopt a similar time policy, but it +# appears that they will not do so.... + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Latvia 1989 1996 - Mar lastSun 2:00s 1:00 S +Rule Latvia 1989 1996 - Sep lastSun 2:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Riga 1:36:24 - LMT 1880 + 1:36:24 - RMT 1918 Apr 15 2:00 #Riga Mean Time + 1:36:24 1:00 LST 1918 Sep 16 3:00 #Latvian Summer + 1:36:24 - RMT 1919 Apr 1 2:00 + 1:36:24 1:00 LST 1919 May 22 3:00 + 1:36:24 - RMT 1926 May 11 + 2:00 - EET 1940 Aug 5 + 3:00 - MSK 1941 Jul + 1:00 C-Eur CE%sT 1944 Oct 13 + 3:00 Russia MSK/MSD 1989 Mar lastSun 2:00s + 2:00 1:00 EEST 1989 Sep lastSun 2:00s + 2:00 Latvia EE%sT 1997 Jan 21 + 2:00 EU EE%sT 2000 Feb 29 + 2:00 - EET 2001 Jan 2 + 2:00 EU EE%sT + +# Liechtenstein +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Vaduz 0:38:04 - LMT 1894 Jun + 1:00 - CET 1981 + 1:00 EU CE%sT + +# Lithuania + +# From Paul Eggert (1996-11-22): +# IATA SSIM (1992/1996) says Lithuania uses W-Eur rules, but since it is +# known to be wrong about Estonia and Latvia, assume it's wrong here too. + +# From Marius Gedminas (1998-08-07): +# I would like to inform that in this year Lithuanian time zone +# (Europe/Vilnius) was changed. + +# From ELTA No. 972 (2582) (1999-09-29), +# via Steffen Thorsen: +# Lithuania has shifted back to the second time zone (GMT plus two hours) +# to be valid here starting from October 31, +# as decided by the national government on Wednesday.... +# The Lithuanian government also announced plans to consider a +# motion to give up shifting to summer time in spring, as it was +# already done by Estonia. + +# From the +# Fact File, Lithuanian State Department of Tourism +# (2000-03-27): Local time is GMT+2 hours ..., no daylight saving. + +# From a user via Klaus Marten (2003-02-07): +# As a candidate for membership of the European Union, Lithuania will +# observe Summer Time in 2003, changing its clocks at the times laid +# down in EU Directive 2000/84 of 19.I.01 (i.e. at the same times as its +# neighbour Latvia). The text of the Lithuanian government Order of +# 7.XI.02 to this effect can be found at +# http://www.lrvk.lt/nut/11/n1749.htm + + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Vilnius 1:41:16 - LMT 1880 + 1:24:00 - WMT 1917 # Warsaw Mean Time + 1:35:36 - KMT 1919 Oct 10 # Kaunas Mean Time + 1:00 - CET 1920 Jul 12 + 2:00 - EET 1920 Oct 9 + 1:00 - CET 1940 Aug 3 + 3:00 - MSK 1941 Jun 24 + 1:00 C-Eur CE%sT 1944 Aug + 3:00 Russia MSK/MSD 1991 Mar 31 2:00s + 2:00 1:00 EEST 1991 Sep 29 2:00s + 2:00 C-Eur EE%sT 1998 + 2:00 - EET 1998 Mar 29 1:00u + 1:00 EU CE%sT 1999 Oct 31 1:00u + 2:00 - EET 2003 Jan 1 + 2:00 EU EE%sT + +# Luxembourg +# Whitman disagrees with most of these dates in minor ways; go with Shanks. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Lux 1916 only - May 14 23:00 1:00 S +Rule Lux 1916 only - Oct 1 1:00 0 - +Rule Lux 1917 only - Apr 28 23:00 1:00 S +Rule Lux 1917 only - Sep 17 1:00 0 - +Rule Lux 1918 only - Apr Mon>=15 2:00s 1:00 S +Rule Lux 1918 only - Sep Mon>=15 2:00s 0 - +Rule Lux 1919 only - Mar 1 23:00 1:00 S +Rule Lux 1919 only - Oct 5 3:00 0 - +Rule Lux 1920 only - Feb 14 23:00 1:00 S +Rule Lux 1920 only - Oct 24 2:00 0 - +Rule Lux 1921 only - Mar 14 23:00 1:00 S +Rule Lux 1921 only - Oct 26 2:00 0 - +Rule Lux 1922 only - Mar 25 23:00 1:00 S +Rule Lux 1922 only - Oct Sun>=2 1:00 0 - +Rule Lux 1923 only - Apr 21 23:00 1:00 S +Rule Lux 1923 only - Oct Sun>=2 2:00 0 - +Rule Lux 1924 only - Mar 29 23:00 1:00 S +Rule Lux 1924 1928 - Oct Sun>=2 1:00 0 - +Rule Lux 1925 only - Apr 5 23:00 1:00 S +Rule Lux 1926 only - Apr 17 23:00 1:00 S +Rule Lux 1927 only - Apr 9 23:00 1:00 S +Rule Lux 1928 only - Apr 14 23:00 1:00 S +Rule Lux 1929 only - Apr 20 23:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Luxembourg 0:24:36 - LMT 1904 Jun + 1:00 Lux CE%sT 1918 Nov 25 + 0:00 Lux WE%sT 1929 Oct 6 2:00s + 0:00 Belgium WE%sT 1940 May 14 3:00 + 1:00 C-Eur WE%sT 1944 Sep 18 3:00 + 1:00 Belgium CE%sT 1977 + 1:00 EU CE%sT + +# Macedonia +# see Serbia and Montenegro + +# Malta +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Malta 1973 only - Mar 31 0:00s 1:00 S +Rule Malta 1973 only - Sep 29 0:00s 0 - +Rule Malta 1974 only - Apr 21 0:00s 1:00 S +Rule Malta 1974 only - Sep 16 0:00s 0 - +Rule Malta 1975 1979 - Apr Sun>=15 2:00 1:00 S +Rule Malta 1975 1980 - Sep Sun>=15 2:00 0 - +Rule Malta 1980 only - Mar 31 2:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Malta 0:58:04 - LMT 1893 Nov 2 # Valletta + 1:00 Italy CE%sT 1942 Nov 2 2:00s + 1:00 C-Eur CE%sT 1945 Apr 2 2:00s + 1:00 Italy CE%sT 1973 Mar 31 + 1:00 Malta CE%sT 1981 + 1:00 EU CE%sT + +# Moldova + +# From Paul Eggert (2001-02-11): +# A previous version of this database followed Shanks, who writes that +# Tiraspol switched to Moscow time on 1992-01-19 at 02:00. +# However, this is most likely an error, as Moldova declared independence +# on 1991-08-27 (the 1992-01-19 date is that of a Russian decree). +# In early 1992 there was large-scale interethnic violence in the area +# and it's possible that some Russophones continued to observe Moscow time. +# But moldavizolit@tirastel.md and mk@tirastel.md separately reported via +# Jesper Norgaard that as of 2001-01-24 Tiraspol was like Chisinau. +# The Tiraspol entry has therefore been removed for now. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Chisinau 1:55:20 - LMT 1880 + 1:55 - CMT 1918 Feb 15 # Chisinau MT + 1:44:24 - BMT 1931 Jul 24 # Bucharest MT + 2:00 Romania EE%sT 1940 Aug 15 + 2:00 1:00 EEST 1941 Jul 17 + 1:00 C-Eur CE%sT 1944 Aug 24 + 3:00 Russia MSK/MSD 1990 + 3:00 - MSK 1990 May 6 + 2:00 - EET 1991 + 2:00 Russia EE%sT 1992 + 2:00 E-Eur EE%sT 1997 +# See Romania commentary for the guessed 1997 transition to EU rules. + 2:00 EU EE%sT + +# Monaco +# Shanks gives 0:09 for Paris Mean Time; go with Howse's more precise 0:09:21. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Monaco 0:29:32 - LMT 1891 Mar 15 + 0:09:21 - PMT 1911 Mar 11 # Paris Mean Time + 0:00 France WE%sT 1945 Sep 16 3:00 + 1:00 France CE%sT 1977 + 1:00 EU CE%sT + +# Netherlands + +# Howse writes that the Netherlands' railways used GMT between 1892 and 1940, +# but for other purposes the Netherlands used Amsterdam mean time. + +# However, Robert H. van Gent writes (2001-04-01): +# Howse's statement is only correct up to 1909. From 1909-05-01 (00:00:00 +# Amsterdam mean time) onwards, the whole of the Netherlands (including +# the Dutch railways) was required by law to observe Amsterdam mean time +# (19 minutes 32.13 seconds ahead of GMT). This had already been the +# common practice (except for the railways) for many decades but it was +# not until 1909 when the Dutch government finally defined this by law. +# On 1937-07-01 this was changed to 20 minutes (exactly) ahead of GMT and +# was generally known as Dutch Time ("Nederlandse Tijd"). +# +# (2001-04-08): +# 1892-05-01 was the date when the Dutch railways were by law required to +# observe GMT while the remainder of the Netherlands adhered to the common +# practice of following Amsterdam mean time. +# +# (2001-04-09): +# In 1835 the authorities of the province of North Holland requested the +# municipal authorities of the towns and cities in the province to observe +# Amsterdam mean time but I do not know in how many cases this request was +# actually followed. +# +# From 1852 onwards the Dutch telegraph offices were by law required to +# observe Amsterdam mean time. As the time signals from the observatory of +# Leiden were also distributed by the telegraph system, I assume that most +# places linked up with the telegraph (and railway) system automatically +# adopted Amsterdam mean time. +# +# Although the early Dutch railway companies initially observed a variety +# of times, most of them had adopted Amsterdam mean time by 1858 but it +# was not until 1866 when they were all required by law to observe +# Amsterdam mean time. + +# The data before 1945 are taken from +# . + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Neth 1916 only - May 1 0:00 1:00 NST # Netherlands Summer Time +Rule Neth 1916 only - Oct 1 0:00 0 AMT # Amsterdam Mean Time +Rule Neth 1917 only - Apr 16 2:00s 1:00 NST +Rule Neth 1917 only - Sep 17 2:00s 0 AMT +Rule Neth 1918 1921 - Apr Mon>=1 2:00s 1:00 NST +Rule Neth 1918 1921 - Sep lastMon 2:00s 0 AMT +Rule Neth 1922 only - Mar lastSun 2:00s 1:00 NST +Rule Neth 1922 1936 - Oct Sun>=2 2:00s 0 AMT +Rule Neth 1923 only - Jun Fri>=1 2:00s 1:00 NST +Rule Neth 1924 only - Mar lastSun 2:00s 1:00 NST +Rule Neth 1925 only - Jun Fri>=1 2:00s 1:00 NST +# From 1926 through 1939 DST began 05-15, except that it was delayed by a week +# in years when 05-15 fell in the Pentecost weekend. +Rule Neth 1926 1931 - May 15 2:00s 1:00 NST +Rule Neth 1932 only - May 22 2:00s 1:00 NST +Rule Neth 1933 1936 - May 15 2:00s 1:00 NST +Rule Neth 1937 only - May 22 2:00s 1:00 NST +Rule Neth 1937 only - Jul 1 0:00 1:00 S +Rule Neth 1937 1939 - Oct Sun>=2 2:00s 0 - +Rule Neth 1938 1939 - May 15 2:00s 1:00 S +Rule Neth 1945 only - Apr 2 2:00s 1:00 S +Rule Neth 1945 only - Sep 16 2:00s 0 - +# +# Amsterdam Mean Time was +00:19:32.13 exactly, but the .13 is omitted +# below because the current format requires GMTOFF to be an integer. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Amsterdam 0:19:32 - LMT 1835 + 0:19:32 Neth %s 1937 Jul 1 + 0:20 Neth NE%sT 1940 May 16 0:00 # Dutch Time + 1:00 C-Eur CE%sT 1945 Apr 2 2:00 + 1:00 Neth CE%sT 1977 + 1:00 EU CE%sT + +# Norway +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Whitman gives 1916 May 21 - 1916 Oct 21; go with Shanks. +Rule Norway 1916 only - May 22 1:00 1:00 S +Rule Norway 1916 only - Sep 30 0:00 0 - +# Whitman says DST observed 1935-08-11/1942-11-01, then 1943-03-29/10-04, +# 1944-04-03/10-02, and 1945-04-01/10-01; go with Shanks. +Rule Norway 1945 only - Apr 2 2:00s 1:00 S +Rule Norway 1945 only - Oct 1 2:00s 0 - +Rule Norway 1959 1964 - Mar Sun>=15 2:00s 1:00 S +Rule Norway 1959 1965 - Sep Sun>=15 2:00s 0 - +Rule Norway 1965 only - Apr 25 2:00s 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Oslo 0:43:00 - LMT 1895 Jan 1 + 1:00 Norway CE%sT 1940 Aug 10 23:00 + 1:00 C-Eur CE%sT 1945 Apr 2 2:00 + 1:00 Norway CE%sT 1980 + 1:00 EU CE%sT + +# Svalbard & Jan Mayen + +# From Steffen Thorsen (2001-05-01): +# Although I could not find it explicitly, it seems that Jan Mayen and +# Svalbard have been using the same time as Norway at least since the +# time they were declared as parts of Norway. Svalbard was declared +# as a part of Norway by law of 1925-07-17 no 11, section 4 and Jan +# Mayen by law of 1930-02-27 no 2, section 2. (From +# http://www.lovdata.no/all/nl-19250717-011.html and +# http://www.lovdata.no/all/nl-19300227-002.html). The law/regulation +# for normal/standard time in Norway is from 1894-06-29 no 1 (came +# into operation on 1895-01-01) and Svalbard/Jan Mayen seem to be a +# part of this law since 1925/1930. (From +# http://www.lovdata.no/all/nl-18940629-001.html ) I have not been +# able to find if Jan Mayen used a different time zone (e.g. -0100) +# before 1930. Jan Mayen has only been "inhabitated" since 1921 by +# Norwegian meteorologists and maybe used the same time as Norway ever +# since 1921. Svalbard (Arctic/Longyearbyen) has been inhabited since +# before 1895, and therefore probably changed the local time somewhere +# between 1895 and 1925 (inclusive). + +# From Paul Eggert (2001-05-01): +# +# Actually, Jan Mayen was never occupied by Germany during World War II, +# so it must have diverged from Oslo time during the war, as Olso was +# keeping Berlin time. +# +# says that the meteorologists +# burned down their station in 1940 and left the island, but returned in +# 1941 with a small Norwegian garrison and continued operations despite +# frequent air ttacks from Germans. In 1943 the Americans established a +# radiolocating station on the island, called "Atlantic City". Possibly +# the UTC offset changed during the war, but I think it unlikely that +# Jan Mayen used German daylight-saving rules. +# +# Svalbard is more complicated, as it was raided in August 1941 by an +# Allied party that evacuated the civilian population to England (says +# ). The Svalbard FAQ +# says that the Germans were +# expelled on 1942-05-14. However, small parties of Germans did return, +# and according to Wilhelm Dege's book "War North of 80" (1954) +# +# the German armed forces at the Svalbard weather station code-named +# Haudegen did not surrender to the Allies until September 1945. +# +# All these events predate our cutoff date of 1970. Unless we can +# come up with more definitive info about the timekeeping during the +# war years it's probably best just do do the following for now: +Link Europe/Oslo Arctic/Longyearbyen +Link Europe/Oslo Atlantic/Jan_Mayen + +# Poland +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Poland 1918 1919 - Sep 16 2:00s 0 - +Rule Poland 1919 only - Apr 15 2:00s 1:00 S +# Whitman gives 1944 Nov 30; go with Shanks. +Rule Poland 1944 only - Oct 4 2:00 0 - +# For 1944-1948 Whitman gives the previous day; go with Shanks. +Rule Poland 1945 only - Apr 29 0:00 1:00 S +Rule Poland 1945 only - Nov 1 0:00 0 - +Rule Poland 1946 only - Apr 14 0:00 1:00 S +Rule Poland 1946 only - Sep 7 0:00 0 - +Rule Poland 1947 only - May 4 0:00 1:00 S +Rule Poland 1947 1948 - Oct Sun>=1 0:00 0 - +Rule Poland 1948 only - Apr 18 0:00 1:00 S +# Whitman also gives 1949 Apr 9 - 1949 Oct 1; go with Shanks. +Rule Poland 1957 only - Jun 2 1:00s 1:00 S +Rule Poland 1957 1958 - Sep lastSun 1:00s 0 - +Rule Poland 1958 only - Mar 30 1:00s 1:00 S +Rule Poland 1959 only - May 31 1:00s 1:00 S +Rule Poland 1959 1961 - Oct Sun>=1 1:00s 0 - +Rule Poland 1960 only - Apr 3 1:00s 1:00 S +Rule Poland 1961 1964 - May Sun>=25 1:00s 1:00 S +Rule Poland 1962 1964 - Sep lastSun 1:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Warsaw 1:24:00 - LMT 1880 + 1:24:00 - WMT 1915 Aug 5 # Warsaw Mean Time + 1:00 C-Eur CE%sT 1918 Sep 16 3:00 + 2:00 Poland EE%sT 1922 Jun + 1:00 Poland CE%sT 1940 Jun 23 2:00 + 1:00 C-Eur CE%sT 1944 Oct + 1:00 Poland CE%sT 1977 Apr 3 1:00 + 1:00 W-Eur CE%sT 1999 +# IATA SSIM (1991/1996) gives EU rules, but the _The Warsaw Voice_ +# +# http://www.warsawvoice.com/pl/v361/NewsInBrief.shtml (1995-09-24) +# +# says the autumn 1995 switch was at 02:00. +# Stick with W-Eur for now. +# +# From Marcin.Kasperski@softax.com.pl (1999-06-10): +# According to my colleagues someone recently decided, that Poland would +# follow European Union regulations, so - I think - the matter is not +# worth further discussion. +# +# From Paul Eggert (1999-06-10): +# Kasperski also writes that the government futzed with the rules in 1997 +# or 1998 but he doesn't remember the details. Assume they switched to +# EU rules in 1999. + 1:00 EU CE%sT + +# Portugal +# +# From Rui Pedro Salgueiro (1992-11-12): +# Portugal has recently (September, 27) changed timezone +# (from WET to MET or CET) to harmonize with EEC. +# +# Martin Bruckmann (1996-02-29) reports via Peter Ilieve +# that Portugal is reverting to 0:00 by not moving its clocks this spring. +# The new Prime Minister was fed up with getting up in the dark in the winter. +# +# From Paul Eggert (1996-11-12): +# IATA SSIM (1991-09) reports several 1991-09 and 1992-09 transitions +# at 02:00u, not 01:00u. Assume that these are typos. +# IATA SSIM (1991/1992) reports that the Azores were at -1:00. +# IATA SSIM (1993-02) says +0:00; later issues (through 1996-09) say -1:00. +# Guess that the Azores changed to EU rules in 1992 (since that's when Portugal +# harmonized with the EU), and that they stayed +0:00 that winter. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# DSH writes that despite Decree 1,469 (1915), the change to the clocks was not +# done every year, depending on what Spain did, because of railroad schedules. +# Go with Shanks. +Rule Port 1916 only - Jun 17 23:00 1:00 S +# Whitman gives 1916 Oct 31; go with Shanks. +Rule Port 1916 only - Nov 1 1:00 0 - +Rule Port 1917 only - Feb 28 23:00s 1:00 S +Rule Port 1917 1921 - Oct 14 23:00s 0 - +Rule Port 1918 only - Mar 1 23:00s 1:00 S +Rule Port 1919 only - Feb 28 23:00s 1:00 S +Rule Port 1920 only - Feb 29 23:00s 1:00 S +Rule Port 1921 only - Feb 28 23:00s 1:00 S +Rule Port 1924 only - Apr 16 23:00s 1:00 S +Rule Port 1924 only - Oct 14 23:00s 0 - +Rule Port 1926 only - Apr 17 23:00s 1:00 S +Rule Port 1926 1929 - Oct Sat>=1 23:00s 0 - +Rule Port 1927 only - Apr 9 23:00s 1:00 S +Rule Port 1928 only - Apr 14 23:00s 1:00 S +Rule Port 1929 only - Apr 20 23:00s 1:00 S +Rule Port 1931 only - Apr 18 23:00s 1:00 S +# Whitman gives 1931 Oct 8; go with Shanks. +Rule Port 1931 1932 - Oct Sat>=1 23:00s 0 - +Rule Port 1932 only - Apr 2 23:00s 1:00 S +# Shanks gives 1934 Apr 4; go with Whitman. +Rule Port 1934 only - Apr 7 23:00s 1:00 S +# Whitman gives 1934 Oct 5; go with Shanks. +Rule Port 1934 1938 - Oct Sat>=1 23:00s 0 - +# Shanks gives 1935 Apr 30; go with Whitman. +Rule Port 1935 only - Mar 30 23:00s 1:00 S +Rule Port 1936 only - Apr 18 23:00s 1:00 S +# Whitman gives 1937 Apr 2; go with Shanks. +Rule Port 1937 only - Apr 3 23:00s 1:00 S +Rule Port 1938 only - Mar 26 23:00s 1:00 S +Rule Port 1939 only - Apr 15 23:00s 1:00 S +# Whitman gives 1939 Oct 7; go with Shanks. +Rule Port 1939 only - Nov 18 23:00s 0 - +Rule Port 1940 only - Feb 24 23:00s 1:00 S +# Shanks gives 1940 Oct 7; go with Whitman. +Rule Port 1940 1941 - Oct 5 23:00s 0 - +Rule Port 1941 only - Apr 5 23:00s 1:00 S +Rule Port 1942 1945 - Mar Sat>=8 23:00s 1:00 S +Rule Port 1942 only - Apr 25 22:00s 2:00 M # Midsummer +Rule Port 1942 only - Aug 15 22:00s 1:00 S +Rule Port 1942 1945 - Oct Sat>=24 23:00s 0 - +Rule Port 1943 only - Apr 17 22:00s 2:00 M +Rule Port 1943 1945 - Aug Sat>=25 22:00s 1:00 S +Rule Port 1944 1945 - Apr Sat>=21 22:00s 2:00 M +Rule Port 1946 only - Apr Sat>=1 23:00s 1:00 S +Rule Port 1946 only - Oct Sat>=1 23:00s 0 - +Rule Port 1947 1949 - Apr Sun>=1 2:00s 1:00 S +Rule Port 1947 1949 - Oct Sun>=1 2:00s 0 - +# Shanks says DST was observed in 1950; go with Whitman. +# Whitman gives Oct lastSun for 1952 on; go with Shanks. +Rule Port 1951 1965 - Apr Sun>=1 2:00s 1:00 S +Rule Port 1951 1965 - Oct Sun>=1 2:00s 0 - +Rule Port 1977 only - Mar 27 0:00s 1:00 S +Rule Port 1977 only - Sep 25 0:00s 0 - +Rule Port 1978 1979 - Apr Sun>=1 0:00s 1:00 S +Rule Port 1978 only - Oct 1 0:00s 0 - +Rule Port 1979 1982 - Sep lastSun 1:00s 0 - +Rule Port 1980 only - Mar lastSun 0:00s 1:00 S +Rule Port 1981 1982 - Mar lastSun 1:00s 1:00 S +Rule Port 1983 only - Mar lastSun 2:00s 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# Shanks says that the transition from LMT to WET occurred 1911-05-24; +# Willett says 1912-01-01. Go with Willett. +Zone Europe/Lisbon -0:36:32 - LMT 1884 + -0:36:32 - LMT 1912 Jan 1 # Lisbon Mean Time + 0:00 Port WE%sT 1966 Apr 3 2:00 + 1:00 - CET 1976 Sep 26 1:00 + 0:00 Port WE%sT 1983 Sep 25 1:00s + 0:00 W-Eur WE%sT 1992 Sep 27 1:00s + 1:00 EU CE%sT 1996 Mar 31 1:00u + 0:00 EU WE%sT +Zone Atlantic/Azores -1:42:40 - LMT 1884 # Ponta Delgada + -1:54:32 - HMT 1911 May 24 # Horta Mean Time + -2:00 Port AZO%sT 1966 Apr 3 2:00 # Azores Time + -1:00 Port AZO%sT 1983 Sep 25 1:00s + -1:00 W-Eur AZO%sT 1992 Sep 27 1:00s + 0:00 EU WE%sT 1993 Mar 28 1:00u + -1:00 EU AZO%sT +Zone Atlantic/Madeira -1:07:36 - LMT 1884 # Funchal + -1:07:36 - FMT 1911 May 24 # Funchal Mean Time + -1:00 Port MAD%sT 1966 Apr 3 2:00 # Madeira Time + 0:00 Port WE%sT 1983 Sep 25 1:00s + 0:00 EU WE%sT + +# Romania +# +# From Paul Eggert (1999-10-07): +# +# Nine O'clock (1998-10-23) reports that the switch occurred at +# 04:00 local time in fall 1998. For lack of better info, +# assume that Romania and Moldova switched to EU rules in 1997, +# the same year as Bulgaria. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Romania 1932 only - May 21 0:00s 1:00 S +Rule Romania 1932 1939 - Oct Sun>=1 0:00s 0 - +Rule Romania 1933 1939 - Apr Sun>=2 0:00s 1:00 S +Rule Romania 1979 only - May 27 0:00 1:00 S +Rule Romania 1979 only - Sep lastSun 0:00 0 - +Rule Romania 1980 only - Apr 5 23:00 1:00 S +Rule Romania 1980 only - Sep lastSun 1:00 0 - +Rule Romania 1991 1993 - Mar lastSun 0:00s 1:00 S +Rule Romania 1991 1993 - Sep lastSun 0:00s 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Bucharest 1:44:24 - LMT 1891 Oct + 1:44:24 - BMT 1931 Jul 24 # Bucharest MT + 2:00 Romania EE%sT 1981 Mar 29 2:00s + 2:00 C-Eur EE%sT 1991 + 2:00 Romania EE%sT 1994 + 2:00 E-Eur EE%sT 1997 + 2:00 EU EE%sT + +# Russia + +# From Paul Eggert (1999-11-12): +# Except for Moscow after 1919-07-01, I invented the time zone abbreviations. +# Moscow time zone abbreviations after 1919-07-01, and Moscow rules after 1991, +# are from Andrey A. Chernov. The rest is from Shanks, except we follow +# Chernov's report that 1992 DST transitions were Sat 23:00, not Sun 02:00s. +# +# From Stanislaw A. Kuzikowski (1994-06-29): +# But now it is some months since Novosibirsk is 3 hours ahead of Moscow! +# I do not know why they have decided to make this change; +# as far as I remember it was done exactly during winter->summer switching +# so we (Novosibirsk) simply did not switch. +# +# From Andrey A. Chernov (1996-10-04): +# `MSK' and `MSD' were born and used initially on Moscow computers with +# UNIX-like OSes by several developer groups (e.g. Demos group, Kiae group).... +# The next step was the UUCP network, the Relcom predecessor +# (used mainly for mail), and MSK/MSD was actively used there. +# +# From Chris Carrier <72157.3334@CompuServe.COM> (1996-10-30): +# According to a friend of mine who rode the Trans-Siberian Railroad from +# Moscow to Irkutsk in 1995, public air and rail transport in Russia ... +# still follows Moscow time, no matter where in Russia it is located. +# +# For Grozny, Chechnya, we have the following story from +# John Daniszewski, "Scavengers in the Rubble", Los Angeles Times (2001-02-07): +# News--often false--is spread by word of mouth. A rumor that it was +# time to move the clocks back put this whole city out of sync with +# the rest of Russia for two weeks--even soldiers stationed here began +# enforcing curfew at the wrong time. +# +# From Gwillim Law (2001-06-05): +# There's considerable evidence that Sakhalin Island used to be in +# UTC+11, and has changed to UTC+10, in this decade. I start with the +# SSIM, which listed Yuzhno-Sakhalinsk in zone RU10 along with Magadan +# until February 1997, and then in RU9 with Khabarovsk and Vladivostok +# since September 1997.... Although the Kuril Islands are +# administratively part of Sakhalin oblast', they appear to have +# remained on UTC+11 along with Magadan. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# +# Kaliningradskaya oblast'. +Zone Europe/Kaliningrad 1:22:00 - LMT 1893 Apr + 1:00 C-Eur CE%sT 1945 + 2:00 Poland CE%sT 1946 + 3:00 Russia MSK/MSD 1991 Mar 31 2:00s + 2:00 Russia EE%sT +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Respublika Adygeya, Arkhangel'skaya oblast', Astrakhanskaya oblast', +# Belgorodskaya oblast', Bryanskaya oblast', Vladimirskaya oblast', +# Volgogradskaya oblast', Vologodskaya oblast', Voronezhskaya oblast', +# Respublika Dagestan, Ivanovskaya oblast', Respublika Ingushetiya, +# Kabarbino-Balkarskaya Respublika, Respublika Kalmykiya, +# Kalyzhskaya oblast', Respublika Karachaevo-Cherkessiya, +# Respublika Kareliya, Kirovskaya oblast', Respublika Komi, +# Kostromskaya oblast', Krasnodarskij kraj, Kurskaya oblast', +# Leningradskaya oblast', Lipetskaya oblast', Respublika Marij El, +# Respublika Mordoviya, Moskva, Moskovskaya oblast', +# Murmanskaya oblast', Nenetskij avtonomnyj okrug, +# Nizhegorodskaya oblast', Novgorodskaya oblast', Orlovskaya oblast', +# Penzenskaya oblast', Pskovskaya oblast', Rostovskaya oblast', +# Ryazanskaya oblast', Sankt-Peterburg, Saratovskaya oblast', +# Respublika Severnaya Osetiya, Smolenskaya oblast', +# Stavropol'skij kraj, Tambovskaya oblast', Respublika Tatarstan, +# Tverskaya oblast', Tyl'skaya oblast', Ul'yanovskaya oblast', +# Chechenskaya Respublika, Chuvashskaya oblast', +# Yaroslavskaya oblast' +Zone Europe/Moscow 2:30:20 - LMT 1880 + 2:30 - MMT 1916 Jul 3 # Moscow Mean Time + 2:30:48 Russia %s 1919 Jul 1 2:00 + 3:00 Russia MSK/MSD 1922 Oct + 2:00 - EET 1930 Jun 21 + 3:00 Russia MSK/MSD 1991 Mar 31 2:00s + 2:00 Russia EE%sT 1992 Jan 19 2:00s + 3:00 Russia MSK/MSD +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Samarskaya oblast', Udmyrtskaya respublika +Zone Europe/Samara 3:20:36 - LMT 1919 Jul 1 2:00 + 3:00 - KUYT 1930 Jun 21 # Kuybyshev + 4:00 Russia KUY%sT 1989 Mar 26 2:00s + 3:00 Russia KUY%sT 1991 Mar 31 2:00s + 2:00 Russia KUY%sT 1991 Sep 29 2:00s + 3:00 - KUYT 1991 Oct 20 3:00 + 4:00 Russia SAM%sT # Samara Time +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Respublika Bashkortostan, Komi-Permyatskij avtonomnyj okrug, +# Kurganskaya oblast', Orenburgskaya oblast', Permskaya oblast', +# Sverdlovskaya oblast', Tyumenskaya oblast', +# Khanty-Manskijskij avtonomnyj okrug, Chelyabinskaya oblast', +# Yamalo-Nenetskij avtonomnyj okrug. +Zone Asia/Yekaterinburg 4:02:24 - LMT 1919 Jul 15 4:00 + 4:00 - SVET 1930 Jun 21 # Sverdlovsk Time + 5:00 Russia SVE%sT 1991 Mar 31 2:00s + 4:00 Russia SVE%sT 1992 Jan 19 2:00s + 5:00 Russia YEK%sT # Yekaterinburg Time +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Respublika Altaj, Altajskij kraj, Omskaya oblast'. +Zone Asia/Omsk 4:53:36 - LMT 1919 Nov 14 + 5:00 - OMST 1930 Jun 21 # Omsk TIme + 6:00 Russia OMS%sT 1991 Mar 31 2:00s + 5:00 Russia OMS%sT 1992 Jan 19 2:00s + 6:00 Russia OMS%sT +# +# Novosibirskaya oblast'. +Zone Asia/Novosibirsk 5:31:40 - LMT 1919 Dec 14 6:00 + 6:00 - NOVT 1930 Jun 21 # Novosibirsk Time + 7:00 Russia NOV%sT 1991 Mar 31 2:00s + 6:00 Russia NOV%sT 1992 Jan 19 2:00s + 7:00 Russia NOV%sT 1993 May 23 # says Shanks + 6:00 Russia NOV%sT +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Kemerovskaya oblast', Krasnoyarskij kraj, +# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug, Tomskaya oblast', +# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug. +Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6 + 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time + 7:00 Russia KRA%sT 1991 Mar 31 2:00s + 6:00 Russia KRA%sT 1992 Jan 19 2:00s + 7:00 Russia KRA%sT +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Respublika Buryatiya, Irkutskaya oblast', +# Ust'-Ordynskij Buryatskij avtonomnyj okrug. +Zone Asia/Irkutsk 6:57:20 - LMT 1880 + 6:57:20 - IMT 1920 Jan 25 # Irkutsk Mean Time + 7:00 - IRKT 1930 Jun 21 # Irkutsk Time + 8:00 Russia IRK%sT 1991 Mar 31 2:00s + 7:00 Russia IRK%sT 1992 Jan 19 2:00s + 8:00 Russia IRK%sT +# +# From Oscar van Vlijmen (2003-10-18): [This region consists of] +# Aginskij Buryatskij avtonomnyj okrug, Amurskaya oblast', +# [parts of] Respublika Sakha (Yakutiya), Chitinskaya oblast'. +# The Sakha districts are: Aldanskij, Amginskij, Anabarskij, +# Bulunskij, Verkhnekolymskij, Verkhnevilyujskij, Vilyujskij, Gornyj, +# Zhiganskij, Kobyajskij, Lenskij, Megino-Kangalasskij, Mirninskij, +# Namskij, Nyurbinskij, Olenekskij, Olekminskij, Srednekolymskij, +# Suntarskij, Tattinskij, Ust'-Aldanskij, Khangalasskij, +# Churapchinskij, Eveno-Bytantajskij. +Zone Asia/Yakutsk 8:38:40 - LMT 1919 Dec 15 + 8:00 - YAKT 1930 Jun 21 # Yakutsk Time + 9:00 Russia YAK%sT 1991 Mar 31 2:00s + 8:00 Russia YAK%sT 1992 Jan 19 2:00s + 9:00 Russia YAK%sT +# +# From Oscar van Vlijmen (2003-10-18): [This region consists of] +# Evrejskaya avtonomnaya oblast', Khabarovskij kraj, Primorskij kraj, +# [parts of] Respublika Sakha (Yakutiya). +# The Sakha districts are: Verkhoyanskij, Tomponskij, Ust'-Majskij, +# Ust'-Yanskij. +Zone Asia/Vladivostok 8:47:44 - LMT 1922 Nov 15 + 9:00 - VLAT 1930 Jun 21 # Vladivostok Time + 10:00 Russia VLA%sT 1991 Mar 31 2:00s + 9:00 Russia VLA%sST 1992 Jan 19 2:00s + 10:00 Russia VLA%sT +# +# Sakhalinskaya oblast'. +# The Zone name should be Yuzhno-Sakhalinsk, but that's too long. +Zone Asia/Sakhalin 9:30:48 - LMT 1905 Aug 23 + 9:00 - CJT 1938 + 9:00 - JST 1945 Aug 25 + 11:00 Russia SAK%sT 1991 Mar 31 2:00s # Sakhalin T. + 10:00 Russia SAK%sT 1992 Jan 19 2:00s + 11:00 Russia SAK%sT 1997 Mar lastSun 2:00s + 10:00 Russia SAK%sT +# +# From Oscar van Vlijmen (2003-10-18): [This region consists of] +# Magadanskaya oblast', Respublika Sakha (Yakutiya). +# Probably also: Kuril Islands. +# The Sakha districts are: Abyjskij, Allaikhovskij, Momskij, +# Nizhnekolymskij, Ojmyakonskij. +Zone Asia/Magadan 10:03:12 - LMT 1924 May 2 + 10:00 - MAGT 1930 Jun 21 # Magadan Time + 11:00 Russia MAG%sT 1991 Mar 31 2:00s + 10:00 Russia MAG%sT 1992 Jan 19 2:00s + 11:00 Russia MAG%sT +# +# From Oscar van Vlijmen (2001-08-25): [This region consists of] +# Kamchatskaya oblast', Koryakskij avtonomnyj okrug. +# +# The Zone name should be Asia/Petropavlovsk-Kamchatski, but that's too long. +Zone Asia/Kamchatka 10:34:36 - LMT 1922 Nov 10 + 11:00 - PETT 1930 Jun 21 # P-K Time + 12:00 Russia PET%sT 1991 Mar 31 2:00s + 11:00 Russia PET%sT 1992 Jan 19 2:00s + 12:00 Russia PET%sT +# +# Chukotskij avtonomnyj okrug +Zone Asia/Anadyr 11:49:56 - LMT 1924 May 2 + 12:00 - ANAT 1930 Jun 21 # Anadyr Time + 13:00 Russia ANA%sT 1982 Apr 1 0:00s + 12:00 Russia ANA%sT 1991 Mar 31 2:00s + 11:00 Russia ANA%sT 1992 Jan 19 2:00s + 12:00 Russia ANA%sT + +# Serbia and Montenegro +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Belgrade 1:22:00 - LMT 1884 + 1:00 - CET 1941 Apr 18 23:00 + 1:00 C-Eur CE%sT 1945 May 8 2:00s + 1:00 1:00 CEST 1945 Sep 16 2:00s +# Metod Kozelj reports that the legal date of +# transition to EU rules was 1982-11-27, for all of Yugoslavia at the time. +# Shanks doesn't give as much detail, so go with Kozelj. + 1:00 - CET 1982 Nov 27 + 1:00 EU CE%sT +Link Europe/Belgrade Europe/Ljubljana # Slovenia +Link Europe/Belgrade Europe/Sarajevo # Bosnia and Herzegovina +Link Europe/Belgrade Europe/Skopje # Macedonia +Link Europe/Belgrade Europe/Zagreb # Croatia + +# Slovakia +Link Europe/Prague Europe/Bratislava + +# Slovenia +# see Serbia and Montenegro + +# Spain +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# For 1917-1919 Whitman gives Apr Sat>=1 - Oct Sat>=1; go with Shanks. +Rule Spain 1917 only - May 5 23:00s 1:00 S +Rule Spain 1917 1919 - Oct 6 23:00s 0 - +Rule Spain 1918 only - Apr 15 23:00s 1:00 S +Rule Spain 1919 only - Apr 5 23:00s 1:00 S +# Whitman gives 1921 Feb 28 - Oct 14; go with Shanks. +Rule Spain 1924 only - Apr 16 23:00s 1:00 S +# Whitman gives 1924 Oct 14; go with Shanks. +Rule Spain 1924 only - Oct 4 23:00s 0 - +Rule Spain 1926 only - Apr 17 23:00s 1:00 S +# Whitman says no DST in 1929; go with Shanks. +Rule Spain 1926 1929 - Oct Sat>=1 23:00s 0 - +Rule Spain 1927 only - Apr 9 23:00s 1:00 S +Rule Spain 1928 only - Apr 14 23:00s 1:00 S +Rule Spain 1929 only - Apr 20 23:00s 1:00 S +# Whitman gives 1937 Jun 16, 1938 Apr 16, 1940 Apr 13; go with Shanks. +Rule Spain 1937 only - May 22 23:00s 1:00 S +Rule Spain 1937 1939 - Oct Sat>=1 23:00s 0 - +Rule Spain 1938 only - Mar 22 23:00s 1:00 S +Rule Spain 1939 only - Apr 15 23:00s 1:00 S +Rule Spain 1940 only - Mar 16 23:00s 1:00 S +# Whitman says no DST 1942-1945; go with Shanks. +Rule Spain 1942 only - May 2 22:00s 2:00 M # Midsummer +Rule Spain 1942 only - Sep 1 22:00s 1:00 S +Rule Spain 1943 1946 - Apr Sat>=13 22:00s 2:00 M +Rule Spain 1943 only - Oct 3 22:00s 1:00 S +Rule Spain 1944 only - Oct 10 22:00s 1:00 S +Rule Spain 1945 only - Sep 30 1:00 1:00 S +Rule Spain 1946 only - Sep 30 0:00 0 - +Rule Spain 1949 only - Apr 30 23:00 1:00 S +Rule Spain 1949 only - Sep 30 1:00 0 - +Rule Spain 1974 1975 - Apr Sat>=13 23:00 1:00 S +Rule Spain 1974 1975 - Oct Sun>=1 1:00 0 - +Rule Spain 1976 only - Mar 27 23:00 1:00 S +Rule Spain 1976 1977 - Sep lastSun 1:00 0 - +Rule Spain 1977 1978 - Apr 2 23:00 1:00 S +Rule Spain 1978 only - Oct 1 1:00 0 - +# The following rules are copied from Morocco from 1967 through 1978. +Rule SpainAfrica 1967 only - Jun 3 12:00 1:00 S +Rule SpainAfrica 1967 only - Oct 1 0:00 0 - +Rule SpainAfrica 1974 only - Jun 24 0:00 1:00 S +Rule SpainAfrica 1974 only - Sep 1 0:00 0 - +Rule SpainAfrica 1976 1977 - May 1 0:00 1:00 S +Rule SpainAfrica 1976 only - Aug 1 0:00 0 - +Rule SpainAfrica 1977 only - Sep 28 0:00 0 - +Rule SpainAfrica 1978 only - Jun 1 0:00 1:00 S +Rule SpainAfrica 1978 only - Aug 4 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Madrid -0:14:44 - LMT 1901 + 0:00 Spain WE%sT 1946 Sep 30 + 1:00 Spain CE%sT 1979 + 1:00 EU CE%sT +Zone Africa/Ceuta -0:21:16 - LMT 1901 + 0:00 - WET 1918 May 6 23:00 + 0:00 1:00 WEST 1918 Oct 7 23:00 + 0:00 - WET 1924 + 0:00 Spain WE%sT 1929 + 0:00 SpainAfrica WE%sT 1984 Mar 16 + 1:00 - CET 1986 + 1:00 EU CE%sT +Zone Atlantic/Canary -1:01:36 - LMT 1922 Mar # Las Palmas de Gran C. + -1:00 - CANT 1946 Sep 30 1:00 # Canaries Time + 0:00 - WET 1980 Apr 6 0:00s + 0:00 1:00 WEST 1980 Sep 28 0:00s + 0:00 EU WE%sT +# IATA SSIM (1996-09) says the Canaries switch at 2:00u, not 1:00u. +# Ignore this for now, as the Canaries are part of the EU. + +# Sweden + +# From Ivan Nilsson (2001-04-13), superseding Shanks: +# +# The law "Svensk forfattningssamling 1878, no 14" about standard time in 1879: +# From the beginning of 1879 (that is 01-01 00:00) the time for all +# places in the country is "the mean solar time for the meridian at +# three degrees, or twelve minutes of time, to the west of the +# meridian of the Observatory of Stockholm". The law is dated 1878-05-31. +# +# The observatory at that time had the meridian 18 degrees 03' 30" +# eastern longitude = 01:12:14 in time. Less 12 minutes gives the +# national standard time as 01:00:14 ahead of GMT.... +# +# About the beginning of CET in Sweden. The lawtext ("Svensk +# forfattningssamling 1899, no 44") states, that "from the beginning +# of 1900... ... the same as the mean solar time for the meridian at +# the distance of one hour of time from the meridian of the English +# observatory at Greenwich, or at 12 minutes 14 seconds to the west +# from the meridian of the Observatory of Stockholm". The law is dated +# 1899-06-16. In short: At 1900-01-01 00:00:00 the new standard time +# in Sweden is 01:00:00 ahead of GMT. +# +# 1916: The lawtext ("Svensk forfattningssamling 1916, no 124") states +# that "1916-05-15 is considered to begin one hour earlier". It is +# pretty obvious that at 05-14 23:00 the clocks are set to 05-15 00:00.... +# Further the law says, that "1916-09-30 is considered to end one hour later". +# +# The laws regulating [DST] are available on the site of the Swedish +# Parliament beginning with 1985 - the laws regulating 1980/1984 are +# not available on the site (to my knowledge they are only available +# in Swedish): (type +# "sommartid" without the quotes in the field "Fritext" and then click +# the Sok-button). +# +# (2001-05-13): +# +# I have now found a newspaper stating that at 1916-10-01 01:00 +# summertime the church-clocks etc were set back one hour to show +# 1916-10-01 00:00 standard time. The article also reports that some +# people thought the switch to standard time would take place already +# at 1916-10-01 00:00 summer time, but they had to wait for another +# hour before the event took place. +# +# Source: The newspaper "Dagens Nyheter", 1916-10-01, page 7 upper left. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Stockholm 1:12:12 - LMT 1879 Jan 1 + 1:00:14 - SET 1900 Jan 1 # Swedish Time + 1:00 - CET 1916 May 14 23:00 + 1:00 1:00 CEST 1916 Oct 1 01:00 + 1:00 - CET 1980 + 1:00 EU CE%sT + +# Switzerland +# From Howse: +# By the end of the 18th century clocks and watches became commonplace +# and their performance improved enormously. Communities began to keep +# mean time in preference to apparent time -- Geneva from 1780 .... +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# From Whitman (who writes ``Midnight?''): +Rule Swiss 1940 only - Nov 2 0:00 1:00 S +Rule Swiss 1940 only - Dec 31 0:00 0 - +# From Shanks: +Rule Swiss 1941 1942 - May Sun>=1 2:00 1:00 S +Rule Swiss 1941 1942 - Oct Sun>=1 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Zurich 0:34:08 - LMT 1848 Sep 12 + 0:29:44 - BMT 1894 Jun # Bern Mean Time + 1:00 Swiss CE%sT 1981 + 1:00 EU CE%sT + +# Turkey +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Turkey 1916 only - May 1 0:00 1:00 S +Rule Turkey 1916 only - Oct 1 0:00 0 - +Rule Turkey 1920 only - Mar 28 0:00 1:00 S +Rule Turkey 1920 only - Oct 25 0:00 0 - +Rule Turkey 1921 only - Apr 3 0:00 1:00 S +Rule Turkey 1921 only - Oct 3 0:00 0 - +Rule Turkey 1922 only - Mar 26 0:00 1:00 S +Rule Turkey 1922 only - Oct 8 0:00 0 - +# Whitman gives 1923 Apr 28 - Sep 16 and no DST in 1924-1925; go with Shanks. +Rule Turkey 1924 only - May 13 0:00 1:00 S +Rule Turkey 1924 1925 - Oct 1 0:00 0 - +Rule Turkey 1925 only - May 1 0:00 1:00 S +Rule Turkey 1940 only - Jun 30 0:00 1:00 S +Rule Turkey 1940 only - Oct 5 0:00 0 - +Rule Turkey 1940 only - Dec 1 0:00 1:00 S +Rule Turkey 1941 only - Sep 21 0:00 0 - +Rule Turkey 1942 only - Apr 1 0:00 1:00 S +# Whitman omits the next two transition and gives 1945 Oct 1; go with Shanks. +Rule Turkey 1942 only - Nov 1 0:00 0 - +Rule Turkey 1945 only - Apr 2 0:00 1:00 S +Rule Turkey 1945 only - Oct 8 0:00 0 - +Rule Turkey 1946 only - Jun 1 0:00 1:00 S +Rule Turkey 1946 only - Oct 1 0:00 0 - +Rule Turkey 1947 1948 - Apr Sun>=16 0:00 1:00 S +Rule Turkey 1947 1950 - Oct Sun>=2 0:00 0 - +Rule Turkey 1949 only - Apr 10 0:00 1:00 S +Rule Turkey 1950 only - Apr 19 0:00 1:00 S +Rule Turkey 1951 only - Apr 22 0:00 1:00 S +Rule Turkey 1951 only - Oct 8 0:00 0 - +Rule Turkey 1962 only - Jul 15 0:00 1:00 S +Rule Turkey 1962 only - Oct 8 0:00 0 - +Rule Turkey 1964 only - May 15 0:00 1:00 S +Rule Turkey 1964 only - Oct 1 0:00 0 - +Rule Turkey 1970 1972 - May Sun>=2 0:00 1:00 S +Rule Turkey 1970 1972 - Oct Sun>=2 0:00 0 - +Rule Turkey 1973 only - Jun 3 1:00 1:00 S +Rule Turkey 1973 only - Nov 4 3:00 0 - +Rule Turkey 1974 only - Mar 31 2:00 1:00 S +Rule Turkey 1974 only - Nov 3 5:00 0 - +Rule Turkey 1975 only - Mar 30 0:00 1:00 S +Rule Turkey 1975 1976 - Oct lastSun 0:00 0 - +Rule Turkey 1976 only - Jun 1 0:00 1:00 S +Rule Turkey 1977 1978 - Apr Sun>=1 0:00 1:00 S +Rule Turkey 1977 only - Oct 16 0:00 0 - +Rule Turkey 1979 1980 - Apr Sun>=1 3:00 1:00 S +Rule Turkey 1979 1982 - Oct Mon>=11 0:00 0 - +Rule Turkey 1981 1982 - Mar lastSun 3:00 1:00 S +Rule Turkey 1983 only - Jul 31 0:00 1:00 S +Rule Turkey 1983 only - Oct 2 0:00 0 - +Rule Turkey 1985 only - Apr 20 0:00 1:00 S +Rule Turkey 1985 only - Sep 28 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Europe/Istanbul 1:55:52 - LMT 1880 + 1:56:56 - IMT 1910 Oct # Istanbul Mean Time? + 2:00 Turkey EE%sT 1978 Oct 15 + 3:00 Turkey TR%sT 1985 Apr 20 # Turkey Time + 2:00 Turkey EE%sT 1986 + 2:00 C-Eur EE%sT 1991 + 2:00 EU EE%sT +Link Europe/Istanbul Asia/Istanbul # Istanbul is in both continents. + +# Ukraine +# +# From Igor Karpov, who works for the Ukranian Ministry of Justice, +# via Garrett Wollman (2003-01-27): +# BTW, I've found the official document on this matter. It's goverment +# regulations number 509, May 13, 1996. In my poor translation it says: +# "Time in Ukraine is set to second timezone (Kiev time). Each last Sunday +# of March at 3am the time is changing to 4am and each last Sunday of +# October the time at 4am is changing to 3am" + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# Most of Ukraine since 1970 has been like Kiev. +Zone Europe/Kiev 2:02:04 - LMT 1880 + 2:02:04 - KMT 1924 May 2 # Kiev Mean Time + 2:00 - EET 1930 Jun 21 + 3:00 - MSK 1941 Sep 20 + 1:00 C-Eur CE%sT 1943 Nov 6 + 3:00 Russia MSK/MSD 1990 + 3:00 - MSK 1990 Jul 1 2:00 + 2:00 - EET 1992 + 2:00 E-Eur EE%sT 1995 + 2:00 EU EE%sT +# Ruthenia used CET 1990/1991. +Zone Europe/Uzhgorod 1:29:12 - LMT 1890 Oct + 1:00 - CET 1940 + 1:00 C-Eur CE%sT 1944 Oct + 1:00 1:00 CEST 1944 Oct 26 + 1:00 - CET 1945 Jun 29 + 3:00 Russia MSK/MSD 1990 + 3:00 - MSK 1990 Jul 1 2:00 + 1:00 - CET 1991 Mar 31 3:00 + 2:00 - EET 1992 + 2:00 E-Eur EE%sT 1995 + 2:00 EU EE%sT +# Zaporozh'ye and eastern Lugansk oblasts observed DST 1990/1991. +# Zaporozh'ye has an apostrophe, but Posix file names can't have apostrophes. +Zone Europe/Zaporozhye 2:20:40 - LMT 1880 + 2:20 - CUT 1924 May 2 # Central Ukraine T + 2:00 - EET 1930 Jun 21 + 3:00 - MSK 1941 Aug 25 + 1:00 C-Eur CE%sT 1943 Oct 25 + 3:00 Russia MSK/MSD 1991 Mar 31 2:00 + 2:00 E-Eur EE%sT 1995 + 2:00 EU EE%sT +# Central Crimea used Moscow time 1994/1997. +Zone Europe/Simferopol 2:16:24 - LMT 1880 + 2:16 - SMT 1924 May 2 # Simferopol Mean T + 2:00 - EET 1930 Jun 21 + 3:00 - MSK 1941 Nov + 1:00 C-Eur CE%sT 1944 Apr 13 + 3:00 Russia MSK/MSD 1990 + 3:00 - MSK 1990 Jul 1 2:00 + 2:00 - EET 1992 +# From Paul Eggert (1999-11-12): +# The _Economist_ (1994-05-28, p 45) reports that central Crimea switched +# from Kiev to Moscow time sometime after the January 1994 elections. +# Shanks says ``date of change uncertain'', but implies that it happened +# sometime between the 1994 DST switches. For now, guess it changed in May. + 2:00 E-Eur EE%sT 1994 May +# From IATA SSIM (1994/1997), which also says that Kerch is still like Kiev. + 3:00 E-Eur MSK/MSD 1996 Mar 31 3:00s + 3:00 1:00 MSD 1996 Oct 27 3:00s +# IATA SSIM (1997-09) says Crimea switched to EET/EEST. +# Assume it happened in March by not changing the clocks. + 3:00 Russia MSK/MSD 1997 + 3:00 - MSK 1997 Mar lastSun 1:00u + 2:00 EU EE%sT + +############################################################################### + +# One source shows that Bulgaria, Cyprus, Finland, and Greece observe DST from +# the last Sunday in March to the last Sunday in September in 1986. +# The source shows Romania changing a day later than everybody else. +# +# According to Bernard Sieloff's source, Poland is in the MET time zone but +# uses the WE DST rules. The Western USSR uses EET+1 and ME DST rules. +# Bernard Sieloff's source claims Romania switches on the same day, but at +# 00:00 standard time (i.e., 01:00 DST). It also claims that Turkey +# switches on the same day, but switches on at 01:00 standard time +# and off at 00:00 standard time (i.e., 01:00 DST) + +# ... +# Date: Wed, 28 Jan 87 16:56:27 -0100 +# From: seismo!mcvax!cgcha!wtho (Tom Hofmann) +# Message-Id: <8701281556.AA22174@cgcha.uucp> +# ... +# +# ...the European time rules are...standardized since 1981, when +# most European coun[tr]ies started DST. Before that year, only +# a few countries (UK, France, Italy) had DST, each according +# to own national rules. In 1981, however, DST started on +# 'Apr firstSun', and not on 'Mar lastSun' as in the following +# years... +# But also since 1981 there are some more national exceptions +# than listed in 'europe': Switzerland, for example, joined DST +# one year later, Denmark ended DST on 'Oct 1' instead of 'Sep +# lastSun' in 1981---I don't know how they handle now. +# +# Finally, DST ist always from 'Apr 1' to 'Oct 1' in the +# Soviet Union (as far as I know). +# +# Tom Hofmann, Scientific Computer Center, CIBA-GEIGY AG, +# 4002 Basle, Switzerland +# UUCP: ...!mcvax!cernvax!cgcha!wtho + +# ... +# Date: Wed, 4 Feb 87 22:35:22 +0100 +# From: seismo!mcvax!cwi.nl!dik (Dik T. Winter) +# ... +# +# The information from Tom Hofmann is (as far as I know) not entirely correct. +# After a request from chongo at amdahl I tried to retrieve all information +# about DST in Europe. I was able to find all from about 1969. +# +# ...standardization on DST in Europe started in about 1977 with switches on +# first Sunday in April and last Sunday in September... +# In 1981 UK joined Europe insofar that +# the starting day for both shifted to last Sunday in March. And from 1982 +# the whole of Europe used DST, with switch dates April 1 and October 1 in +# the Sov[i]et Union. In 1985 the SU reverted to standard Europe[a]n switch +# dates... +# +# It should also be remembered that time-zones are not constants; e.g. +# Portugal switched in 1976 from MET (or CET) to WET with DST... +# Note also that though there were rules for switch dates not +# all countries abided to these dates, and many individual deviations +# occurred, though not since 1982 I believe. Another note: it is always +# assumed that DST is 1 hour ahead of normal time, this need not be the +# case; at least in the Netherlands there have been times when DST was 2 hours +# in advance of normal time. +# +# ... +# dik t. winter, cwi, amsterdam, nederland +# INTERNET : dik@cwi.nl +# BITNET/EARN: dik@mcvax + +# From Bob Devine (1988-01-28): +# ... +# Greece: Last Sunday in April to last Sunday in September (iffy on dates). +# Since 1978. Change at midnight. +# ... +# Monaco: has same DST as France. +# ... diff --git a/src/timezone/data/factory b/src/timezone/data/factory new file mode 100644 index 0000000000..ba27c63269 --- /dev/null +++ b/src/timezone/data/factory @@ -0,0 +1,8 @@ +# @(#)factory 7.3 + +# For companies who don't want to put time zone specification in +# their installation procedures. When users run date, they'll get the message. +# Also useful for the "comp.sources" version. + +# Zone NAME GMTOFF RULES FORMAT +Zone Factory 0 - "Local time zone must be set--see zic manual page" diff --git a/src/timezone/data/iso3166.tab b/src/timezone/data/iso3166.tab new file mode 100644 index 0000000000..dc8a1d9e52 --- /dev/null +++ b/src/timezone/data/iso3166.tab @@ -0,0 +1,262 @@ +# ISO 3166 alpha-2 country codes +# +# @(#)iso3166.tab 1.14 +# +# From Paul Eggert (2003-02-04): +# +# This file contains a table with the following columns: +# 1. ISO 3166-1 alpha-2 country code, current as of +# ISO 3166-1 Newsletter No. V-8 (2003-07-23). See: +# +# ISO 3166 Maintenance agency (ISO 3166/MA) +# . +# 2. The usual English name for the country, +# chosen so that alphabetic sorting of subsets produces helpful lists. +# This is not the same as the English name in the ISO 3166 tables. +# +# Columns are separated by a single tab. +# The table is sorted by country code. +# +# Lines beginning with `#' are comments. +# +#country- +#code country name +AD Andorra +AE United Arab Emirates +AF Afghanistan +AG Antigua & Barbuda +AI Anguilla +AL Albania +AM Armenia +AN Netherlands Antilles +AO Angola +AQ Antarctica +AR Argentina +AS Samoa (American) +AT Austria +AU Australia +AW Aruba +AZ Azerbaijan +BA Bosnia & Herzegovina +BB Barbados +BD Bangladesh +BE Belgium +BF Burkina Faso +BG Bulgaria +BH Bahrain +BI Burundi +BJ Benin +BM Bermuda +BN Brunei +BO Bolivia +BR Brazil +BS Bahamas +BT Bhutan +BV Bouvet Island +BW Botswana +BY Belarus +BZ Belize +CA Canada +CC Cocos (Keeling) Islands +CD Congo (Dem. Rep.) +CF Central African Rep. +CG Congo (Rep.) +CH Switzerland +CI Cote d'Ivoire +CK Cook Islands +CL Chile +CM Cameroon +CN China +CO Colombia +CR Costa Rica +CS Serbia and Montenegro +CU Cuba +CV Cape Verde +CX Christmas Island +CY Cyprus +CZ Czech Republic +DE Germany +DJ Djibouti +DK Denmark +DM Dominica +DO Dominican Republic +DZ Algeria +EC Ecuador +EE Estonia +EG Egypt +EH Western Sahara +ER Eritrea +ES Spain +ET Ethiopia +FI Finland +FJ Fiji +FK Falkland Islands +FM Micronesia +FO Faeroe Islands +FR France +GA Gabon +GB Britain (UK) +GD Grenada +GE Georgia +GF French Guiana +GH Ghana +GI Gibraltar +GL Greenland +GM Gambia +GN Guinea +GP Guadeloupe +GQ Equatorial Guinea +GR Greece +GS South Georgia & the South Sandwich Islands +GT Guatemala +GU Guam +GW Guinea-Bissau +GY Guyana +HK Hong Kong +HM Heard Island & McDonald Islands +HN Honduras +HR Croatia +HT Haiti +HU Hungary +ID Indonesia +IE Ireland +IL Israel +IN India +IO British Indian Ocean Territory +IQ Iraq +IR Iran +IS Iceland +IT Italy +JM Jamaica +JO Jordan +JP Japan +KE Kenya +KG Kyrgyzstan +KH Cambodia +KI Kiribati +KM Comoros +KN St Kitts & Nevis +KP Korea (North) +KR Korea (South) +KW Kuwait +KY Cayman Islands +KZ Kazakhstan +LA Laos +LB Lebanon +LC St Lucia +LI Liechtenstein +LK Sri Lanka +LR Liberia +LS Lesotho +LT Lithuania +LU Luxembourg +LV Latvia +LY Libya +MA Morocco +MC Monaco +MD Moldova +MG Madagascar +MH Marshall Islands +MK Macedonia +ML Mali +MM Myanmar (Burma) +MN Mongolia +MO Macau +MP Northern Mariana Islands +MQ Martinique +MR Mauritania +MS Montserrat +MT Malta +MU Mauritius +MV Maldives +MW Malawi +MX Mexico +MY Malaysia +MZ Mozambique +NA Namibia +NC New Caledonia +NE Niger +NF Norfolk Island +NG Nigeria +NI Nicaragua +NL Netherlands +NO Norway +NP Nepal +NR Nauru +NU Niue +NZ New Zealand +OM Oman +PA Panama +PE Peru +PF French Polynesia +PG Papua New Guinea +PH Philippines +PK Pakistan +PL Poland +PM St Pierre & Miquelon +PN Pitcairn +PR Puerto Rico +PS Palestine +PT Portugal +PW Palau +PY Paraguay +QA Qatar +RE Reunion +RO Romania +RU Russia +RW Rwanda +SA Saudi Arabia +SB Solomon Islands +SC Seychelles +SD Sudan +SE Sweden +SG Singapore +SH St Helena +SI Slovenia +SJ Svalbard & Jan Mayen +SK Slovakia +SL Sierra Leone +SM San Marino +SN Senegal +SO Somalia +SR Suriname +ST Sao Tome & Principe +SV El Salvador +SY Syria +SZ Swaziland +TC Turks & Caicos Is +TD Chad +TF French Southern & Antarctic Lands +TG Togo +TH Thailand +TJ Tajikistan +TK Tokelau +TL East Timor +TM Turkmenistan +TN Tunisia +TO Tonga +TR Turkey +TT Trinidad & Tobago +TV Tuvalu +TW Taiwan +TZ Tanzania +UA Ukraine +UG Uganda +UM US minor outlying islands +US United States +UY Uruguay +UZ Uzbekistan +VA Vatican City +VC St Vincent +VE Venezuela +VG Virgin Islands (UK) +VI Virgin Islands (US) +VN Vietnam +VU Vanuatu +WF Wallis & Futuna +WS Samoa (Western) +YE Yemen +YT Mayotte +ZA South Africa +ZM Zambia +ZW Zimbabwe diff --git a/src/timezone/data/leapseconds b/src/timezone/data/leapseconds new file mode 100644 index 0000000000..0e7d8c8454 --- /dev/null +++ b/src/timezone/data/leapseconds @@ -0,0 +1,79 @@ +# @(#)leapseconds 7.16 + +# Allowance for leapseconds added to each timezone file. + +# The International Earth Rotation Service periodically uses leap seconds +# to keep UTC to within 0.9 s of UT1 +# (which measures the true angular orientation of the earth in space); see +# Terry J Quinn, The BIPM and the accurate measure of time, +# Proc IEEE 79, 7 (July 1991), 894-905. +# There were no leap seconds before 1972, because the official mechanism +# accounting for the discrepancy between atomic time and the earth's rotation +# did not exist until the early 1970s. + +# The correction (+ or -) is made at the given time, so lines +# will typically look like: +# Leap YEAR MON DAY 23:59:60 + R/S +# or +# Leap YEAR MON DAY 23:59:59 - R/S + +# If the leapsecond is Rolling (R) the given time is local time +# If the leapsecond is Stationary (S) the given time is UTC + +# Leap YEAR MONTH DAY HH:MM:SS CORR R/S +Leap 1972 Jun 30 23:59:60 + S +Leap 1972 Dec 31 23:59:60 + S +Leap 1973 Dec 31 23:59:60 + S +Leap 1974 Dec 31 23:59:60 + S +Leap 1975 Dec 31 23:59:60 + S +Leap 1976 Dec 31 23:59:60 + S +Leap 1977 Dec 31 23:59:60 + S +Leap 1978 Dec 31 23:59:60 + S +Leap 1979 Dec 31 23:59:60 + S +Leap 1981 Jun 30 23:59:60 + S +Leap 1982 Jun 30 23:59:60 + S +Leap 1983 Jun 30 23:59:60 + S +Leap 1985 Jun 30 23:59:60 + S +Leap 1987 Dec 31 23:59:60 + S +Leap 1989 Dec 31 23:59:60 + S +Leap 1990 Dec 31 23:59:60 + S +Leap 1992 Jun 30 23:59:60 + S +Leap 1993 Jun 30 23:59:60 + S +Leap 1994 Jun 30 23:59:60 + S +Leap 1995 Dec 31 23:59:60 + S +Leap 1997 Jun 30 23:59:60 + S +Leap 1998 Dec 31 23:59:60 + S + +# INTERNATIONAL EARTH ROTATION SERVICE (IERS) +# SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE +# +# SERVICE DE LA ROTATION TERRESTRE +# OBSERVATOIRE DE PARIS +# 61, Av. de l'Observatoire 75014 PARIS (France) +# Tel. : 33 (0) 1 40 51 22 26 +# FAX : 33 (0) 1 40 51 22 91 +# Internet : iers@obspm.fr +# +# Paris, 1 July 2003 +# +# Bulletin C 26 +# +# To authorities responsible +# for the measurement and +# distribution of time +# +# INFORMATION ON UTC - TAI +# +# NO positive leap second will be introduced at the end of December 2003. +# The difference between UTC and the International Atomic Time TAI is: +# +# from 1999 January 1, 0h UTC, until further notice: UTC-TAI = -32 s +# +# Leap seconds can be introduced in UTC at the end of the months of December +# or June, depending on the evolution of UT1-TAI. Bulletin C is mailed every +# six months, either to announce a time step in UTC, or to confirm that there +# will be no time step at the next possible date. +# +# Daniel GAMBIS +# Director +# Earth Orientation Center of IERS diff --git a/src/timezone/data/northamerica b/src/timezone/data/northamerica new file mode 100644 index 0000000000..fd6aa734ba --- /dev/null +++ b/src/timezone/data/northamerica @@ -0,0 +1,1968 @@ +# @(#)northamerica 7.67 +# also includes Central America and the Caribbean + +# This data is by no means authoritative; if you think you know better, +# go ahead and edit the file (and please send any changes to +# tz@elsie.nci.nih.gov for general use in the future). + +# From Paul Eggert (1999-03-22): +# A reliable and entertaining source about time zones is +# Derek Howse, Greenwich time and longitude, Philip Wilson Publishers (1997). + +############################################################################### + +# United States + +# From Paul Eggert (1999-03-31): +# Howse writes (pp 121-125) that time zones were invented by +# Professor Charles Ferdinand Dowd (1825-1904), +# Principal of Temple Grove Ladies' Seminary (Saratoga Springs, NY). +# His pamphlet ``A System of National Time for Railroads'' (1870) +# was the result of his proposals at the Convention of Railroad Trunk Lines +# in New York City (1869-10). His 1870 proposal was based on Washington, DC, +# but in 1872-05 he moved the proposed origin to Greenwich. +# His proposal was adopted by the railroads on 1883-11-18 at 12:00, +# and the most of the country soon followed suit. + +# From Paul Eggert (1995-12-19): +# A good source for time zone historical data in the US is +# Thomas G. Shanks, The American Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1991). +# Make sure you have the errata sheet; the book is somewhat useless without it. +# It is the source for the US and Puerto Rico entries below. + +# From Paul Eggert (2001-03-06): +# Daylight Saving Time was first suggested as a joke by Benjamin Franklin +# in his whimsical essay ``An Economical Project for Diminishing the Cost +# of Light'' published in the Journal de Paris (1784-04-26). +# Not everyone is happy with the results: +# +# I don't really care how time is reckoned so long as there is some +# agreement about it, but I object to being told that I am saving +# daylight when my reason tells me that I am doing nothing of the kind. +# I even object to the implication that I am wasting something +# valuable if I stay in bed after the sun has risen. As an admirer +# of moonlight I resent the bossy insistence of those who want to +# reduce my time for enjoying it. At the back of the Daylight Saving +# scheme I detect the bony, blue-fingered hand of Puritanism, eager +# to push people into bed earlier, and get them up earlier, to make +# them healthy, wealthy and wise in spite of themselves. +# +# -- Robertson Davies, The Diary of Samuel Marchbanks (1947), XIX, Sunday +# +# For more about the first ten years of DST in the United States, see +# Robert Garland's +# Ten years of daylight saving from the Pittsburgh standpoint +# (Carnegie Library of Pittsburgh, 1927). +# +# Shanks says that DST was called "War Time" in the US in 1918 and 1919. +# However, DST was imposed by the Standard Time Act of 1918, which +# was the first nationwide legal time standard, and apparently +# time was just called "Standard Time" or "Daylight Saving Time". + +# From Arthur David Olson: +# US Daylight Saving Time ended on the last Sunday of *October* in 1974. +# See, for example, the front page of the Saturday, 1974-10-26 +# and Sunday, 1974-10-27 editions of the Washington Post. + +# From Arthur David Olson: +# Before the Uniform Time Act of 1966 took effect in 1967, observance of +# Daylight Saving Time in the US was by local option, except during wartime. + +# From Arthur David Olson (2000-09-25): +# Last night I heard part of a rebroadcast of a 1945 Arch Oboler radio drama. +# In the introduction, Oboler spoke of "Eastern Peace Time." +# An AltaVista search turned up +# : +# "When the time is announced over the radio now, it is 'Eastern Peace +# Time' instead of the old familiar 'Eastern War Time.' Peace is wonderful." +# (August 1945) by way of confirmation. + +# From Joseph Gallant , citing +# George H. Douglas, _The Early Days of Radio Broadcasting_ (1987): +# At 7 P.M. (Eastern War Time) [on 1945-08-14], the networks were set +# to switch to London for Attlee's address, but the American people +# never got to hear his speech live. According to one press account, +# CBS' Bob Trout was first to announce the word of Japan's surrender, +# but a few seconds later, NBC, ABC and Mutual also flashed the word +# of surrender, all of whom interrupting the bells of Big Ben in +# London which were to precede Mr. Attlee's speech. + +# From Paul Eggert (2003-02-09): It was Robert St John, not Bob Trout. From +# Myrna Oliver's obituary of St John on page B16 of today's Los Angeles Times: +# +# ... a war-weary U.S. clung to radios, awaiting word of Japan's surrender. +# Any announcement from Asia would reach St. John's New York newsroom on a +# wire service teletype machine, which had prescribed signals for major news. +# Associated Press, for example, would ring five bells before spewing out +# typed copy of an important story, and 10 bells for news "of transcendental +# importance." +# +# On Aug. 14, stalling while talking steadily into the NBC networks' open +# microphone, St. John heard five bells and waited only to hear a sixth bell, +# before announcing confidently: "Ladies and gentlemen, World War II is over. +# The Japanese have agreed to our surrender terms." +# +# He had scored a 20-second scoop on other broadcasters. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule US 1918 1919 - Mar lastSun 2:00 1:00 D +Rule US 1918 1919 - Oct lastSun 2:00 0 S +Rule US 1942 only - Feb 9 2:00 1:00 W # War +Rule US 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule US 1945 only - Sep 30 2:00 0 S +Rule US 1967 max - Oct lastSun 2:00 0 S +Rule US 1967 1973 - Apr lastSun 2:00 1:00 D +Rule US 1974 only - Jan 6 2:00 1:00 D +Rule US 1975 only - Feb 23 2:00 1:00 D +Rule US 1976 1986 - Apr lastSun 2:00 1:00 D +Rule US 1987 max - Apr Sun>=1 2:00 1:00 D +# +# H.R.177 +# (introduced 1999-01-06) would change April to March in the above rule. + +# From Bob Devine (1988-01-28): +# ...Alaska (and Hawaii) had the timezone names changed in 1967. +# old new +# Pacific Standard Time(PST) -same- +# Yukon Standard Time(YST) -same- +# Central Alaska S.T. (CAT) Alaska-Hawaii St[an]dard Time (AHST) +# Nome Standard Time (NT) Bering Standard Time (BST) +# +# ...Alaska's timezone lines were redrawn in 1983 to give only 2 tz. +# The YST zone now covers nearly all of the state, AHST just part +# of the Aleutian islands. No DST. + +# From Paul Eggert (1995-12-19): +# The tables below use `NST', not `NT', for Nome Standard Time. +# I invented `CAWT' for Central Alaska War Time. + +# From U. S. Naval Observatory (1989-01-19): +# USA EASTERN 5 H BEHIND UTC NEW YORK, WASHINGTON +# USA EASTERN 4 H BEHIND UTC APR 3 - OCT 30 +# USA CENTRAL 6 H BEHIND UTC CHICAGO, HOUSTON +# USA CENTRAL 5 H BEHIND UTC APR 3 - OCT 30 +# USA MOUNTAIN 7 H BEHIND UTC DENVER +# USA MOUNTAIN 6 H BEHIND UTC APR 3 - OCT 30 +# USA PACIFIC 8 H BEHIND UTC L.A., SAN FRANCISCO +# USA PACIFIC 7 H BEHIND UTC APR 3 - OCT 30 +# USA ALASKA STD 9 H BEHIND UTC MOST OF ALASKA (AKST) +# USA ALASKA STD 8 H BEHIND UTC APR 3 - OCT 30 (AKDT) +# USA ALEUTIAN 10 H BEHIND UTC ISLANDS WEST OF 170W +# USA - " - 9 H BEHIND UTC APR 3 - OCT 30 +# USA HAWAII 10 H BEHIND UTC +# USA BERING 11 H BEHIND UTC SAMOA, MIDWAY + +# From Arthur David Olson (1989-01-21): +# The above dates are for 1988. +# Note the "AKST" and "AKDT" abbreviations, the claim that there's +# no DST in Samoa, and the claim that there is DST in Alaska and the +# Aleutians. + +# From Arthur David Olson (1988-02-13): +# Legal standard time zone names, from United States Code (1982 Edition and +# Supplement III), Title 15, Chapter 6, Section 260 and forward. First, names +# up to 1967-04-01 (when most provisions of the Uniform Time Act of 1966 +# took effect), as explained in sections 263 and 261: +# (none) +# United States standard eastern time +# United States standard mountain time +# United States standard central time +# United States standard Pacific time +# (none) +# United States standard Alaska time +# (none) +# Next, names from 1967-04-01 until 1983-11-30 (the date for +# public law 98-181): +# Atlantic standard time +# eastern standard time +# central standard time +# mountain standard time +# Pacific standard time +# Yukon standard time +# Alaska-Hawaii standard time +# Bering standard time +# And after 1983-11-30: +# Atlantic standard time +# eastern standard time +# central standard time +# mountain standard time +# Pacific standard time +# Alaska standard time +# Hawaii-Aleutian standard time +# Samoa standard time +# The law doesn't give abbreviations. +# +# From Paul Eggert (1995-12-19): +# Shanks uses 1983-10-30, not 1983-11-30, for the 1983 transitions. +# Go with Shanks. +# +# From Paul Eggert (2000-01-08), following a heads-up from Rives McDow: +# Public law 106-564 (2000-12-23) introduced the abbreviation +# "Chamorro Standard Time" for time in Guam and the Northern Marianas. +# See the file "australasia". + + +# US eastern time, represented by New York + +# Connecticut, Delaware, District of Columbia, most of Florida, +# Georgia, southeast Indiana (Clark, Dearborn, Floyd, Harrison, and +# Ohio counties), eastern Kentucky, Maine, Maryland, Massachusetts, +# New Hampshire, New Jersey, New York, North Carolina, Ohio, +# Pennsylvania, Rhode Island, South Carolina, eastern Tennessee, +# Vermont, Virginia, West Virginia + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule NYC 1920 only - Mar lastSun 2:00 1:00 D +Rule NYC 1920 only - Oct lastSun 2:00 0 S +Rule NYC 1921 1966 - Apr lastSun 2:00 1:00 D +Rule NYC 1921 1954 - Sep lastSun 2:00 0 S +Rule NYC 1955 1966 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/New_York -4:56:02 - LMT 1883 Nov 18 12:00 + -5:00 US E%sT 1920 + -5:00 NYC E%sT 1942 + -5:00 US E%sT 1946 + -5:00 NYC E%sT 1967 + -5:00 US E%sT + +# US central time, represented by Chicago + +# Alabama, Arkansas, Florida panhandle (Bay, Calhoun, Escambia, +# Gulf, Holmes, Jackson, Okaloosa, Santa Rosa, Walton, and +# Washington counties), Illinois, western Indiana +# (Gibson, Jasper, Lake, LaPorte, Newton, Porter, Posey, Spencer, +# Vanderburgh, and Warrick counties), Iowa, most of Kansas, western +# Kentucky, Louisiana, Minnesota, Mississippi, Missouri, eastern +# Nebraska, eastern North Dakota, Oklahoma, eastern South Dakota, +# western Tennessee, most of Texas, Wisconsin + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Chicago 1920 only - Jun 13 2:00 1:00 D +Rule Chicago 1920 1921 - Oct lastSun 2:00 0 S +Rule Chicago 1921 only - Mar lastSun 2:00 1:00 D +Rule Chicago 1922 1966 - Apr lastSun 2:00 1:00 D +Rule Chicago 1922 1954 - Sep lastSun 2:00 0 S +Rule Chicago 1955 1966 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Chicago -5:50:36 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1920 + -6:00 Chicago C%sT 1936 Mar 1 2:00 + -5:00 - EST 1936 Nov 15 2:00 + -6:00 Chicago C%sT 1942 + -6:00 US C%sT 1946 + -6:00 Chicago C%sT 1967 + -6:00 US C%sT +# Oliver County, ND switched from mountain to central time on 1992-10-25. +Zone America/North_Dakota/Center -6:45:12 - LMT 1883 Nov 18 12:00 + -7:00 US M%sT 1992 Oct 25 02:00 + -6:00 US C%sT + +# US mountain time, represented by Denver +# +# Colorado, far western Kansas, Montana, western +# Nebraska, Nevada border (Jackpot, Owyhee, and Mountain City), +# New Mexico, southwestern North Dakota, far eastern Oregon, +# western South Dakota, far western Texas (El Paso County, Hudspeth County, +# and Pine Springs and Nickel Creek in Culberson County), Utah, Wyoming +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Denver 1920 1921 - Mar lastSun 2:00 1:00 D +Rule Denver 1920 only - Oct lastSun 2:00 0 S +Rule Denver 1921 only - May 22 2:00 0 S +Rule Denver 1965 1966 - Apr lastSun 2:00 1:00 D +Rule Denver 1965 1966 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Denver -6:59:56 - LMT 1883 Nov 18 12:00 + -7:00 US M%sT 1920 + -7:00 Denver M%sT 1942 + -7:00 US M%sT 1946 + -7:00 Denver M%sT 1967 + -7:00 US M%sT + +# US Pacific time, represented by Los Angeles +# +# California, northern Idaho (Benewah, Bonner, Boundary, Clearwater, +# Idaho, Kootenai, Latah, Lewis, Nez Perce, and Shoshone counties), +# most of Nevada, most of Oregon, and Washington +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule CA 1948 only - Mar 14 2:00 1:00 D +Rule CA 1949 only - Jan 1 2:00 0 S +Rule CA 1950 1966 - Apr lastSun 2:00 1:00 D +Rule CA 1950 1961 - Sep lastSun 2:00 0 S +Rule CA 1962 1966 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Los_Angeles -7:52:58 - LMT 1883 Nov 18 12:00 + -8:00 US P%sT 1946 + -8:00 CA P%sT 1967 + -8:00 US P%sT + +# Alaska +# AK%sT is the modern abbreviation for -9:00 per USNO. +# +# From Paul Eggert (2001-05-30): +# Howse writes that Alaska switched from the Julian to the Gregorian calendar, +# and from east-of-GMT to west-of-GMT days, when the US bought it from Russia. +# This was on 1867-10-18, a Friday; the previous day was 1867-10-06 Julian, +# also a Friday. Include only the time zone part of this transition, +# ignoring the switch from Julian to Gregorian, since we can't represent +# the Julian calendar. +# +# As far as we know, none of the exact locations mentioned below were +# permanently inhabited in 1867 by anyone using either calendar. +# (Yakutat was colonized by the Russians in 1799, but the settlement +# was destroyed in 1805 by a Yakutat-kon war party.) However, there +# were nearby inhabitants in some cases and for our purposes perhaps +# it's best to simply use the official transition. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Juneau 15:02:19 - LMT 1867 Oct 18 + -8:57:41 - LMT 1900 Aug 20 12:00 + -8:00 - PST 1942 + -8:00 US P%sT 1946 + -8:00 - PST 1969 + -8:00 US P%sT 1983 Oct 30 2:00 + -9:00 US AK%sT +Zone America/Yakutat 14:41:05 - LMT 1867 Oct 18 + -9:18:55 - LMT 1900 Aug 20 12:00 + -9:00 - YST 1942 + -9:00 US Y%sT 1946 + -9:00 - YST 1969 + -9:00 US Y%sT 1983 Oct 30 2:00 + -9:00 US AK%sT +Zone America/Anchorage 14:00:24 - LMT 1867 Oct 18 + -9:59:36 - LMT 1900 Aug 20 12:00 + -10:00 - CAT 1942 + -10:00 US CAT/CAWT 1946 + -10:00 - CAT 1967 Apr + -10:00 - AHST 1969 + -10:00 US AH%sT 1983 Oct 30 2:00 + -9:00 US AK%sT +Zone America/Nome 12:58:21 - LMT 1867 Oct 18 + -11:01:38 - LMT 1900 Aug 20 12:00 + -11:00 - NST 1942 + -11:00 US N%sT 1946 + -11:00 - NST 1967 Apr + -11:00 - BST 1969 + -11:00 US B%sT 1983 Oct 30 2:00 + -9:00 US AK%sT +Zone America/Adak 12:13:21 - LMT 1867 Oct 18 + -11:46:38 - LMT 1900 Aug 20 12:00 + -11:00 - NST 1942 + -11:00 US N%sT 1946 + -11:00 - NST 1967 Apr + -11:00 - BST 1969 + -11:00 US B%sT 1983 Oct 30 2:00 + -10:00 US HA%sT +# Shanks writes that part of southwest Alaska (e.g. Aniak) +# switched from -11:00 to -10:00 on 1968-09-22 at 02:00, +# and another part (e.g. Akiak) made the same switch five weeks later. +# These switches don't quite make our 1970 cutoff. + +# Hawaii +# +# From Arthur David Olson: +# And then there's Hawaii. +# DST was observed for one day in 1933; +# standard time was changed by half an hour in 1947; +# it's always standard as of 1986. +# +# From Paul Eggert: +# Shanks says the 1933 experiment lasted for three weeks. Go with Shanks. +# +Zone Pacific/Honolulu -10:31:26 - LMT 1900 Jan 1 12:00 + -10:30 - HST 1933 Apr 30 2:00 + -10:30 1:00 HDT 1933 May 21 2:00 + -10:30 US H%sT 1947 Jun 8 2:00 + -10:00 - HST + +# Now we turn to US areas that have diverged from the consensus since 1970. + +# Arizona mostly uses MST. + +# From Paul Eggert (2002-10-20): +# +# The information in the rest of this paragraph is derived from the +# +# Daylight Saving Time web page (2002-01-23) maintained by the +# Arizona State Library, Archives and Public Records. +# Between 1944-01-01 and 1944-04-01 the State of Arizona used standard +# time, but by federal law railroads, airlines, bus lines, military +# personnel, and some engaged in interstate commerce continued to +# observe war (i.e., daylight saving) time. The 1944-03-17 Phoenix +# Gazette says that was the date the law changed, and that 04-01 was +# the date the state's clocks would change. In 1945 the State of +# Arizona used standard time all year, again with exceptions only as +# mandated by federal law. Arizona observed DST in 1967, but Arizona +# Laws 1968, ch. 183 (effective 1968-03-21) repealed DST. +# +# Shanks says the 1944 experiment came to an end on 1944-03-17. +# Go with the Arizona State Library instead. + +Zone America/Phoenix -7:28:18 - LMT 1883 Nov 18 12:00 + -7:00 US M%sT 1944 Jan 1 00:01 + -7:00 - MST 1944 Apr 1 00:01 + -7:00 US M%sT 1944 Oct 1 00:01 + -7:00 - MST 1967 + -7:00 US M%sT 1968 Mar 21 + -7:00 - MST +# From Arthur David Olson (1988-02-13): +# A writer from the Inter Tribal Council of Arizona, Inc., +# notes in private correspondence dated 1987-12-28 that "Presently, only the +# Navajo Nation participates in the Daylight Saving Time policy, due to its +# large size and location in three states." (The "only" means that other +# tribal nations don't use DST.) + +Link America/Denver America/Shiprock + +# Southern Idaho (Ada, Adams, Bannock, Bear Lake, Bingham, Blaine, +# Boise, Bonneville, Butte, Camas, Canyon, Caribou, Cassia, Clark, +# Custer, Elmore, Franklin, Fremont, Gem, Gooding, Jefferson, Jerome, +# Lemhi, Lincoln, Madison, Minidoka, Oneida, Owyhee, Payette, Power, +# Teton, Twin Falls, Valley, Washington counties) and eastern Oregon +# switched four weeks late in 1974. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Boise -7:44:49 - LMT 1883 Nov 18 12:00 + -8:00 US P%sT 1923 May 13 2:00 + -7:00 US M%sT 1974 + -7:00 - MST 1974 Feb 3 2:00 + -7:00 US M%sT + +# Indiana +# +# For a map of Indiana's time zone regions, see: +# +# What time is it in Indiana? +# (1999-04-06) +# +# From Paul Eggert (1995-12-19): +# Indiana generally observes either EST all year, or CST/CDT, +# but areas near Cincinnati and Louisville use those cities' timekeeping +# and in 1969 and 1970 the whole state observed daylight time; +# and there are other exceptions as noted below. +# Shanks partitions Indiana into 345 regions, each with its own time history, +# and writes ``Even newspaper reports present contradictory information.'' +# Fortunately, most of the complexity occurred before our cutoff date of 1970. +# +# Since 1970, EST-only Indiana has been like America/Indianapolis, +# with exceptions noted below for Crawford, Starke, and Switzerland counties. +# The parts of Indiana not listed below have been like America/Chicago, +# America/Louisville, or America/New_York. +# +# Other than Indianapolis, the Indiana place names are so nondescript +# that they would be ambiguous if we left them at the `America' level. +# So we reluctantly put them all in a subdirectory `America/Indiana'. +# +# Most of EST-only Indiana last observed DST in 1970. + +# From Paul Eggert (2001-03-06), following a tip by Markus Kuhn: +# Pam Belluck reported in the New York Times (2001-01-31) that the +# Indiana Legislature is considering a bill to adopt DST statewide. +# Her article mentioned Vevay, whose post office observes a different +# time zone from Danner's Hardware across the street. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Indianapolis 1941 only - Jun 22 2:00 1:00 D +Rule Indianapolis 1941 1954 - Sep lastSun 2:00 0 S +Rule Indianapolis 1946 1954 - Apr lastSun 2:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Indianapolis -5:44:38 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1920 + -6:00 Indianapolis C%sT 1942 + -6:00 US C%sT 1946 + -6:00 Indianapolis C%sT 1955 Apr 24 2:00 + -5:00 - EST 1957 Sep 29 2:00 + -6:00 - CST 1958 Apr 27 2:00 + -5:00 - EST 1969 + -5:00 US E%sT 1971 + -5:00 - EST +Link America/Indianapolis America/Indiana/Indianapolis +# +# Part of Crawford County, Indiana, last observed DST in 1975, +# and left its clocks alone in 1974. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Marengo 1951 only - Apr lastSun 2:00 1:00 D +Rule Marengo 1951 only - Sep lastSun 2:00 0 S +Rule Marengo 1954 1960 - Apr lastSun 2:00 1:00 D +Rule Marengo 1954 1960 - Sep lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Indiana/Marengo -5:45:23 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1951 + -6:00 Marengo C%sT 1961 Apr 30 2:00 + -5:00 - EST 1969 + -5:00 US E%sT 1974 Jan 6 2:00 + -6:00 1:00 CDT 1974 Oct 27 2:00 + -5:00 US E%sT 1976 + -5:00 - EST +# +# Starke County, Indiana +# From Arthur David Olson (1991-10-28): +# An article on page A3 of the Sunday, 1991-10-27 Washington Post +# notes that Starke County switched from Central time to Eastern time as of +# 1991-10-27. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Starke 1947 1961 - Apr lastSun 2:00 1:00 D +Rule Starke 1947 1954 - Sep lastSun 2:00 0 S +Rule Starke 1955 1956 - Oct lastSun 2:00 0 S +Rule Starke 1957 1958 - Sep lastSun 2:00 0 S +Rule Starke 1959 1961 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Indiana/Knox -5:46:30 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1947 + -6:00 Starke C%sT 1962 Apr 29 2:00 + -5:00 - EST 1963 Oct 27 2:00 + -6:00 US C%sT 1991 Oct 27 2:00 + -5:00 - EST +# +# Switzerland County, Indiana, last observed DST in 1972. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Indiana/Vevay -5:40:16 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1954 Apr 25 2:00 + -5:00 - EST 1969 + -5:00 US E%sT 1973 + -5:00 - EST + +# Part of Kentucky left its clocks alone in 1974. +# This also includes a part of Indiana immediately adjacent to Louisville. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Louisville 1921 only - May 1 2:00 1:00 D +Rule Louisville 1921 only - Sep 1 2:00 0 S +Rule Louisville 1941 1961 - Apr lastSun 2:00 1:00 D +Rule Louisville 1941 only - Sep lastSun 2:00 0 S +Rule Louisville 1946 only - Jun 2 2:00 0 S +Rule Louisville 1950 1955 - Sep lastSun 2:00 0 S +Rule Louisville 1956 1960 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Louisville -5:43:02 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1921 + -6:00 Louisville C%sT 1942 + -6:00 US C%sT 1946 + -6:00 Louisville C%sT 1961 Jul 23 2:00 + -5:00 - EST 1968 + -5:00 US E%sT 1974 Jan 6 2:00 + -6:00 1:00 CDT 1974 Oct 27 2:00 + -5:00 US E%sT +Link America/Louisville America/Kentucky/Louisville +# +# Wayne, Clinton, and Russell Counties, Kentucky +# +# From +# +# Lake Cumberland LIFE +# (1999-01-29) via WKYM-101.7: +# Clinton County has joined Wayne County in asking the DoT to change from +# the Central to the Eastern time zone.... The Wayne County government made +# the same request in December. And while Russell County officials have not +# taken action, the majority of respondents to a poll conducted there in +# August indicated they would like to change to "fast time" also. +# The three Lake Cumberland counties are the farthest east of any U.S. +# location in the Central time zone. +# +# From Rich Wales (2000-08-29): +# After prolonged debate, and despite continuing deep differences of opinion, +# Wayne County (central Kentucky) is switching from Central (-0600) to Eastern +# (-0500) time. They won't "fall back" this year. See Sara Shipley, +# The difference an hour makes, Nando Times (2000-08-29 15:33 -0400). +# +# From Paul Eggert (2001-07-16): +# The final rule was published in the +# +# Federal Register 65, 160 (2000-08-17), page 50154-50158. +# +# +Zone America/Kentucky/Monticello -5:39:24 - LMT 1883 Nov 18 12:00 + -6:00 US C%sT 1946 + -6:00 - CST 1968 + -6:00 US C%sT 2000 Oct 29 2:00 + -5:00 US E%sT + + +# From Rives McDow (2000-08-30): +# Here ... are all the changes in the US since 1985. +# Kearny County, KS (put all of county on central; +# previously split between MST and CST) ... 1990-10 +# Starke County, IN (from CST to EST) ... 1991-10 +# Oliver County, ND (from MST to CST) ... 1992-10 +# West Wendover, NV (from PST TO MST) ... 1999-10 +# Wayne County, KY (from CST to EST) ... 2000-10 +# +# From Paul Eggert (2001-07-17): +# We don't know where the line used to be within Kearny County, KS, +# so omit that change for now. +# See America/Indiana/Knox for the Starke County, IN change. +# See America/North_Dakota/Center for the Oliver County, ND change. +# West Wendover, NV officially switched from Pacific to mountain time on +# 1999-10-31. See the +# +# Federal Register 64, 203 (1999-10-21), page 56705-56707. +# +# However, the Federal Register says that West Wendover already operated +# on mountain time, and the rule merely made this official; +# hence a separate tz entry is not needed. + +# Michigan +# +# From Bob Devine (1988-01-28): +# Michigan didn't observe DST from 1968 to 1973. +# +# From Paul Eggert (1999-03-31): +# Shanks writes that Michigan started using standard time on 1885-09-18, +# but Howse writes (pp 124-125, referring to Popular Astronomy, 1901-01) +# that Detroit kept +# +# local time until 1900 when the City Council decreed that clocks should +# be put back twenty-eight minutes to Central Standard Time. Half the +# city obeyed, half refused. After considerable debate, the decision +# was rescinded and the city reverted to Sun time. A derisive offer to +# erect a sundial in front of the city hall was referred to the +# Committee on Sewers. Then, in 1905, Central time was adopted +# by city vote. +# +# This story is too entertaining to be false, so go with Howse over Shanks. +# +# From Paul Eggert (2001-03-06): +# Garland (1927) writes ``Cleveland and Detroit advanced their clocks +# one hour in 1914.'' This change is not in Shanks. We have no more +# info, so omit this for now. +# +# Most of Michigan observed DST from 1973 on, but was a bit late in 1975. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Detroit 1948 only - Apr lastSun 2:00 1:00 D +Rule Detroit 1948 only - Sep lastSun 2:00 0 S +Rule Detroit 1967 only - Jun 14 2:00 1:00 D +Rule Detroit 1967 only - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Detroit -5:32:11 - LMT 1905 + -6:00 - CST 1915 May 15 2:00 + -5:00 - EST 1942 + -5:00 US E%sT 1946 + -5:00 Detroit E%sT 1973 + -5:00 US E%sT 1975 + -5:00 - EST 1975 Apr 27 2:00 + -5:00 US E%sT +# +# The Michigan border with Wisconsin switched from EST to CST/CDT in 1973. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER +Rule Menominee 1946 only - Apr lastSun 2:00 1:00 D +Rule Menominee 1946 only - Sep lastSun 2:00 0 S +Rule Menominee 1966 only - Apr lastSun 2:00 1:00 D +Rule Menominee 1966 only - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Menominee -5:50:27 - LMT 1885 Sep 18 12:00 + -6:00 US C%sT 1946 + -6:00 Menominee C%sT 1969 Apr 27 2:00 + -5:00 - EST 1973 Apr 29 2:00 + -6:00 US C%sT + +# Navassa +# administered by the US Fish and Wildlife Service +# claimed by US under the provisions of the 1856 Guano Islands Act +# also claimed by Haiti +# occupied 1857/1900 by the Navassa Phosphate Co +# US lighthouse 1917/1996-09 +# currently uninhabited +# see Mark Fineman, ``An Isle Rich in Guano and Discord'', +# _Los Angeles Times_ (1998-11-10), A1, A10; it cites +# Jimmy Skaggs, _The Great Guano Rush_ (1994). + +# Old names, for S5 users + +# Link LINK-FROM LINK-TO +Link America/New_York EST5EDT +Link America/Chicago CST6CDT +Link America/Denver MST7MDT +Link America/Los_Angeles PST8PDT +Link America/Indianapolis EST +Link America/Phoenix MST +Link Pacific/Honolulu HST + +################################################################################ + + +# From Paul Eggert (1999-10-29): +# A good source for time zone historical data outside the US is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1990, +# and IATA SSIM is the source for entries after 1990. +# +# Other sources occasionally used include: +# +# Edward W. Whitman, World Time Differences, +# Whitman Publishing Co, 2 Niagara Av, Ealing, London (undated), +# which I found in the UCLA library. +# +# +# William Willett, The Waste of Daylight, 19th edition +# (1914-03) +# +# See the `europe' file for Greenland. + +# Canada + +# From Alain LaBont (1994-11-14): +# I post here the time zone abbreviations standardized in Canada +# for both English and French in the CAN/CSA-Z234.4-89 standard.... +# +# UTC Standard time Daylight savings time +# offset French English French English +# -2:30 - - HAT NDT +# -3 - - HAA ADT +# -3:30 HNT NST - - +# -4 HNA AST HAE EDT +# -5 HNE EST HAC CDT +# -6 HNC CST HAR MDT +# -7 HNR MST HAP PDT +# -8 HNP PST HAY YDT +# -9 HNY YST - - +# +# HN: Heure Normale ST: Standard Time +# HA: Heure Avance DT: Daylight saving Time +# +# A: de l'Atlantique Atlantic +# C: du Centre Central +# E: de l'Est Eastern +# M: Mountain +# N: Newfoundland +# P: du Pacifique Pacific +# R: des Rocheuses +# T: de Terre-Neuve +# Y: du Yukon Yukon +# +# From Paul Eggert (1994-11-22): +# Alas, this sort of thing must be handled by localization software. + +# Unless otherwise specified, the data for Canada are all from Shanks. + +# From Paul Eggert (2000-10-02): +# H. David Matthews and Mary Vincent's map +# +# "It's about TIME", _Canadian Geographic_ (September-October 1998) +# contains detailed boundaries for regions observing nonstandard +# time and daylight saving time arrangements in Canada circa 1998. +# +# INMS, the Institute for National Measurement Standards in Ottawa, has +# +# information about standard and daylight saving time zones in Canada. +# (updated periodically). +# Its unofficial information is often taken from Matthews and Vincent. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Canada 1918 only - Apr 14 2:00 1:00 D +Rule Canada 1918 only - Oct 31 2:00 0 S +Rule Canada 1942 only - Feb 9 2:00 1:00 W # War +Rule Canada 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule Canada 1945 only - Sep 30 2:00 0 S +Rule Canada 1974 1986 - Apr lastSun 2:00 1:00 D +Rule Canada 1974 max - Oct lastSun 2:00 0 S +Rule Canada 1987 max - Apr Sun>=1 2:00 1:00 D + + +# Newfoundland (and far southeast Labrador) + +# From Paul Eggert (2000-10-02): +# Matthews and Vincent (1998) write that Labrador should use NST/NDT, +# but the only part of Labrador that follows the rules is the +# southeast corner, including Port Hope Simpson and Mary's Harbour, +# but excluding, say, Black Tickle. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule StJohns 1917 only - Apr 8 2:00 1:00 D +Rule StJohns 1917 only - Sep 17 2:00 0 S +# Whitman gives 1919 Apr 5 and 1920 Apr 5; go with Shanks. +Rule StJohns 1919 only - May 5 23:00 1:00 D +Rule StJohns 1919 only - Aug 12 23:00 0 S +# For 1931-1935 Whitman gives Apr same date; go with Shanks. +Rule StJohns 1920 1935 - May Sun>=1 23:00 1:00 D +Rule StJohns 1920 1935 - Oct lastSun 23:00 0 S +# For 1936-1941 Whitman gives May Sun>=8 and Oct Sun>=1; go with Shanks. +Rule StJohns 1936 1941 - May Mon>=9 0:00 1:00 D +Rule StJohns 1936 1941 - Oct Mon>=2 0:00 0 S +# Whitman gives the following transitions: +# 1942 03-01/12-31, 1943 05-30/09-05, 1944 07-10/09-02, 1945 01-01/10-07 +# but go with Shanks and assume they used Canadian rules. +# For 1946-9 Whitman gives May 5,4,9,1 - Oct 1,5,3,2, and for 1950 he gives +# Apr 30 - Sep 24; go with Shanks. +Rule StJohns 1946 1950 - May Sun>=8 2:00 1:00 D +Rule StJohns 1946 1950 - Oct Sun>=2 2:00 0 S +Rule StJohns 1951 1986 - Apr lastSun 2:00 1:00 D +Rule StJohns 1951 1959 - Sep lastSun 2:00 0 S +Rule StJohns 1960 1986 - Oct lastSun 2:00 0 S +# From Paul Eggert (2000-10-02): +# INMS (2000-09-12) says that, since 1988 at least, Newfoundland switches +# at 00:01 local time. For now, assume it started in 1987. +Rule StJohns 1987 only - Apr Sun>=1 0:01 1:00 D +Rule StJohns 1987 max - Oct lastSun 0:01 0 S +Rule StJohns 1988 only - Apr Sun>=1 0:01 2:00 DD +Rule StJohns 1989 max - Apr Sun>=1 0:01 1:00 D +# St John's has an apostrophe, but Posix file names can't have apostrophes. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/St_Johns -3:30:52 - LMT 1884 + -3:30:52 StJohns N%sT 1918 + -3:30:52 Canada N%sT 1919 + -3:30:52 StJohns N%sT 1935 Mar 30 + -3:30 StJohns N%sT 1942 May 11 + -3:30 Canada N%sT 1946 + -3:30 StJohns N%sT + +# most of east Labrador + +# The name `Happy Valley-Goose Bay' is too long; use `Goose Bay'. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Goose_Bay -4:01:40 - LMT 1884 # Happy Valley-Goose Bay + -3:30:52 - NST 1918 + -3:30:52 Canada N%sT 1919 + -3:30:52 - NST 1935 Mar 30 + -3:30 - NST 1936 + -3:30 StJohns N%sT 1942 May 11 + -3:30 Canada N%sT 1946 + -3:30 StJohns N%sT 1966 Mar 15 2:00 + -4:00 StJohns A%sT + + +# west Labrador, New Brunswick, Nova Scotia, Prince Edward I + +# From Paul Eggert (1996-06-12): +# Shanks writes that since 1970 most of this region has been like Halifax. +# Many locales did not observe peacetime DST until 1972; +# Glace Bay, NS is the largest that we know of. +# Shanks also writes that Liverpool, NS was the only town in Canada to observe +# DST in 1971 but not 1970; for now we'll assume this is a typo. + +# From Paul Eggert (2000-10-02): +# INMS (2000-09-12) says that, since 1988 at least, New Brunswick switches +# at 00:01 local time. FIXME: verify and create a new Zone for this. + + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Halifax 1916 only - Apr 1 0:00 1:00 D +Rule Halifax 1916 only - Oct 1 0:00 0 S +Rule Halifax 1920 only - May 9 0:00 1:00 D +Rule Halifax 1920 only - Aug 29 0:00 0 S +Rule Halifax 1921 only - May 6 0:00 1:00 D +Rule Halifax 1921 1922 - Sep 5 0:00 0 S +Rule Halifax 1922 only - Apr 30 0:00 1:00 D +Rule Halifax 1923 1925 - May Sun>=1 0:00 1:00 D +Rule Halifax 1923 only - Sep 4 0:00 0 S +Rule Halifax 1924 only - Sep 15 0:00 0 S +Rule Halifax 1925 only - Sep 28 0:00 0 S +Rule Halifax 1926 only - May 16 0:00 1:00 D +Rule Halifax 1926 only - Sep 13 0:00 0 S +Rule Halifax 1927 only - May 1 0:00 1:00 D +Rule Halifax 1927 only - Sep 26 0:00 0 S +Rule Halifax 1928 1931 - May Sun>=8 0:00 1:00 D +Rule Halifax 1928 only - Sep 9 0:00 0 S +Rule Halifax 1929 only - Sep 3 0:00 0 S +Rule Halifax 1930 only - Sep 15 0:00 0 S +Rule Halifax 1931 1932 - Sep Mon>=24 0:00 0 S +Rule Halifax 1932 only - May 1 0:00 1:00 D +Rule Halifax 1933 only - Apr 30 0:00 1:00 D +Rule Halifax 1933 only - Oct 2 0:00 0 S +Rule Halifax 1934 only - May 20 0:00 1:00 D +Rule Halifax 1934 only - Sep 16 0:00 0 S +Rule Halifax 1935 only - Jun 2 0:00 1:00 D +Rule Halifax 1935 only - Sep 30 0:00 0 S +Rule Halifax 1936 only - Jun 1 0:00 1:00 D +Rule Halifax 1936 only - Sep 14 0:00 0 S +Rule Halifax 1937 1938 - May Sun>=1 0:00 1:00 D +Rule Halifax 1937 1941 - Sep Mon>=24 0:00 0 S +Rule Halifax 1939 only - May 28 0:00 1:00 D +Rule Halifax 1940 1941 - May Sun>=1 0:00 1:00 D +Rule Halifax 1946 1949 - Sep lastSun 2:00 0 S +Rule Halifax 1946 1949 - Apr lastSun 2:00 1:00 D +Rule Halifax 1951 1954 - Sep lastSun 2:00 0 S +Rule Halifax 1951 1954 - Apr lastSun 2:00 1:00 D +Rule Halifax 1956 1959 - Sep lastSun 2:00 0 S +Rule Halifax 1956 1959 - Apr lastSun 2:00 1:00 D +Rule Halifax 1962 1973 - Apr lastSun 2:00 1:00 D +Rule Halifax 1962 1973 - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Halifax -4:14:24 - LMT 1902 Jun 15 + -4:00 Halifax A%sT 1918 + -4:00 Canada A%sT 1919 + -4:00 Halifax A%sT 1942 Feb 9 2:00s + -4:00 Canada A%sT 1946 + -4:00 Halifax A%sT 1974 + -4:00 Canada A%sT +Zone America/Glace_Bay -3:59:48 - LMT 1902 Jun 15 + -4:00 Canada A%sT 1953 + -4:00 Halifax A%sT 1954 + -4:00 - AST 1972 + -4:00 Halifax A%sT 1974 + -4:00 Canada A%sT + + +# Ontario, Quebec + +# From Paul Eggert (1996-06-12): +# Shanks writes that since 1970 most of Ontario has been like Toronto, +# and most of Quebec has been like Montreal. +# Thunder Bay skipped DST in 1973. +# Many smaller locales did not observe peacetime DST until 1974; +# Nipigon (EST) and Rainy River (CST) are the largest that we know of. +# Far west Ontario is like Winnipeg; far east Quebec is like Halifax. + +# From Mark Brader (2003-07-26): +# [According to the Toronto Star] Orillia, Ontario, adopted DST +# effective Saturday, 1912-06-22, 22:00; the article mentions that +# Port Arthur (now part of Thunder Bay, Ontario) as well as Moose Jaw +# have already done so. In Orillia DST was to run until Saturday, +# 1912-08-31 (no time mentioned), but it was met with considerable +# hostility from certain segments of the public, and was revoked after +# only two weeks -- I copied it as Saturday, 1912-07-07, 22:00, but +# presumably that should be -07-06. (1912-06-19, -07-12; also letters +# earlier in June). +# +# Kenora, Ontario, was to abandon DST on 1914-06-01 (-05-21). + +# From Paul Eggert (1997-10-17): +# Mark Brader writes that an article in the 1997-10-14 Toronto Star +# says that Atikokan, Ontario currently does not observe DST, +# but will vote on 11-10 whether to use EST/EDT. +# He also writes that the +# +# Ontario Time Act (1990, Chapter T.9) +# +# says that Ontario east of 90W uses EST/EDT, and west of 90W uses CST/CDT. +# Officially Atikokan is therefore on CST/CDT, and most likely this report +# concerns a non-official time observed as a matter of local practice. +# For what it's worth, Shanks says that Atikokan has agreed with +# Rainy River ever since standard time was introduced. + +# From Paul Eggert (2000-10-02): +# Matthews and Vincent (1998) write that Atikokan, Pickle Lake, and +# New Osnaburgh observe CST all year, that Big Trout Lake observes +# CST/CDT, and that Upsala and Shebandowan observe EST/EDT, all in +# violation of the official Ontario rules. +# They also write that Quebec east of the -63 meridian is supposed to +# observe AST, but residents as far east as Natashquan use EST/EDT, +# and residents east of Natashquan use AST. +# We probably need Zones for far east Quebec and for Atikokan, +# but we don't know when their practices started. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Mont 1917 only - Mar 25 2:00 1:00 D +Rule Mont 1917 only - Apr 24 0:00 0 S +Rule Mont 1919 only - Mar 31 2:30 1:00 D +Rule Mont 1919 only - Oct 25 2:30 0 S +Rule Mont 1920 only - May 2 2:30 1:00 D +Rule Mont 1920 1922 - Oct Sun>=1 2:30 0 S +Rule Mont 1921 only - May 1 2:00 1:00 D +Rule Mont 1922 only - Apr 30 2:00 1:00 D +Rule Mont 1924 only - May 17 2:00 1:00 D +Rule Mont 1924 1926 - Sep lastSun 2:30 0 S +Rule Mont 1925 1926 - May Sun>=1 2:00 1:00 D +# The 1927-to-1937 rules can be expressed more simply as +# Rule Mont 1927 1937 - Apr lastSat 24:00 1:00 D +# Rule Mont 1927 1937 - Sep lastSat 24:00 0 S +# The rules below avoid use of 24:00 +# (which pre-1998 versions of zic cannot handle). +Rule Mont 1927 only - May 1 0:00 1:00 D +Rule Mont 1927 1932 - Sep lastSun 0:00 0 S +Rule Mont 1928 1931 - Apr lastSun 0:00 1:00 D +Rule Mont 1932 only - May 1 0:00 1:00 D +Rule Mont 1933 1940 - Apr lastSun 0:00 1:00 D +Rule Mont 1933 only - Oct 1 0:00 0 S +Rule Mont 1934 1939 - Sep lastSun 0:00 0 S +Rule Mont 1946 1973 - Apr lastSun 2:00 1:00 D +Rule Mont 1945 1948 - Sep lastSun 2:00 0 S +Rule Mont 1949 1950 - Oct lastSun 2:00 0 S +Rule Mont 1951 1956 - Sep lastSun 2:00 0 S +Rule Mont 1957 1973 - Oct lastSun 2:00 0 S + +Rule Toronto 1919 only - Mar 30 23:30 1:00 D +Rule Toronto 1919 only - Oct 26 0:00 0 S +Rule Toronto 1920 only - May 2 2:00 1:00 D +Rule Toronto 1920 only - Sep 26 0:00 0 S +Rule Toronto 1921 only - May 15 2:00 1:00 D +Rule Toronto 1921 only - Sep 15 2:00 0 S +Rule Toronto 1922 1923 - May Sun>=8 2:00 1:00 D +# Shanks says 1923-09-19; assume it's a typo and that "-16" was meant. +Rule Toronto 1922 1926 - Sep Sun>=15 2:00 0 S +Rule Toronto 1924 1927 - May Sun>=1 2:00 1:00 D +Rule Toronto 1927 1932 - Sep lastSun 2:00 0 S +Rule Toronto 1928 1931 - Apr lastSun 2:00 1:00 D +Rule Toronto 1932 only - May 1 2:00 1:00 D +Rule Toronto 1933 1940 - Apr lastSun 2:00 1:00 D +Rule Toronto 1933 only - Oct 1 2:00 0 S +Rule Toronto 1934 1939 - Sep lastSun 2:00 0 S +Rule Toronto 1945 1946 - Sep lastSun 2:00 0 S +Rule Toronto 1946 only - Apr lastSun 2:00 1:00 D +Rule Toronto 1947 1949 - Apr lastSun 0:00 1:00 D +Rule Toronto 1947 1948 - Sep lastSun 0:00 0 S +Rule Toronto 1949 only - Nov lastSun 0:00 0 S +Rule Toronto 1950 1973 - Apr lastSun 2:00 1:00 D +Rule Toronto 1950 only - Nov lastSun 2:00 0 S +Rule Toronto 1951 1956 - Sep lastSun 2:00 0 S +# Shanks says Toronto ended DST a week early in 1971, namely on 1971-10-24, +# but Mark Brader wrote (2003-05-31) that he checked the 1971-10-30 issue +# of the Toronto Star, and it said that DST ended 1971-10-31 as usual. +Rule Toronto 1957 1973 - Oct lastSun 2:00 0 S + +# From Paul Eggert (2003-07-27): +# Willett (1914-03) writes (p. 17) "In the Cities of Fort William, and +# Port Arthur, Ontario, the principle of the Bill has been in +# operation for the past three years, and in the City of Moose Jaw, +# Saskatchewan, for one year." + +# From David Bryan via Tory Tronrud, Director/Curator, +# Thunder Bay Museum (2003-11-12): +# There is some suggestion, however, that, by-law or not, daylight +# savings time was being practiced in Fort William and Port Arthur +# before 1909.... [I]n 1910, the line between the Eastern and Central +# Time Zones was permanently moved about two hundred miles west to +# include the Thunder Bay area.... When Canada adopted daylight +# savings time in 1916, Fort William and Port Arthur, having done so +# already, did not change their clocks.... During the Second World +# War,... [t]he cities agreed to implement DST during the summer +# months for the remainder of the war years. + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Montreal -4:54:16 - LMT 1884 + -5:00 Mont E%sT 1918 + -5:00 Canada E%sT 1919 + -5:00 Mont E%sT 1942 Feb 9 2:00s + -5:00 Canada E%sT 1946 + -5:00 Mont E%sT 1974 + -5:00 Canada E%sT +Zone America/Toronto -5:17:32 - LMT 1895 + -5:00 Canada E%sT 1919 + -5:00 Toronto E%sT 1942 Feb 9 2:00s + -5:00 Canada E%sT 1946 + -5:00 Toronto E%sT 1974 + -5:00 Canada E%sT +Zone America/Thunder_Bay -5:57:00 - LMT 1895 + -6:00 - CST 1910 + -5:00 - EST 1942 + -5:00 Canada E%sT 1970 + -5:00 Mont E%sT 1973 + -5:00 - EST 1974 + -5:00 Canada E%sT +Zone America/Nipigon -5:53:04 - LMT 1895 + -5:00 Canada E%sT 1940 Sep 29 + -5:00 1:00 EDT 1942 Feb 9 2:00s + -5:00 Canada E%sT +Zone America/Rainy_River -6:17:56 - LMT 1895 + -6:00 Canada C%sT 1940 Sep 29 + -6:00 1:00 CDT 1942 Feb 9 2:00s + -6:00 Canada C%sT + + +# Manitoba + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Winn 1916 only - Apr 23 0:00 1:00 D +Rule Winn 1916 only - Sep 17 0:00 0 S +Rule Winn 1918 only - Apr 14 2:00 1:00 D +Rule Winn 1918 only - Oct 31 2:00 0 S +Rule Winn 1937 only - May 16 2:00 1:00 D +Rule Winn 1937 only - Sep 26 2:00 0 S +Rule Winn 1942 only - Feb 9 2:00 1:00 W # War +Rule Winn 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule Winn 1945 only - Sep lastSun 2:00 0 S +Rule Winn 1946 only - May 12 2:00 1:00 D +Rule Winn 1946 only - Oct 13 2:00 0 S +Rule Winn 1947 1949 - Apr lastSun 2:00 1:00 D +Rule Winn 1947 1949 - Sep lastSun 2:00 0 S +Rule Winn 1950 only - May 1 2:00 1:00 D +Rule Winn 1950 only - Sep 30 2:00 0 S +Rule Winn 1951 1960 - Apr lastSun 2:00 1:00 D +Rule Winn 1951 1958 - Sep lastSun 2:00 0 S +Rule Winn 1959 only - Oct lastSun 2:00 0 S +Rule Winn 1960 only - Sep lastSun 2:00 0 S +Rule Winn 1963 only - Apr lastSun 2:00 1:00 D +Rule Winn 1963 only - Sep 22 2:00 0 S +Rule Winn 1966 1986 - Apr lastSun 2:00 1:00 D +Rule Winn 1966 1986 - Oct lastSun 2:00 0 S +Rule Winn 1987 max - Apr Sun>=1 2:00 1:00 D +# From Paul Eggert (2000-10-02): +# INMS (2000-09-12) says that, since 1988 at least, Manitoba switches from +# DST at 03:00 local time. For now, assume it started in 1987. +Rule Winn 1987 max - Oct lastSun 2:00s 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Winnipeg -6:28:36 - LMT 1887 Jul 16 + -6:00 Winn C%sT + + +# Saskatchewan + +# From Mark Brader (2003-07-26): +# The first actual adoption of DST in Canada was at the municipal +# level. As the [Toronto] Star put it (1912-06-07), "While people +# elsewhere have long been talking of legislation to save daylight, +# the city of Moose Jaw [Saskatchewan] has acted on its own hook." +# DST in Moose Jaw began on Saturday, 1912-06-01 (no time mentioned: +# presumably late evening, as below), and would run until "the end of +# the summer". The discrepancy between municipal time and railroad +# time was noted. + +# From Paul Eggert (2003-07-27): +# Willett (1914-03) notes that DST "has been in operation ... in the +# City of Moose Jaw, Saskatchewan, for one year." + +# From Paul Eggert (2000-10-02): +# Shanks writes that since 1970 most of this region has been like Regina. +# Some western towns (e.g. Swift Current) switched from MST/MDT to CST in 1972. +# Other western towns (e.g. Lloydminster) are like Edmonton. +# Matthews and Vincent (1998) write that Denare Beach and Creighton +# are like Winnipeg, in violation of Saskatchewan law. + +# From W. Jones (1992-11-06): +# The. . .below is based on information I got from our law library, the +# provincial archives, and the provincial Community Services department. +# A precise history would require digging through newspaper archives, and +# since you didn't say what you wanted, I didn't bother. +# +# Saskatchewan is split by a time zone meridian (105W) and over the years +# the boundary became pretty ragged as communities near it reevaluated +# their affiliations in one direction or the other. In 1965 a provincial +# referendum favoured legislating common time practices. +# +# On 15 April 1966 the Time Act (c. T-14, Revised Statutes of +# Saskatchewan 1978) was proclaimed, and established that the eastern +# part of Saskatchewan would use CST year round, that districts in +# northwest Saskatchewan would by default follow CST but could opt to +# follow Mountain Time rules (thus 1 hour difference in the winter and +# zero in the summer), and that districts in southwest Saskatchewan would +# by default follow MT but could opt to follow CST. +# +# It took a few years for the dust to settle (I know one story of a town +# on one time zone having its school in another, such that a mom had to +# serve her family lunch in two shifts), but presently it seems that only +# a few towns on the border with Alberta (e.g. Lloydminster) follow MT +# rules any more; all other districts appear to have used CST year round +# since sometime in the 1960s. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Regina 1918 only - Apr 14 2:00 1:00 D +Rule Regina 1918 only - Oct 31 2:00 0 S +Rule Regina 1930 1934 - May Sun>=1 0:00 1:00 D +Rule Regina 1930 1934 - Oct Sun>=1 0:00 0 S +Rule Regina 1937 1941 - Apr Sun>=8 0:00 1:00 D +Rule Regina 1937 only - Oct Sun>=8 0:00 0 S +Rule Regina 1938 only - Oct Sun>=1 0:00 0 S +Rule Regina 1939 1941 - Oct Sun>=8 0:00 0 S +Rule Regina 1942 only - Feb 9 2:00 1:00 W # War +Rule Regina 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule Regina 1945 only - Sep lastSun 2:00 0 S +Rule Regina 1946 only - Apr Sun>=8 2:00 1:00 D +Rule Regina 1946 only - Oct Sun>=8 2:00 0 S +Rule Regina 1947 1957 - Apr lastSun 2:00 1:00 D +Rule Regina 1947 1957 - Sep lastSun 2:00 0 S +Rule Regina 1959 only - Apr lastSun 2:00 1:00 D +Rule Regina 1959 only - Oct lastSun 2:00 0 S +# +Rule Swift 1957 only - Apr lastSun 2:00 1:00 D +Rule Swift 1957 only - Oct lastSun 2:00 0 S +Rule Swift 1959 1961 - Apr lastSun 2:00 1:00 D +Rule Swift 1959 only - Oct lastSun 2:00 0 S +Rule Swift 1960 1961 - Sep lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Regina -6:58:36 - LMT 1905 Sep + -7:00 Regina M%sT 1960 Apr lastSun 2:00 + -6:00 - CST +Zone America/Swift_Current -7:11:20 - LMT 1905 Sep + -7:00 Canada M%sT 1946 Apr lastSun 2:00 + -7:00 Regina M%sT 1950 + -7:00 Swift M%sT 1972 Apr lastSun 2:00 + -6:00 - CST + + +# Alberta + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Edm 1918 1919 - Apr Sun>=8 2:00 1:00 D +Rule Edm 1918 only - Oct 31 2:00 0 S +Rule Edm 1919 only - May 27 2:00 0 S +Rule Edm 1920 1923 - Apr lastSun 2:00 1:00 D +Rule Edm 1920 only - Oct lastSun 2:00 0 S +Rule Edm 1921 1923 - Sep lastSun 2:00 0 S +Rule Edm 1942 only - Feb 9 2:00 1:00 W # War +Rule Edm 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule Edm 1945 only - Sep lastSun 2:00 0 S +Rule Edm 1947 only - Apr lastSun 2:00 1:00 D +Rule Edm 1947 only - Sep lastSun 2:00 0 S +Rule Edm 1967 only - Apr lastSun 2:00 1:00 D +Rule Edm 1967 only - Oct lastSun 2:00 0 S +Rule Edm 1969 only - Apr lastSun 2:00 1:00 D +Rule Edm 1969 only - Oct lastSun 2:00 0 S +Rule Edm 1972 1986 - Apr lastSun 2:00 1:00 D +Rule Edm 1972 max - Oct lastSun 2:00 0 S +Rule Edm 1987 max - Apr Sun>=1 2:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Edmonton -7:33:52 - LMT 1906 Sep + -7:00 Edm M%sT + + +# British Columbia + +# From Paul Eggert (2000-10-02): +# Shanks writes that since 1970 most of this region has been like Vancouver. +# Dawson Creek uses MST. Much of east BC is like Edmonton. +# Matthews and Vincent (1998) write that Creston is like Dawson Creek. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Vanc 1918 only - Apr 14 2:00 1:00 D +Rule Vanc 1918 only - Oct 31 2:00 0 S +Rule Vanc 1942 only - Feb 9 2:00 1:00 W # War +Rule Vanc 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule Vanc 1945 only - Sep 30 2:00 0 S +Rule Vanc 1946 1986 - Apr lastSun 2:00 1:00 D +Rule Vanc 1946 only - Oct 13 2:00 0 S +Rule Vanc 1947 1961 - Sep lastSun 2:00 0 S +Rule Vanc 1962 max - Oct lastSun 2:00 0 S +Rule Vanc 1987 max - Apr Sun>=1 2:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Vancouver -8:12:28 - LMT 1884 + -8:00 Vanc P%sT +Zone America/Dawson_Creek -8:00:56 - LMT 1884 + -8:00 Canada P%sT 1947 + -8:00 Vanc P%sT 1972 Aug 30 2:00 + -7:00 - MST + + +# Northwest Territories, Nunavut, Yukon + +# From Paul Eggert (1999-10-29): +# Dawson switched to PST in 1973. Inuvik switched to MST in 1979. +# Mathew Englander (1996-10-07) gives the following refs: +# * 1967. Paragraph 28(34)(g) of the Interpretation Act, S.C. 1967-68, +# c. 7 defines Yukon standard time as UTC-9. This is still valid; +# see Interpretation Act, R.S.C. 1985, c. I-21, s. 35(1). +# * C.O. 1973/214 switched Yukon to PST on 1973-10-28 00:00. +# * O.I.C. 1980/02 established DST. +# * O.I.C. 1987/056 changed DST to Apr firstSun 2:00 to Oct lastSun 2:00. +# Shanks says Yukon's 1973-10-28 switch was at 2:00; go with Englander. + +# From Rives McDow (1999-09-04): +# Nunavut ... moved ... to incorporate the whole territory into one time zone. +# +# Nunavut moves to single time zone Oct. 31 +# +# +# From Antoine Leca (1999-09-06): +# We then need to create a new timezone for the Kitikmeot region of Nunavut +# to differentiate it from the Yellowknife region. + +# From Paul Eggert (1999-09-20): +# +# Basic Facts: The New Territory +# (1999) reports that Pangnirtung operates on eastern time, +# and that Coral Harbour does not observe DST. We don't know when +# Pangnirtung switched to eastern time; we'll guess 1995. +# We'll ignore the claim about Coral Harbour for now, +# since we have no further info. + +# From Rives McDow (1999-11-08): +# On October 31, when the rest of Nunavut went to Central time, +# Pangnirtung wobbled. Here is the result of their wobble: +# +# The following businesses and organizations in Pangnirtung use Central Time: +# +# First Air, Power Corp, Nunavut Construction, Health Center, RCMP, +# Eastern Arctic National Parks, A & D Specialist +# +# The following businesses and organizations in Pangnirtung use Eastern Time: +# +# Hamlet office, All other businesses, Both schools, Airport operator +# +# This has made for an interesting situation there, which warranted the news. +# No one there that I spoke with seems concerned, or has plans to +# change the local methods of keeping time, as it evidently does not +# really interfere with any activities or make things difficult locally. +# They plan to celebrate New Year's turn-over twice, one hour apart, +# so it appears that the situation will last at least that long. +# The Nunavut Intergovernmental Affairs hopes that they will "come to +# their senses", but the locals evidently don't see any problem with +# the current state of affairs. + +# From Michaela Rodrigue, writing in the +# +# Nunatsiaq News (1999-11-19): +# Clyde River, Pangnirtung and Sanikiluaq now operate with two time zones, +# central - or Nunavut time - for government offices, and eastern time +# for municipal offices and schools.... Igloolik [was similar but then] +# made the switch to central time on Saturday, Nov. 6. + +# From Paul Eggert (2000-10-02): +# Matthews and Vincent (1998) say the following, but we lack histories +# for these potential new Zones. +# +# The Canadian Forces station at Alert uses Eastern Time while the +# handful of residents at the Eureka weather station [in the Central +# zone] skip daylight savings. Baffin Island, which is crossed by the +# Central, Eastern and Atlantic Time zones only uses Eastern Time. +# Gjoa Haven, Taloyoak and Pelly Bay all use Mountain instead of +# Central Time and Southampton Island [in the Central zone] is not +# required to use daylight savings. + +# From +# +# Nunavut now has two time zones +# (2000-11-10): +# The Nunavut government would allow its employees in Kugluktuk and +# Cambridge Bay to operate on central time year-round, putting them +# one hour behind the rest of Nunavut for six months during the winter. +# At the end of October the two communities had rebelled against +# Nunavut's unified time zone, refusing to shift to eastern time with +# the rest of the territory for the winter. Cambridge Bay remained on +# central time, while Kugluktuk, even farther west, reverted to +# mountain time, which they had used before the advent of Nunavut's +# unified time zone in 1999. +# +# From Rives McDow (2001-01-20), quoting the Nunavut government: +# The preceding decision came into effect at midnight, Saturday Nov 4, 2000. + +# From Paul Eggert (2000-12-04): +# Let's just keep track of the official times for now. + +# From Rives McDow (2001-03-07): +# The premier of Nunavut has issued a ministerial statement advising +# that effective 2001-04-01, the territory of Nunavut will revert +# back to three time zones (mountain, central, and eastern). Of the +# cities in Nunavut, Coral Harbor is the only one that I know of that +# has said it will not observe dst, staying on EST year round. I'm +# checking for more info, and will get back to you if I come up with +# more. +# [Also see (2001-03-09).] + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule NT_YK 1918 only - Apr 14 2:00 1:00 D +Rule NT_YK 1918 only - Oct 27 2:00 0 S +Rule NT_YK 1919 only - May 25 2:00 1:00 D +Rule NT_YK 1919 only - Nov 1 0:00 0 S +Rule NT_YK 1942 only - Feb 9 2:00 1:00 W # War +Rule NT_YK 1945 only - Aug 14 23:00u 1:00 P # Peace +Rule NT_YK 1945 only - Sep 30 2:00 0 S +Rule NT_YK 1965 only - Apr lastSun 0:00 2:00 DD +Rule NT_YK 1965 only - Oct lastSun 2:00 0 S +Rule NT_YK 1980 1986 - Apr lastSun 2:00 1:00 D +Rule NT_YK 1980 max - Oct lastSun 2:00 0 S +Rule NT_YK 1987 max - Apr Sun>=1 2:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Pangnirtung -4:22:56 - LMT 1884 + -4:00 NT_YK A%sT 1995 Apr Sun>=1 2:00 + -5:00 Canada E%sT 1999 Oct 31 2:00 + -6:00 Canada C%sT 2000 Oct 29 2:00 + -5:00 Canada E%sT +Zone America/Iqaluit -4:33:52 - LMT 1884 # Frobisher Bay before 1987 + -5:00 NT_YK E%sT 1999 Oct 31 2:00 + -6:00 Canada C%sT 2000 Oct 29 2:00 + -5:00 Canada E%sT +Zone America/Rankin_Inlet -6:08:40 - LMT 1884 + -6:00 NT_YK C%sT 2000 Oct 29 2:00 + -5:00 - EST 2001 Apr 1 3:00 + -6:00 Canada C%sT +Zone America/Cambridge_Bay -7:00:20 - LMT 1884 + -7:00 NT_YK M%sT 1999 Oct 31 2:00 + -6:00 Canada C%sT 2000 Oct 29 2:00 + -5:00 - EST 2000 Nov 5 0:00 + -6:00 - CST 2001 Apr 1 3:00 + -7:00 Canada M%sT +Zone America/Yellowknife -7:37:24 - LMT 1884 + -7:00 NT_YK M%sT +Zone America/Inuvik -8:54:00 - LMT 1884 + -8:00 NT_YK P%sT 1979 Apr lastSun 2:00 + -7:00 NT_YK M%sT +Zone America/Whitehorse -9:00:12 - LMT 1900 Aug 20 + -9:00 NT_YK Y%sT 1966 Jul 1 2:00 + -8:00 NT_YK P%sT +Zone America/Dawson -9:17:40 - LMT 1900 Aug 20 + -9:00 NT_YK Y%sT 1973 Oct 28 0:00 + -8:00 NT_YK P%sT + + +############################################################################### + +# Mexico + +# From Paul Eggert (2001-03-05): +# The Investigation and Analysis Service of the +# Mexican Library of Congress (MLoC) has published a +# +# history of Mexican local time (in Spanish) +# . +# +# Here are the discrepancies between Shanks and the MLoC. +# (In all cases we go with the MLoC.) +# Shanks reports that Baja was at -8:00 in 1922/1923. +# Shanks says the 1930 transition in Baja was 1930-11-16. +# Shanks reports no DST during summer 1931. +# Shanks reports a transition at 1032-03-30 23:00, not 1932-04-01. +# Shanks does not report transitions for Baja in 1945 or 1948. +# Shanks reports southern Mexico transitions on 1981-12-01, not 12-23. +# Shanks says Quintana Roo switched to -6:00 on 1982-12-02, and to -5:00 +# on 1997-10-26 at 02:00. + +# From Gwillim Law (2001-02-20): +# There are some other discrepancies between the Decrees page and the +# tz database. I think they can best be explained by supposing that +# the researchers who prepared the Decrees page failed to find some of +# the relevant documents. + +# From Paul Eggert (2000-07-26): +# Shanks gives 1942-04-01 instead of 1942-04-24, and omits the 1981 +# and 1988 DST experiments. Go with spin.com.mx. + +# From Alan Perry (1996-02-15): +# A guy from our Mexico subsidiary finally found the Presidential Decree +# outlining the timezone changes in Mexico. +# +# ------------- Begin Forwarded Message ------------- +# +# I finally got my hands on the Official Presidential Decree that sets up the +# rules for the DST changes. The rules are: +# +# 1. The country is divided in 3 timezones: +# - Baja California Norte (the Mexico/BajaNorte TZ) +# - Baja California Sur, Nayarit, Sinaloa and Sonora (the Mexico/BajaSur TZ) +# - The rest of the country (the Mexico/General TZ) +# +# 2. From the first Sunday in April at 2:00 AM to the last Sunday in October +# at 2:00 AM, the times in each zone are as follows: +# BajaNorte: GMT+7 +# BajaSur: GMT+6 +# General: GMT+5 +# +# 3. The rest of the year, the times are as follows: +# BajaNorte: GMT+8 +# BajaSur: GMT+7 +# General: GMT+6 +# +# The Decree was published in Mexico's Official Newspaper on January 4th. +# +# -------------- End Forwarded Message -------------- +# From Paul Eggert (1996-06-12): +# For an English translation of the decree, see +# +# ``Diario Oficial: Time Zone Changeover'' (1996-01-04). +# + +# From Rives McDow (1998-10-08): +# The State of Quintana Roo has reverted back to central STD and DST times +# (i.e. UTC -0600 and -0500 as of 1998-08-02). + +# From Rives McDow (2000-01-10): +# Effective April 4, 1999 at 2:00 AM local time, Sonora changed to the time +# zone 5 hours from the International Date Line, and will not observe daylight +# savings time so as to stay on the same time zone as the southern part of +# Arizona year round. + +# From Jesper Norgaard, translating +# (2001-01-17): +# In Oaxaca, the 55.000 teachers from the Section 22 of the National +# Syndicate of Education Workers, refuse to apply daylight saving each +# year, so that the more than 10,000 schools work at normal hour the +# whole year. + +# From Gwillim Law (2001-01-19): +# ... says +# (translated):... +# January 17, 2000 - The Energy Secretary, Ernesto Martens, announced +# that Summer Time will be reduced from seven to five months, starting +# this year.... +# +# [translated], says "summer time will ... take effect on the first Sunday +# in May, and end on the last Sunday of September. + +# From Arthur David Olson (2001-01-25): +# The 2001-01-24 traditional Washington Post contained the page one +# story "Timely Issue Divides Mexicans."... +# http://www.washingtonpost.com/wp-dyn/articles/A37383-2001Jan23.html +# ... Mexico City Mayor Lopez Obrador "...is threatening to keep +# Mexico City and its 20 million residents on a different time than +# the rest of the country..." In particular, Lopez Obrador would abolish +# observation of Daylight Saving Time. + +# +# Official statute published by the Energy Department +# (2001-02-01) shows Baja and Chihauhua as still using US DST rules, +# and Sonora with no DST. This was reported by Jesper Norgaard (2001-02-03). + +# From Paul Eggert (2001-03-03): +# +# +# James F. Smith writes in today's LA Times +# +# * Sonora will continue to observe standard time. +# * Last week Mexico City's mayor Andres Manuel Lopez Obrador decreed that +# the Federal District will not adopt DST. +# * 4 of 16 district leaders announced they'll ignore the decree. +# * The decree does not affect federal-controlled facilities including +# the airport, banks, hospitals, and schools. +# +# For now we'll assume that the Federal District will bow to federal rules. + +# From Jesper Norgaard (2001-04-01): +# I found some references to the Mexican application of daylight +# saving, which modifies what I had already sent you, stating earlier +# that a number of northern Mexican states would go on daylight +# saving. The modification reverts this to only cover Baja California +# (Norte), while all other states (except Sonora, who has no daylight +# saving all year) will follow the original decree of president +# Vicente Fox, starting daylight saving May 6, 2001 and ending +# September 30, 2001. +# References: "Diario de Monterrey" +# Palabra (2001-03-31) + +# From Reuters (2001-09-04): +# Mexico's Supreme Court on Tuesday declared that daylight savings was +# unconstitutional in Mexico City, creating the possibility the +# capital will be in a different time zone from the rest of the nation +# next year.... The Supreme Court's ruling takes effect at 2:00 +# a.m. (0800 GMT) on Sept. 30, when Mexico is scheduled to revert to +# standard time. "This is so residents of the Federal District are not +# subject to unexpected time changes," a statement from the court said. + +# From Jesper Norgaard Welen (2002-03-12): +# ... consulting my local grocery store(!) and my coworkers, they all insisted +# that a new decision had been made to reinstate US style DST in Mexico.... +# http://www.conae.gob.mx/ahorro/horaver2001_m1_2002.html (2002-02-20) +# confirms this. Sonora as usual is the only state where DST is not applied. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Mexico 1939 only - Feb 5 0:00 1:00 D +Rule Mexico 1939 only - Jun 25 0:00 0 S +Rule Mexico 1940 only - Dec 9 0:00 1:00 D +Rule Mexico 1941 only - Apr 1 0:00 0 S +Rule Mexico 1943 only - Dec 16 0:00 1:00 W # War +Rule Mexico 1944 only - May 1 0:00 0 S +Rule Mexico 1950 only - Feb 12 0:00 1:00 D +Rule Mexico 1950 only - Jul 30 0:00 0 S +Rule Mexico 1996 2000 - Apr Sun>=1 2:00 1:00 D +Rule Mexico 1996 2000 - Oct lastSun 2:00 0 S +Rule Mexico 2001 only - May Sun>=1 2:00 1:00 D +Rule Mexico 2001 only - Sep lastSun 2:00 0 S +Rule Mexico 2002 max - Apr Sun>=1 2:00 1:00 D +Rule Mexico 2002 max - Oct lastSun 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# Quintana Roo +Zone America/Cancun -5:47:04 - LMT 1922 Jan 1 0:12:56 + -6:00 - CST 1981 Dec 23 + -5:00 Mexico E%sT 1998 Aug 2 2:00 + -6:00 Mexico C%sT +# Campeche, Yucatan +Zone America/Merida -5:58:28 - LMT 1922 Jan 1 0:01:32 + -6:00 - CST 1981 Dec 23 + -5:00 - EST 1982 Dec 2 + -6:00 Mexico C%sT +# Coahuila, Durango, Nuevo Leon, Tamaulipas +Zone America/Monterrey -6:41:16 - LMT 1921 Dec 31 23:18:44 + -6:00 - CST 1988 + -6:00 US C%sT 1989 + -6:00 Mexico C%sT +# Central Mexico +Zone America/Mexico_City -6:36:36 - LMT 1922 Jan 1 0:23:24 + -7:00 - MST 1927 Jun 10 23:00 + -6:00 - CST 1930 Nov 15 + -7:00 - MST 1931 May 1 23:00 + -6:00 - CST 1931 Oct + -7:00 - MST 1932 Apr 1 + -6:00 Mexico C%sT 2001 Sep 30 02:00 + -6:00 - CST 2002 Feb 20 + -6:00 Mexico C%sT +# Chihuahua +Zone America/Chihuahua -7:04:20 - LMT 1921 Dec 31 23:55:40 + -7:00 - MST 1927 Jun 10 23:00 + -6:00 - CST 1930 Nov 15 + -7:00 - MST 1931 May 1 23:00 + -6:00 - CST 1931 Oct + -7:00 - MST 1932 Apr 1 + -6:00 - CST 1996 + -6:00 Mexico C%sT 1998 + -6:00 - CST 1998 Apr Sun>=1 3:00 + -7:00 Mexico M%sT +# Sonora +Zone America/Hermosillo -7:23:52 - LMT 1921 Dec 31 23:36:08 + -7:00 - MST 1927 Jun 10 23:00 + -6:00 - CST 1930 Nov 15 + -7:00 - MST 1931 May 1 23:00 + -6:00 - CST 1931 Oct + -7:00 - MST 1932 Apr 1 + -6:00 - CST 1942 Apr 24 + -7:00 - MST 1949 Jan 14 + -8:00 - PST 1970 + -7:00 Mexico M%sT 1999 + -7:00 - MST +# Baja California Sur, Nayarit, Sinaloa +Zone America/Mazatlan -7:05:40 - LMT 1921 Dec 31 23:54:20 + -7:00 - MST 1927 Jun 10 23:00 + -6:00 - CST 1930 Nov 15 + -7:00 - MST 1931 May 1 23:00 + -6:00 - CST 1931 Oct + -7:00 - MST 1932 Apr 1 + -6:00 - CST 1942 Apr 24 + -7:00 - MST 1949 Jan 14 + -8:00 - PST 1970 + -7:00 Mexico M%sT +# Baja California +Zone America/Tijuana -7:48:04 - LMT 1922 Jan 1 0:11:56 + -7:00 - MST 1924 + -8:00 - PST 1927 Jun 10 23:00 + -7:00 - MST 1930 Nov 15 + -8:00 - PST 1931 Apr 1 + -8:00 1:00 PDT 1931 Sep 30 + -8:00 - PST 1942 Apr 24 + -8:00 1:00 PWT 1945 Nov 12 + -8:00 - PST 1948 Apr 5 + -8:00 1:00 PDT 1949 Jan 14 + -8:00 - PST 1954 + -8:00 CA P%sT 1961 + -8:00 - PST 1976 + -8:00 US P%sT 1996 + -8:00 Mexico P%sT 2001 + -8:00 US P%sT 2002 Feb 20 + -8:00 Mexico P%sT +# From Paul Eggert (2001-03-05): +# Formerly there was an America/Ensenada zone, which differed from +# America/Tijuana only in that it did not observe DST from 1976 +# through 1995. This was as per Shanks. However, Guy Harris reports +# that the 1987 OAG says "Only Ensenada, Mexicale, San Felipe and +# Tijuana observe DST," which contradicts Shanks but does imply that +# DST-observance was a town-by-town matter back then. This concerns +# data after 1970 so most likely there should be at least one Zone +# other than America/Tijuana for Baja, but it's not clear yet what its +# name or contents should be. +# +# Revillagigedo Is +# no information + +############################################################################### + +# Anguilla +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Anguilla -4:12:16 - LMT 1912 Mar 2 + -4:00 - AST + +# Antigua and Barbuda +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Antigua -4:07:12 - LMT 1912 Mar 2 + -5:00 - EST 1951 + -4:00 - AST + +# Bahamas +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Bahamas 1964 max - Oct lastSun 2:00 0 S +Rule Bahamas 1964 1986 - Apr lastSun 2:00 1:00 D +Rule Bahamas 1987 max - Apr Sun>=1 2:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Nassau -5:09:24 - LMT 1912 Mar 2 + -5:00 Bahamas E%sT + +# Barbados +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Barb 1977 only - Jun 12 2:00 1:00 D +Rule Barb 1977 1978 - Oct Sun>=1 2:00 0 S +Rule Barb 1978 1980 - Apr Sun>=15 2:00 1:00 D +Rule Barb 1979 only - Sep 30 2:00 0 S +Rule Barb 1980 only - Sep 25 2:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Barbados -3:58:28 - LMT 1924 # Bridgetown + -3:58:28 - BMT 1932 # Bridgetown Mean Time + -4:00 Barb A%sT + +# Belize +# Whitman entirely disagrees with Shanks; go with Shanks. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Belize 1918 1942 - Oct Sun>=2 0:00 0:30 HD +Rule Belize 1919 1943 - Feb Sun>=9 0:00 0 S +Rule Belize 1973 only - Dec 5 0:00 1:00 D +Rule Belize 1974 only - Feb 9 0:00 0 S +Rule Belize 1982 only - Dec 18 0:00 1:00 D +Rule Belize 1983 only - Feb 12 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Belize -5:52:48 - LMT 1912 Apr + -6:00 Belize C%sT + +# Bermuda +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/Bermuda -4:19:04 - LMT 1930 Jan 1 2:00 # Hamilton + -4:00 - AST 1974 Apr 28 2:00 + -4:00 Bahamas A%sT + +# Cayman Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Cayman -5:25:32 - LMT 1890 # Georgetown + -5:07:12 - KMT 1912 Feb # Kingston Mean Time + -5:00 - EST + +# Costa Rica +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule CR 1979 1980 - Feb lastSun 0:00 1:00 D +Rule CR 1979 1980 - Jun Sun>=1 0:00 0 S +Rule CR 1991 1992 - Jan Sat>=15 0:00 1:00 D +# IATA SSIM (1991-09) says the following was at 1:00; go with Shanks. +Rule CR 1991 only - Jul 1 0:00 0 S +Rule CR 1992 only - Mar 15 0:00 0 S +# There are too many San Joses elsewhere, so we'll use `Costa Rica'. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Costa_Rica -5:36:20 - LMT 1890 # San Jose + -5:36:20 - SJMT 1921 Jan 15 # San Jose Mean Time + -6:00 CR C%sT +# Coco +# no information; probably like America/Costa_Rica + +# Cuba + +# From Arthur David Olson (1999-03-29): +# The 1999-03-28 exhibition baseball game held in Havana, Cuba, between +# the Cuban National Team and the Baltimore Orioles was carried live on +# the Orioles Radio Network, including affiliate WTOP in Washington, DC. +# During the game, play-by-play announcer Jim Hunter noted that +# "We'll be losing two hours of sleep...Cuba switched to Daylight Saving +# Time today." (The "two hour" remark referred to losing one hour of +# sleep on 1999-03-28--when the announcers were in Cuba as it switched +# to DST--and one more hour on 1999-04-04--when the announcers will have +# returned to Baltimore, which switches on that date.) + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Cuba 1928 only - Jun 10 0:00 1:00 D +Rule Cuba 1928 only - Oct 10 0:00 0 S +Rule Cuba 1940 1942 - Jun Sun>=1 0:00 1:00 D +Rule Cuba 1940 1942 - Sep Sun>=1 0:00 0 S +Rule Cuba 1945 1946 - Jun Sun>=1 0:00 1:00 D +Rule Cuba 1945 1946 - Sep Sun>=1 0:00 0 S +Rule Cuba 1965 only - Jun 1 0:00 1:00 D +Rule Cuba 1965 only - Sep 30 0:00 0 S +Rule Cuba 1966 only - May 29 0:00 1:00 D +Rule Cuba 1966 only - Oct 2 0:00 0 S +Rule Cuba 1967 only - Apr 8 0:00 1:00 D +Rule Cuba 1967 1968 - Sep Sun>=8 0:00 0 S +Rule Cuba 1968 only - Apr 14 0:00 1:00 D +Rule Cuba 1969 1977 - Apr lastSun 0:00 1:00 D +Rule Cuba 1969 1971 - Oct lastSun 0:00 0 S +Rule Cuba 1972 1974 - Oct 8 0:00 0 S +Rule Cuba 1975 1977 - Oct lastSun 0:00 0 S +Rule Cuba 1978 only - May 7 0:00 1:00 D +Rule Cuba 1978 1990 - Oct Sun>=8 0:00 0 S +Rule Cuba 1979 1980 - Mar Sun>=15 0:00 1:00 D +Rule Cuba 1981 1985 - May Sun>=5 0:00 1:00 D +Rule Cuba 1986 1989 - Mar Sun>=14 0:00 1:00 D +Rule Cuba 1990 1997 - Apr Sun>=1 0:00 1:00 D +Rule Cuba 1991 1995 - Oct Sun>=8 0:00s 0 S +Rule Cuba 1996 only - Oct 6 0:00s 0 S +Rule Cuba 1997 only - Oct 12 0:00s 0 S +Rule Cuba 1998 1999 - Mar lastSun 0:00s 1:00 D +Rule Cuba 1998 max - Oct lastSun 0:00s 0 S +Rule Cuba 2000 max - Apr Sun>=1 0:00s 1:00 D + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Havana -5:29:28 - LMT 1890 + -5:29:36 - HMT 1925 Jul 19 12:00 # Havana MT + -5:00 Cuba C%sT + +# Dominica +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Dominica -4:05:36 - LMT 1911 Jul 1 0:01 # Roseau + -4:00 - AST + +# Dominican Republic + +# From Steffen Thorsen (2000-10-30): +# Enrique Morales reported to me that the Dominican Republic has changed the +# time zone to Eastern Standard Time as of Sunday 29 at 2 am.... +# http://www.listin.com.do/antes/261000/republica/princi.html + +# From Paul Eggert (2000-12-04): +# That URL (2000-10-26, in Spanish) says they planned to use US-style DST. + +# From Rives McDow (2000-12-01): +# Dominican Republic changed its mind and presidential decree on Tuesday, +# November 28, 2000, with a new decree. On Sunday, December 3 at 1:00 AM the +# Dominican Republic will be reverting to 8 hours from the International Date +# Line, and will not be using DST in the foreseeable future. The reason they +# decided to use DST was to be in synch with Puerto Rico, who was also going +# to implement DST. When Puerto Rico didn't implement DST, the president +# decided to revert. + + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule DR 1966 only - Oct 30 0:00 1:00 D +Rule DR 1967 only - Feb 28 0:00 0 S +Rule DR 1969 1973 - Oct lastSun 0:00 0:30 HD +Rule DR 1970 only - Feb 21 0:00 0 S +Rule DR 1971 only - Jan 20 0:00 0 S +Rule DR 1972 1974 - Jan 21 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Santo_Domingo -4:39:36 - LMT 1890 + -4:40 - SDMT 1933 Apr 1 12:00 # S. Dom. MT + -5:00 DR E%sT 1974 Oct 27 + -4:00 - AST 2000 Oct 29 02:00 + -5:00 US E%sT 2000 Dec 3 01:00 + -4:00 - AST + +# El Salvador +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Salv 1987 1988 - May Sun>=1 0:00 1:00 D +Rule Salv 1987 1988 - Sep lastSun 0:00 0 S +# There are too many San Salvadors elsewhere, so use America/El_Salvador +# instead of America/San_Salvador. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/El_Salvador -5:56:48 - LMT 1921 # San Salvador + -6:00 Salv C%sT + +# Grenada +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Grenada -4:07:00 - LMT 1911 Jul # St George's + -4:00 - AST + +# Guadeloupe +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Guadeloupe -4:06:08 - LMT 1911 Jun 8 # Pointe a Pitre + -4:00 - AST + +# Guatemala +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Guat 1973 only - Nov 25 0:00 1:00 D +Rule Guat 1974 only - Feb 24 0:00 0 S +Rule Guat 1983 only - May 21 0:00 1:00 D +Rule Guat 1983 only - Sep 22 0:00 0 S +Rule Guat 1991 only - Mar 23 0:00 1:00 D +Rule Guat 1991 only - Sep 7 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Guatemala -6:02:04 - LMT 1918 Oct 5 + -6:00 Guat C%sT + +# Haiti +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Haiti 1983 only - May 8 0:00 1:00 D +Rule Haiti 1984 1987 - Apr lastSun 0:00 1:00 D +Rule Haiti 1983 1987 - Oct lastSun 0:00 0 S +# Shanks says AT is 2:00, but IATA SSIM (1991/1997) says 1:00s. Go with IATA. +Rule Haiti 1988 1997 - Apr Sun>=1 1:00s 1:00 D +Rule Haiti 1988 1997 - Oct lastSun 1:00s 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Port-au-Prince -4:49:20 - LMT 1890 + -4:49 - PPMT 1917 Jan 24 12:00 # P-a-P MT + -5:00 Haiti E%sT + +# Honduras +# Shanks says 1921 Jan 1; go with Whitman's more precise Apr 1. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Tegucigalpa -5:48:52 - LMT 1921 Apr + -6:00 Salv C%sT +# +# Great Swan I ceded by US to Honduras in 1972 + +# Jamaica + +# From Bob Devine (1988-01-28): +# Follows US rules. + +# From U. S. Naval Observatory (1989-01-19): +# JAMAICA 5 H BEHIND UTC + +# From Shanks: +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Jamaica -5:07:12 - LMT 1890 # Kingston + -5:07:12 - KMT 1912 Feb # Kingston Mean Time + -5:00 - EST 1974 Apr 28 2:00 + -5:00 US E%sT 1984 + -5:00 - EST + +# Martinique +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Martinique -4:04:20 - LMT 1890 # Fort-de-France + -4:04:20 - FFMT 1911 May # Fort-de-France MT + -4:00 - AST 1980 Apr 6 + -4:00 1:00 ADT 1980 Sep 28 + -4:00 - AST + +# Montserrat +# From Paul Eggert (1997-08-31): +# Recent volcanic eruptions have forced evacuation of Plymouth, the capital. +# Luckily, Olveston, the current de facto capital, has the same longitude. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Montserrat -4:08:52 - LMT 1911 Jul 1 0:01 # Olveston + -4:00 - AST + +# Nicaragua +# +# From Steffen Thorsen (1998-12-29): +# Nicaragua seems to be back at -6:00 but I have not been able to find when +# they changed from -5:00. +# +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Nic 1979 1980 - Mar Sun>=16 0:00 1:00 D +Rule Nic 1979 1980 - Jun Mon>=23 0:00 0 S +Rule Nic 1992 only - Jan 1 4:00 1:00 D +Rule Nic 1992 only - Sep 24 0:00 0 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Managua -5:45:08 - LMT 1890 + -5:45:12 - MMT 1934 Jun 23 # Managua Mean Time? + -6:00 - CST 1973 May + -5:00 - EST 1975 Feb 16 + -6:00 Nic C%sT 1993 Jan 1 4:00 + -5:00 - EST 1998 Dec + -6:00 - CST + +# Panama +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Panama -5:18:08 - LMT 1890 + -5:19:36 - CMT 1908 Apr 22 # Colon Mean Time + -5:00 - EST + +# Puerto Rico +# There are too many San Juans elsewhere, so we'll use `Puerto_Rico'. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Puerto_Rico -4:24:25 - LMT 1899 Mar 28 12:00 # San Juan + -4:00 - AST 1942 May 3 + -4:00 1:00 AWT 1945 Sep 30 2:00 + -4:00 - AST + +# St Kitts-Nevis +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/St_Kitts -4:10:52 - LMT 1912 Mar 2 # Basseterre + -4:00 - AST + +# St Lucia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/St_Lucia -4:04:00 - LMT 1890 # Castries + -4:04:00 - CMT 1912 # Castries Mean Time + -4:00 - AST + +# St Pierre and Miquelon +# There are too many St Pierres elsewhere, so we'll use `Miquelon'. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Miquelon -3:44:40 - LMT 1911 May 15 # St Pierre + -4:00 - AST 1980 May + -3:00 - PMST 1987 # Pierre & Miquelon Time + -3:00 Canada PM%sT + +# St Vincent and the Grenadines +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/St_Vincent -4:04:56 - LMT 1890 # Kingstown + -4:04:56 - KMT 1912 # Kingstown Mean Time + -4:00 - AST + +# Turks and Caicos +# From Paul Eggert (1998-08-06): +# Shanks says they use US DST rules, but IATA SSIM (1991/1998) +# says they switch at midnight. Go with IATA SSIM. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule TC 1979 1986 - Apr lastSun 0:00 1:00 D +Rule TC 1979 max - Oct lastSun 0:00 0 S +Rule TC 1987 max - Apr Sun>=1 0:00 1:00 D +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Grand_Turk -4:44:32 - LMT 1890 + -5:07:12 - KMT 1912 Feb # Kingston Mean Time + -5:00 TC E%sT + +# British Virgin Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Tortola -4:18:28 - LMT 1911 Jul # Road Town + -4:00 - AST + +# Virgin Is +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/St_Thomas -4:19:44 - LMT 1911 Jul # Charlotte Amalie + -4:00 - AST diff --git a/src/timezone/data/pacificnew b/src/timezone/data/pacificnew new file mode 100644 index 0000000000..86dd688341 --- /dev/null +++ b/src/timezone/data/pacificnew @@ -0,0 +1,26 @@ +# @(#)pacificnew 7.10 + +# From Arthur David Olson (1989-04-05): +# On 1989-04-05, the U. S. House of Representatives passed (238-154) a bill +# establishing "Pacific Presidential Election Time"; it was not acted on +# by the Senate or signed into law by the President. +# You might want to change the "PE" (Presidential Election) below to +# "Q" (Quadrennial) to maintain three-character zone abbreviations. +# If you're really conservative, you might want to change it to "D". +# Avoid "L" (Leap Year), which won't be true in 2100. + +# If Presidential Election Time is ever established, replace "XXXX" below +# with the year the law takes effect and uncomment the "##" lines. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +## Rule Twilite XXXX max - Apr Sun>=1 2:00 1:00 D +## Rule Twilite XXXX max uspres Oct lastSun 2:00 1:00 PE +## Rule Twilite XXXX max uspres Nov Sun>=7 2:00 0 S +## Rule Twilite XXXX max nonpres Oct lastSun 2:00 0 S + +# Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] +## Zone America/Los_Angeles-PET -8:00 US P%sT XXXX +## -8:00 Twilite P%sT + +# For now... +Link America/Los_Angeles US/Pacific-New ## diff --git a/src/timezone/data/solar87 b/src/timezone/data/solar87 new file mode 100644 index 0000000000..3f32347973 --- /dev/null +++ b/src/timezone/data/solar87 @@ -0,0 +1,388 @@ +# @(#)solar87 7.3 + +# So much for footnotes about Saudi Arabia. +# Apparent noon times below are for Riyadh; your mileage will vary. +# Times were computed using formulas in the U.S. Naval Observatory's +# Almanac for Computers 1987; the formulas "will give EqT to an accuracy of +# [plus or minus two] seconds during the current year." +# +# Rounding to the nearest five seconds results in fewer than +# 256 different "time types"--a limit that's faced because time types are +# stored on disk as unsigned chars. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule sol87 1987 only - Jan 1 12:03:20s -0:03:20 - +Rule sol87 1987 only - Jan 2 12:03:50s -0:03:50 - +Rule sol87 1987 only - Jan 3 12:04:15s -0:04:15 - +Rule sol87 1987 only - Jan 4 12:04:45s -0:04:45 - +Rule sol87 1987 only - Jan 5 12:05:10s -0:05:10 - +Rule sol87 1987 only - Jan 6 12:05:40s -0:05:40 - +Rule sol87 1987 only - Jan 7 12:06:05s -0:06:05 - +Rule sol87 1987 only - Jan 8 12:06:30s -0:06:30 - +Rule sol87 1987 only - Jan 9 12:06:55s -0:06:55 - +Rule sol87 1987 only - Jan 10 12:07:20s -0:07:20 - +Rule sol87 1987 only - Jan 11 12:07:45s -0:07:45 - +Rule sol87 1987 only - Jan 12 12:08:10s -0:08:10 - +Rule sol87 1987 only - Jan 13 12:08:30s -0:08:30 - +Rule sol87 1987 only - Jan 14 12:08:55s -0:08:55 - +Rule sol87 1987 only - Jan 15 12:09:15s -0:09:15 - +Rule sol87 1987 only - Jan 16 12:09:35s -0:09:35 - +Rule sol87 1987 only - Jan 17 12:09:55s -0:09:55 - +Rule sol87 1987 only - Jan 18 12:10:15s -0:10:15 - +Rule sol87 1987 only - Jan 19 12:10:35s -0:10:35 - +Rule sol87 1987 only - Jan 20 12:10:55s -0:10:55 - +Rule sol87 1987 only - Jan 21 12:11:10s -0:11:10 - +Rule sol87 1987 only - Jan 22 12:11:30s -0:11:30 - +Rule sol87 1987 only - Jan 23 12:11:45s -0:11:45 - +Rule sol87 1987 only - Jan 24 12:12:00s -0:12:00 - +Rule sol87 1987 only - Jan 25 12:12:15s -0:12:15 - +Rule sol87 1987 only - Jan 26 12:12:30s -0:12:30 - +Rule sol87 1987 only - Jan 27 12:12:40s -0:12:40 - +Rule sol87 1987 only - Jan 28 12:12:55s -0:12:55 - +Rule sol87 1987 only - Jan 29 12:13:05s -0:13:05 - +Rule sol87 1987 only - Jan 30 12:13:15s -0:13:15 - +Rule sol87 1987 only - Jan 31 12:13:25s -0:13:25 - +Rule sol87 1987 only - Feb 1 12:13:35s -0:13:35 - +Rule sol87 1987 only - Feb 2 12:13:40s -0:13:40 - +Rule sol87 1987 only - Feb 3 12:13:50s -0:13:50 - +Rule sol87 1987 only - Feb 4 12:13:55s -0:13:55 - +Rule sol87 1987 only - Feb 5 12:14:00s -0:14:00 - +Rule sol87 1987 only - Feb 6 12:14:05s -0:14:05 - +Rule sol87 1987 only - Feb 7 12:14:10s -0:14:10 - +Rule sol87 1987 only - Feb 8 12:14:10s -0:14:10 - +Rule sol87 1987 only - Feb 9 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 10 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 11 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 12 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 13 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 14 12:14:15s -0:14:15 - +Rule sol87 1987 only - Feb 15 12:14:10s -0:14:10 - +Rule sol87 1987 only - Feb 16 12:14:10s -0:14:10 - +Rule sol87 1987 only - Feb 17 12:14:05s -0:14:05 - +Rule sol87 1987 only - Feb 18 12:14:00s -0:14:00 - +Rule sol87 1987 only - Feb 19 12:13:55s -0:13:55 - +Rule sol87 1987 only - Feb 20 12:13:50s -0:13:50 - +Rule sol87 1987 only - Feb 21 12:13:45s -0:13:45 - +Rule sol87 1987 only - Feb 22 12:13:35s -0:13:35 - +Rule sol87 1987 only - Feb 23 12:13:30s -0:13:30 - +Rule sol87 1987 only - Feb 24 12:13:20s -0:13:20 - +Rule sol87 1987 only - Feb 25 12:13:10s -0:13:10 - +Rule sol87 1987 only - Feb 26 12:13:00s -0:13:00 - +Rule sol87 1987 only - Feb 27 12:12:50s -0:12:50 - +Rule sol87 1987 only - Feb 28 12:12:40s -0:12:40 - +Rule sol87 1987 only - Mar 1 12:12:30s -0:12:30 - +Rule sol87 1987 only - Mar 2 12:12:20s -0:12:20 - +Rule sol87 1987 only - Mar 3 12:12:05s -0:12:05 - +Rule sol87 1987 only - Mar 4 12:11:55s -0:11:55 - +Rule sol87 1987 only - Mar 5 12:11:40s -0:11:40 - +Rule sol87 1987 only - Mar 6 12:11:25s -0:11:25 - +Rule sol87 1987 only - Mar 7 12:11:15s -0:11:15 - +Rule sol87 1987 only - Mar 8 12:11:00s -0:11:00 - +Rule sol87 1987 only - Mar 9 12:10:45s -0:10:45 - +Rule sol87 1987 only - Mar 10 12:10:30s -0:10:30 - +Rule sol87 1987 only - Mar 11 12:10:15s -0:10:15 - +Rule sol87 1987 only - Mar 12 12:09:55s -0:09:55 - +Rule sol87 1987 only - Mar 13 12:09:40s -0:09:40 - +Rule sol87 1987 only - Mar 14 12:09:25s -0:09:25 - +Rule sol87 1987 only - Mar 15 12:09:10s -0:09:10 - +Rule sol87 1987 only - Mar 16 12:08:50s -0:08:50 - +Rule sol87 1987 only - Mar 17 12:08:35s -0:08:35 - +Rule sol87 1987 only - Mar 18 12:08:15s -0:08:15 - +Rule sol87 1987 only - Mar 19 12:08:00s -0:08:00 - +Rule sol87 1987 only - Mar 20 12:07:40s -0:07:40 - +Rule sol87 1987 only - Mar 21 12:07:25s -0:07:25 - +Rule sol87 1987 only - Mar 22 12:07:05s -0:07:05 - +Rule sol87 1987 only - Mar 23 12:06:50s -0:06:50 - +Rule sol87 1987 only - Mar 24 12:06:30s -0:06:30 - +Rule sol87 1987 only - Mar 25 12:06:10s -0:06:10 - +Rule sol87 1987 only - Mar 26 12:05:55s -0:05:55 - +Rule sol87 1987 only - Mar 27 12:05:35s -0:05:35 - +Rule sol87 1987 only - Mar 28 12:05:15s -0:05:15 - +Rule sol87 1987 only - Mar 29 12:05:00s -0:05:00 - +Rule sol87 1987 only - Mar 30 12:04:40s -0:04:40 - +Rule sol87 1987 only - Mar 31 12:04:25s -0:04:25 - +Rule sol87 1987 only - Apr 1 12:04:05s -0:04:05 - +Rule sol87 1987 only - Apr 2 12:03:45s -0:03:45 - +Rule sol87 1987 only - Apr 3 12:03:30s -0:03:30 - +Rule sol87 1987 only - Apr 4 12:03:10s -0:03:10 - +Rule sol87 1987 only - Apr 5 12:02:55s -0:02:55 - +Rule sol87 1987 only - Apr 6 12:02:35s -0:02:35 - +Rule sol87 1987 only - Apr 7 12:02:20s -0:02:20 - +Rule sol87 1987 only - Apr 8 12:02:05s -0:02:05 - +Rule sol87 1987 only - Apr 9 12:01:45s -0:01:45 - +Rule sol87 1987 only - Apr 10 12:01:30s -0:01:30 - +Rule sol87 1987 only - Apr 11 12:01:15s -0:01:15 - +Rule sol87 1987 only - Apr 12 12:00:55s -0:00:55 - +Rule sol87 1987 only - Apr 13 12:00:40s -0:00:40 - +Rule sol87 1987 only - Apr 14 12:00:25s -0:00:25 - +Rule sol87 1987 only - Apr 15 12:00:10s -0:00:10 - +Rule sol87 1987 only - Apr 16 11:59:55s 0:00:05 - +Rule sol87 1987 only - Apr 17 11:59:45s 0:00:15 - +Rule sol87 1987 only - Apr 18 11:59:30s 0:00:30 - +Rule sol87 1987 only - Apr 19 11:59:15s 0:00:45 - +Rule sol87 1987 only - Apr 20 11:59:05s 0:00:55 - +Rule sol87 1987 only - Apr 21 11:58:50s 0:01:10 - +Rule sol87 1987 only - Apr 22 11:58:40s 0:01:20 - +Rule sol87 1987 only - Apr 23 11:58:25s 0:01:35 - +Rule sol87 1987 only - Apr 24 11:58:15s 0:01:45 - +Rule sol87 1987 only - Apr 25 11:58:05s 0:01:55 - +Rule sol87 1987 only - Apr 26 11:57:55s 0:02:05 - +Rule sol87 1987 only - Apr 27 11:57:45s 0:02:15 - +Rule sol87 1987 only - Apr 28 11:57:35s 0:02:25 - +Rule sol87 1987 only - Apr 29 11:57:25s 0:02:35 - +Rule sol87 1987 only - Apr 30 11:57:15s 0:02:45 - +Rule sol87 1987 only - May 1 11:57:10s 0:02:50 - +Rule sol87 1987 only - May 2 11:57:00s 0:03:00 - +Rule sol87 1987 only - May 3 11:56:55s 0:03:05 - +Rule sol87 1987 only - May 4 11:56:50s 0:03:10 - +Rule sol87 1987 only - May 5 11:56:45s 0:03:15 - +Rule sol87 1987 only - May 6 11:56:40s 0:03:20 - +Rule sol87 1987 only - May 7 11:56:35s 0:03:25 - +Rule sol87 1987 only - May 8 11:56:30s 0:03:30 - +Rule sol87 1987 only - May 9 11:56:25s 0:03:35 - +Rule sol87 1987 only - May 10 11:56:25s 0:03:35 - +Rule sol87 1987 only - May 11 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 12 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 13 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 14 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 15 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 16 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 17 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 18 11:56:20s 0:03:40 - +Rule sol87 1987 only - May 19 11:56:25s 0:03:35 - +Rule sol87 1987 only - May 20 11:56:25s 0:03:35 - +Rule sol87 1987 only - May 21 11:56:30s 0:03:30 - +Rule sol87 1987 only - May 22 11:56:35s 0:03:25 - +Rule sol87 1987 only - May 23 11:56:40s 0:03:20 - +Rule sol87 1987 only - May 24 11:56:45s 0:03:15 - +Rule sol87 1987 only - May 25 11:56:50s 0:03:10 - +Rule sol87 1987 only - May 26 11:56:55s 0:03:05 - +Rule sol87 1987 only - May 27 11:57:00s 0:03:00 - +Rule sol87 1987 only - May 28 11:57:10s 0:02:50 - +Rule sol87 1987 only - May 29 11:57:15s 0:02:45 - +Rule sol87 1987 only - May 30 11:57:25s 0:02:35 - +Rule sol87 1987 only - May 31 11:57:30s 0:02:30 - +Rule sol87 1987 only - Jun 1 11:57:40s 0:02:20 - +Rule sol87 1987 only - Jun 2 11:57:50s 0:02:10 - +Rule sol87 1987 only - Jun 3 11:58:00s 0:02:00 - +Rule sol87 1987 only - Jun 4 11:58:10s 0:01:50 - +Rule sol87 1987 only - Jun 5 11:58:20s 0:01:40 - +Rule sol87 1987 only - Jun 6 11:58:30s 0:01:30 - +Rule sol87 1987 only - Jun 7 11:58:40s 0:01:20 - +Rule sol87 1987 only - Jun 8 11:58:50s 0:01:10 - +Rule sol87 1987 only - Jun 9 11:59:05s 0:00:55 - +Rule sol87 1987 only - Jun 10 11:59:15s 0:00:45 - +Rule sol87 1987 only - Jun 11 11:59:30s 0:00:30 - +Rule sol87 1987 only - Jun 12 11:59:40s 0:00:20 - +Rule sol87 1987 only - Jun 13 11:59:50s 0:00:10 - +Rule sol87 1987 only - Jun 14 12:00:05s -0:00:05 - +Rule sol87 1987 only - Jun 15 12:00:15s -0:00:15 - +Rule sol87 1987 only - Jun 16 12:00:30s -0:00:30 - +Rule sol87 1987 only - Jun 17 12:00:45s -0:00:45 - +Rule sol87 1987 only - Jun 18 12:00:55s -0:00:55 - +Rule sol87 1987 only - Jun 19 12:01:10s -0:01:10 - +Rule sol87 1987 only - Jun 20 12:01:20s -0:01:20 - +Rule sol87 1987 only - Jun 21 12:01:35s -0:01:35 - +Rule sol87 1987 only - Jun 22 12:01:50s -0:01:50 - +Rule sol87 1987 only - Jun 23 12:02:00s -0:02:00 - +Rule sol87 1987 only - Jun 24 12:02:15s -0:02:15 - +Rule sol87 1987 only - Jun 25 12:02:25s -0:02:25 - +Rule sol87 1987 only - Jun 26 12:02:40s -0:02:40 - +Rule sol87 1987 only - Jun 27 12:02:50s -0:02:50 - +Rule sol87 1987 only - Jun 28 12:03:05s -0:03:05 - +Rule sol87 1987 only - Jun 29 12:03:15s -0:03:15 - +Rule sol87 1987 only - Jun 30 12:03:30s -0:03:30 - +Rule sol87 1987 only - Jul 1 12:03:40s -0:03:40 - +Rule sol87 1987 only - Jul 2 12:03:50s -0:03:50 - +Rule sol87 1987 only - Jul 3 12:04:05s -0:04:05 - +Rule sol87 1987 only - Jul 4 12:04:15s -0:04:15 - +Rule sol87 1987 only - Jul 5 12:04:25s -0:04:25 - +Rule sol87 1987 only - Jul 6 12:04:35s -0:04:35 - +Rule sol87 1987 only - Jul 7 12:04:45s -0:04:45 - +Rule sol87 1987 only - Jul 8 12:04:55s -0:04:55 - +Rule sol87 1987 only - Jul 9 12:05:05s -0:05:05 - +Rule sol87 1987 only - Jul 10 12:05:15s -0:05:15 - +Rule sol87 1987 only - Jul 11 12:05:20s -0:05:20 - +Rule sol87 1987 only - Jul 12 12:05:30s -0:05:30 - +Rule sol87 1987 only - Jul 13 12:05:40s -0:05:40 - +Rule sol87 1987 only - Jul 14 12:05:45s -0:05:45 - +Rule sol87 1987 only - Jul 15 12:05:50s -0:05:50 - +Rule sol87 1987 only - Jul 16 12:06:00s -0:06:00 - +Rule sol87 1987 only - Jul 17 12:06:05s -0:06:05 - +Rule sol87 1987 only - Jul 18 12:06:10s -0:06:10 - +Rule sol87 1987 only - Jul 19 12:06:15s -0:06:15 - +Rule sol87 1987 only - Jul 20 12:06:15s -0:06:15 - +Rule sol87 1987 only - Jul 21 12:06:20s -0:06:20 - +Rule sol87 1987 only - Jul 22 12:06:25s -0:06:25 - +Rule sol87 1987 only - Jul 23 12:06:25s -0:06:25 - +Rule sol87 1987 only - Jul 24 12:06:25s -0:06:25 - +Rule sol87 1987 only - Jul 25 12:06:30s -0:06:30 - +Rule sol87 1987 only - Jul 26 12:06:30s -0:06:30 - +Rule sol87 1987 only - Jul 27 12:06:30s -0:06:30 - +Rule sol87 1987 only - Jul 28 12:06:30s -0:06:30 - +Rule sol87 1987 only - Jul 29 12:06:25s -0:06:25 - +Rule sol87 1987 only - Jul 30 12:06:25s -0:06:25 - +Rule sol87 1987 only - Jul 31 12:06:25s -0:06:25 - +Rule sol87 1987 only - Aug 1 12:06:20s -0:06:20 - +Rule sol87 1987 only - Aug 2 12:06:15s -0:06:15 - +Rule sol87 1987 only - Aug 3 12:06:10s -0:06:10 - +Rule sol87 1987 only - Aug 4 12:06:05s -0:06:05 - +Rule sol87 1987 only - Aug 5 12:06:00s -0:06:00 - +Rule sol87 1987 only - Aug 6 12:05:55s -0:05:55 - +Rule sol87 1987 only - Aug 7 12:05:50s -0:05:50 - +Rule sol87 1987 only - Aug 8 12:05:40s -0:05:40 - +Rule sol87 1987 only - Aug 9 12:05:35s -0:05:35 - +Rule sol87 1987 only - Aug 10 12:05:25s -0:05:25 - +Rule sol87 1987 only - Aug 11 12:05:15s -0:05:15 - +Rule sol87 1987 only - Aug 12 12:05:05s -0:05:05 - +Rule sol87 1987 only - Aug 13 12:04:55s -0:04:55 - +Rule sol87 1987 only - Aug 14 12:04:45s -0:04:45 - +Rule sol87 1987 only - Aug 15 12:04:35s -0:04:35 - +Rule sol87 1987 only - Aug 16 12:04:25s -0:04:25 - +Rule sol87 1987 only - Aug 17 12:04:10s -0:04:10 - +Rule sol87 1987 only - Aug 18 12:04:00s -0:04:00 - +Rule sol87 1987 only - Aug 19 12:03:45s -0:03:45 - +Rule sol87 1987 only - Aug 20 12:03:30s -0:03:30 - +Rule sol87 1987 only - Aug 21 12:03:15s -0:03:15 - +Rule sol87 1987 only - Aug 22 12:03:00s -0:03:00 - +Rule sol87 1987 only - Aug 23 12:02:45s -0:02:45 - +Rule sol87 1987 only - Aug 24 12:02:30s -0:02:30 - +Rule sol87 1987 only - Aug 25 12:02:15s -0:02:15 - +Rule sol87 1987 only - Aug 26 12:02:00s -0:02:00 - +Rule sol87 1987 only - Aug 27 12:01:40s -0:01:40 - +Rule sol87 1987 only - Aug 28 12:01:25s -0:01:25 - +Rule sol87 1987 only - Aug 29 12:01:05s -0:01:05 - +Rule sol87 1987 only - Aug 30 12:00:50s -0:00:50 - +Rule sol87 1987 only - Aug 31 12:00:30s -0:00:30 - +Rule sol87 1987 only - Sep 1 12:00:10s -0:00:10 - +Rule sol87 1987 only - Sep 2 11:59:50s 0:00:10 - +Rule sol87 1987 only - Sep 3 11:59:35s 0:00:25 - +Rule sol87 1987 only - Sep 4 11:59:15s 0:00:45 - +Rule sol87 1987 only - Sep 5 11:58:55s 0:01:05 - +Rule sol87 1987 only - Sep 6 11:58:35s 0:01:25 - +Rule sol87 1987 only - Sep 7 11:58:15s 0:01:45 - +Rule sol87 1987 only - Sep 8 11:57:55s 0:02:05 - +Rule sol87 1987 only - Sep 9 11:57:30s 0:02:30 - +Rule sol87 1987 only - Sep 10 11:57:10s 0:02:50 - +Rule sol87 1987 only - Sep 11 11:56:50s 0:03:10 - +Rule sol87 1987 only - Sep 12 11:56:30s 0:03:30 - +Rule sol87 1987 only - Sep 13 11:56:10s 0:03:50 - +Rule sol87 1987 only - Sep 14 11:55:45s 0:04:15 - +Rule sol87 1987 only - Sep 15 11:55:25s 0:04:35 - +Rule sol87 1987 only - Sep 16 11:55:05s 0:04:55 - +Rule sol87 1987 only - Sep 17 11:54:45s 0:05:15 - +Rule sol87 1987 only - Sep 18 11:54:20s 0:05:40 - +Rule sol87 1987 only - Sep 19 11:54:00s 0:06:00 - +Rule sol87 1987 only - Sep 20 11:53:40s 0:06:20 - +Rule sol87 1987 only - Sep 21 11:53:15s 0:06:45 - +Rule sol87 1987 only - Sep 22 11:52:55s 0:07:05 - +Rule sol87 1987 only - Sep 23 11:52:35s 0:07:25 - +Rule sol87 1987 only - Sep 24 11:52:15s 0:07:45 - +Rule sol87 1987 only - Sep 25 11:51:55s 0:08:05 - +Rule sol87 1987 only - Sep 26 11:51:35s 0:08:25 - +Rule sol87 1987 only - Sep 27 11:51:10s 0:08:50 - +Rule sol87 1987 only - Sep 28 11:50:50s 0:09:10 - +Rule sol87 1987 only - Sep 29 11:50:30s 0:09:30 - +Rule sol87 1987 only - Sep 30 11:50:10s 0:09:50 - +Rule sol87 1987 only - Oct 1 11:49:50s 0:10:10 - +Rule sol87 1987 only - Oct 2 11:49:35s 0:10:25 - +Rule sol87 1987 only - Oct 3 11:49:15s 0:10:45 - +Rule sol87 1987 only - Oct 4 11:48:55s 0:11:05 - +Rule sol87 1987 only - Oct 5 11:48:35s 0:11:25 - +Rule sol87 1987 only - Oct 6 11:48:20s 0:11:40 - +Rule sol87 1987 only - Oct 7 11:48:00s 0:12:00 - +Rule sol87 1987 only - Oct 8 11:47:45s 0:12:15 - +Rule sol87 1987 only - Oct 9 11:47:25s 0:12:35 - +Rule sol87 1987 only - Oct 10 11:47:10s 0:12:50 - +Rule sol87 1987 only - Oct 11 11:46:55s 0:13:05 - +Rule sol87 1987 only - Oct 12 11:46:40s 0:13:20 - +Rule sol87 1987 only - Oct 13 11:46:25s 0:13:35 - +Rule sol87 1987 only - Oct 14 11:46:10s 0:13:50 - +Rule sol87 1987 only - Oct 15 11:45:55s 0:14:05 - +Rule sol87 1987 only - Oct 16 11:45:45s 0:14:15 - +Rule sol87 1987 only - Oct 17 11:45:30s 0:14:30 - +Rule sol87 1987 only - Oct 18 11:45:20s 0:14:40 - +Rule sol87 1987 only - Oct 19 11:45:05s 0:14:55 - +Rule sol87 1987 only - Oct 20 11:44:55s 0:15:05 - +Rule sol87 1987 only - Oct 21 11:44:45s 0:15:15 - +Rule sol87 1987 only - Oct 22 11:44:35s 0:15:25 - +Rule sol87 1987 only - Oct 23 11:44:25s 0:15:35 - +Rule sol87 1987 only - Oct 24 11:44:20s 0:15:40 - +Rule sol87 1987 only - Oct 25 11:44:10s 0:15:50 - +Rule sol87 1987 only - Oct 26 11:44:05s 0:15:55 - +Rule sol87 1987 only - Oct 27 11:43:55s 0:16:05 - +Rule sol87 1987 only - Oct 28 11:43:50s 0:16:10 - +Rule sol87 1987 only - Oct 29 11:43:45s 0:16:15 - +Rule sol87 1987 only - Oct 30 11:43:45s 0:16:15 - +Rule sol87 1987 only - Oct 31 11:43:40s 0:16:20 - +Rule sol87 1987 only - Nov 1 11:43:40s 0:16:20 - +Rule sol87 1987 only - Nov 2 11:43:35s 0:16:25 - +Rule sol87 1987 only - Nov 3 11:43:35s 0:16:25 - +Rule sol87 1987 only - Nov 4 11:43:35s 0:16:25 - +Rule sol87 1987 only - Nov 5 11:43:35s 0:16:25 - +Rule sol87 1987 only - Nov 6 11:43:40s 0:16:20 - +Rule sol87 1987 only - Nov 7 11:43:40s 0:16:20 - +Rule sol87 1987 only - Nov 8 11:43:45s 0:16:15 - +Rule sol87 1987 only - Nov 9 11:43:50s 0:16:10 - +Rule sol87 1987 only - Nov 10 11:43:55s 0:16:05 - +Rule sol87 1987 only - Nov 11 11:44:00s 0:16:00 - +Rule sol87 1987 only - Nov 12 11:44:05s 0:15:55 - +Rule sol87 1987 only - Nov 13 11:44:15s 0:15:45 - +Rule sol87 1987 only - Nov 14 11:44:20s 0:15:40 - +Rule sol87 1987 only - Nov 15 11:44:30s 0:15:30 - +Rule sol87 1987 only - Nov 16 11:44:40s 0:15:20 - +Rule sol87 1987 only - Nov 17 11:44:50s 0:15:10 - +Rule sol87 1987 only - Nov 18 11:45:05s 0:14:55 - +Rule sol87 1987 only - Nov 19 11:45:15s 0:14:45 - +Rule sol87 1987 only - Nov 20 11:45:30s 0:14:30 - +Rule sol87 1987 only - Nov 21 11:45:45s 0:14:15 - +Rule sol87 1987 only - Nov 22 11:46:00s 0:14:00 - +Rule sol87 1987 only - Nov 23 11:46:15s 0:13:45 - +Rule sol87 1987 only - Nov 24 11:46:30s 0:13:30 - +Rule sol87 1987 only - Nov 25 11:46:50s 0:13:10 - +Rule sol87 1987 only - Nov 26 11:47:10s 0:12:50 - +Rule sol87 1987 only - Nov 27 11:47:25s 0:12:35 - +Rule sol87 1987 only - Nov 28 11:47:45s 0:12:15 - +Rule sol87 1987 only - Nov 29 11:48:05s 0:11:55 - +Rule sol87 1987 only - Nov 30 11:48:30s 0:11:30 - +Rule sol87 1987 only - Dec 1 11:48:50s 0:11:10 - +Rule sol87 1987 only - Dec 2 11:49:10s 0:10:50 - +Rule sol87 1987 only - Dec 3 11:49:35s 0:10:25 - +Rule sol87 1987 only - Dec 4 11:50:00s 0:10:00 - +Rule sol87 1987 only - Dec 5 11:50:25s 0:09:35 - +Rule sol87 1987 only - Dec 6 11:50:50s 0:09:10 - +Rule sol87 1987 only - Dec 7 11:51:15s 0:08:45 - +Rule sol87 1987 only - Dec 8 11:51:40s 0:08:20 - +Rule sol87 1987 only - Dec 9 11:52:05s 0:07:55 - +Rule sol87 1987 only - Dec 10 11:52:30s 0:07:30 - +Rule sol87 1987 only - Dec 11 11:53:00s 0:07:00 - +Rule sol87 1987 only - Dec 12 11:53:25s 0:06:35 - +Rule sol87 1987 only - Dec 13 11:53:55s 0:06:05 - +Rule sol87 1987 only - Dec 14 11:54:25s 0:05:35 - +Rule sol87 1987 only - Dec 15 11:54:50s 0:05:10 - +Rule sol87 1987 only - Dec 16 11:55:20s 0:04:40 - +Rule sol87 1987 only - Dec 17 11:55:50s 0:04:10 - +Rule sol87 1987 only - Dec 18 11:56:20s 0:03:40 - +Rule sol87 1987 only - Dec 19 11:56:50s 0:03:10 - +Rule sol87 1987 only - Dec 20 11:57:20s 0:02:40 - +Rule sol87 1987 only - Dec 21 11:57:50s 0:02:10 - +Rule sol87 1987 only - Dec 22 11:58:20s 0:01:40 - +Rule sol87 1987 only - Dec 23 11:58:50s 0:01:10 - +Rule sol87 1987 only - Dec 24 11:59:20s 0:00:40 - +Rule sol87 1987 only - Dec 25 11:59:50s 0:00:10 - +Rule sol87 1987 only - Dec 26 12:00:20s -0:00:20 - +Rule sol87 1987 only - Dec 27 12:00:45s -0:00:45 - +Rule sol87 1987 only - Dec 28 12:01:15s -0:01:15 - +Rule sol87 1987 only - Dec 29 12:01:45s -0:01:45 - +Rule sol87 1987 only - Dec 30 12:02:15s -0:02:15 - +Rule sol87 1987 only - Dec 31 12:02:45s -0:02:45 - + +# Riyadh is at about 46 degrees 46 minutes East: 3 hrs, 7 mins, 4 secs +# Before and after 1987, we'll operate on local mean solar time. + +# Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] +Zone Asia/Riyadh87 3:07:04 - ?? 1987 + 3:07:04 sol87 ?? 1988 + 3:07:04 - ?? +# For backward compatibility... +Link Asia/Riyadh87 Mideast/Riyadh87 diff --git a/src/timezone/data/solar88 b/src/timezone/data/solar88 new file mode 100644 index 0000000000..41a64e5023 --- /dev/null +++ b/src/timezone/data/solar88 @@ -0,0 +1,388 @@ +# @(#)solar88 7.3 + +# Apparent noon times below are for Riyadh; they're a bit off for other places. +# Times were computed using formulas in the U.S. Naval Observatory's +# Almanac for Computers 1988; the formulas "will give EqT to an accuracy of +# [plus or minus two] seconds during the current year." +# +# Rounding to the nearest five seconds results in fewer than +# 256 different "time types"--a limit that's faced because time types are +# stored on disk as unsigned chars. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule sol88 1988 only - Jan 1 12:03:15s -0:03:15 - +Rule sol88 1988 only - Jan 2 12:03:40s -0:03:40 - +Rule sol88 1988 only - Jan 3 12:04:10s -0:04:10 - +Rule sol88 1988 only - Jan 4 12:04:40s -0:04:40 - +Rule sol88 1988 only - Jan 5 12:05:05s -0:05:05 - +Rule sol88 1988 only - Jan 6 12:05:30s -0:05:30 - +Rule sol88 1988 only - Jan 7 12:06:00s -0:06:00 - +Rule sol88 1988 only - Jan 8 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jan 9 12:06:50s -0:06:50 - +Rule sol88 1988 only - Jan 10 12:07:15s -0:07:15 - +Rule sol88 1988 only - Jan 11 12:07:40s -0:07:40 - +Rule sol88 1988 only - Jan 12 12:08:05s -0:08:05 - +Rule sol88 1988 only - Jan 13 12:08:25s -0:08:25 - +Rule sol88 1988 only - Jan 14 12:08:50s -0:08:50 - +Rule sol88 1988 only - Jan 15 12:09:10s -0:09:10 - +Rule sol88 1988 only - Jan 16 12:09:30s -0:09:30 - +Rule sol88 1988 only - Jan 17 12:09:50s -0:09:50 - +Rule sol88 1988 only - Jan 18 12:10:10s -0:10:10 - +Rule sol88 1988 only - Jan 19 12:10:30s -0:10:30 - +Rule sol88 1988 only - Jan 20 12:10:50s -0:10:50 - +Rule sol88 1988 only - Jan 21 12:11:05s -0:11:05 - +Rule sol88 1988 only - Jan 22 12:11:25s -0:11:25 - +Rule sol88 1988 only - Jan 23 12:11:40s -0:11:40 - +Rule sol88 1988 only - Jan 24 12:11:55s -0:11:55 - +Rule sol88 1988 only - Jan 25 12:12:10s -0:12:10 - +Rule sol88 1988 only - Jan 26 12:12:25s -0:12:25 - +Rule sol88 1988 only - Jan 27 12:12:40s -0:12:40 - +Rule sol88 1988 only - Jan 28 12:12:50s -0:12:50 - +Rule sol88 1988 only - Jan 29 12:13:00s -0:13:00 - +Rule sol88 1988 only - Jan 30 12:13:10s -0:13:10 - +Rule sol88 1988 only - Jan 31 12:13:20s -0:13:20 - +Rule sol88 1988 only - Feb 1 12:13:30s -0:13:30 - +Rule sol88 1988 only - Feb 2 12:13:40s -0:13:40 - +Rule sol88 1988 only - Feb 3 12:13:45s -0:13:45 - +Rule sol88 1988 only - Feb 4 12:13:55s -0:13:55 - +Rule sol88 1988 only - Feb 5 12:14:00s -0:14:00 - +Rule sol88 1988 only - Feb 6 12:14:05s -0:14:05 - +Rule sol88 1988 only - Feb 7 12:14:10s -0:14:10 - +Rule sol88 1988 only - Feb 8 12:14:10s -0:14:10 - +Rule sol88 1988 only - Feb 9 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 10 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 11 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 12 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 13 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 14 12:14:15s -0:14:15 - +Rule sol88 1988 only - Feb 15 12:14:10s -0:14:10 - +Rule sol88 1988 only - Feb 16 12:14:10s -0:14:10 - +Rule sol88 1988 only - Feb 17 12:14:05s -0:14:05 - +Rule sol88 1988 only - Feb 18 12:14:00s -0:14:00 - +Rule sol88 1988 only - Feb 19 12:13:55s -0:13:55 - +Rule sol88 1988 only - Feb 20 12:13:50s -0:13:50 - +Rule sol88 1988 only - Feb 21 12:13:45s -0:13:45 - +Rule sol88 1988 only - Feb 22 12:13:40s -0:13:40 - +Rule sol88 1988 only - Feb 23 12:13:30s -0:13:30 - +Rule sol88 1988 only - Feb 24 12:13:20s -0:13:20 - +Rule sol88 1988 only - Feb 25 12:13:15s -0:13:15 - +Rule sol88 1988 only - Feb 26 12:13:05s -0:13:05 - +Rule sol88 1988 only - Feb 27 12:12:55s -0:12:55 - +Rule sol88 1988 only - Feb 28 12:12:45s -0:12:45 - +Rule sol88 1988 only - Feb 29 12:12:30s -0:12:30 - +Rule sol88 1988 only - Mar 1 12:12:20s -0:12:20 - +Rule sol88 1988 only - Mar 2 12:12:10s -0:12:10 - +Rule sol88 1988 only - Mar 3 12:11:55s -0:11:55 - +Rule sol88 1988 only - Mar 4 12:11:45s -0:11:45 - +Rule sol88 1988 only - Mar 5 12:11:30s -0:11:30 - +Rule sol88 1988 only - Mar 6 12:11:15s -0:11:15 - +Rule sol88 1988 only - Mar 7 12:11:00s -0:11:00 - +Rule sol88 1988 only - Mar 8 12:10:45s -0:10:45 - +Rule sol88 1988 only - Mar 9 12:10:30s -0:10:30 - +Rule sol88 1988 only - Mar 10 12:10:15s -0:10:15 - +Rule sol88 1988 only - Mar 11 12:10:00s -0:10:00 - +Rule sol88 1988 only - Mar 12 12:09:45s -0:09:45 - +Rule sol88 1988 only - Mar 13 12:09:30s -0:09:30 - +Rule sol88 1988 only - Mar 14 12:09:10s -0:09:10 - +Rule sol88 1988 only - Mar 15 12:08:55s -0:08:55 - +Rule sol88 1988 only - Mar 16 12:08:40s -0:08:40 - +Rule sol88 1988 only - Mar 17 12:08:20s -0:08:20 - +Rule sol88 1988 only - Mar 18 12:08:05s -0:08:05 - +Rule sol88 1988 only - Mar 19 12:07:45s -0:07:45 - +Rule sol88 1988 only - Mar 20 12:07:30s -0:07:30 - +Rule sol88 1988 only - Mar 21 12:07:10s -0:07:10 - +Rule sol88 1988 only - Mar 22 12:06:50s -0:06:50 - +Rule sol88 1988 only - Mar 23 12:06:35s -0:06:35 - +Rule sol88 1988 only - Mar 24 12:06:15s -0:06:15 - +Rule sol88 1988 only - Mar 25 12:06:00s -0:06:00 - +Rule sol88 1988 only - Mar 26 12:05:40s -0:05:40 - +Rule sol88 1988 only - Mar 27 12:05:20s -0:05:20 - +Rule sol88 1988 only - Mar 28 12:05:05s -0:05:05 - +Rule sol88 1988 only - Mar 29 12:04:45s -0:04:45 - +Rule sol88 1988 only - Mar 30 12:04:25s -0:04:25 - +Rule sol88 1988 only - Mar 31 12:04:10s -0:04:10 - +Rule sol88 1988 only - Apr 1 12:03:50s -0:03:50 - +Rule sol88 1988 only - Apr 2 12:03:35s -0:03:35 - +Rule sol88 1988 only - Apr 3 12:03:15s -0:03:15 - +Rule sol88 1988 only - Apr 4 12:03:00s -0:03:00 - +Rule sol88 1988 only - Apr 5 12:02:40s -0:02:40 - +Rule sol88 1988 only - Apr 6 12:02:25s -0:02:25 - +Rule sol88 1988 only - Apr 7 12:02:05s -0:02:05 - +Rule sol88 1988 only - Apr 8 12:01:50s -0:01:50 - +Rule sol88 1988 only - Apr 9 12:01:35s -0:01:35 - +Rule sol88 1988 only - Apr 10 12:01:15s -0:01:15 - +Rule sol88 1988 only - Apr 11 12:01:00s -0:01:00 - +Rule sol88 1988 only - Apr 12 12:00:45s -0:00:45 - +Rule sol88 1988 only - Apr 13 12:00:30s -0:00:30 - +Rule sol88 1988 only - Apr 14 12:00:15s -0:00:15 - +Rule sol88 1988 only - Apr 15 12:00:00s 0:00:00 - +Rule sol88 1988 only - Apr 16 11:59:45s 0:00:15 - +Rule sol88 1988 only - Apr 17 11:59:30s 0:00:30 - +Rule sol88 1988 only - Apr 18 11:59:20s 0:00:40 - +Rule sol88 1988 only - Apr 19 11:59:05s 0:00:55 - +Rule sol88 1988 only - Apr 20 11:58:55s 0:01:05 - +Rule sol88 1988 only - Apr 21 11:58:40s 0:01:20 - +Rule sol88 1988 only - Apr 22 11:58:30s 0:01:30 - +Rule sol88 1988 only - Apr 23 11:58:15s 0:01:45 - +Rule sol88 1988 only - Apr 24 11:58:05s 0:01:55 - +Rule sol88 1988 only - Apr 25 11:57:55s 0:02:05 - +Rule sol88 1988 only - Apr 26 11:57:45s 0:02:15 - +Rule sol88 1988 only - Apr 27 11:57:35s 0:02:25 - +Rule sol88 1988 only - Apr 28 11:57:30s 0:02:30 - +Rule sol88 1988 only - Apr 29 11:57:20s 0:02:40 - +Rule sol88 1988 only - Apr 30 11:57:10s 0:02:50 - +Rule sol88 1988 only - May 1 11:57:05s 0:02:55 - +Rule sol88 1988 only - May 2 11:56:55s 0:03:05 - +Rule sol88 1988 only - May 3 11:56:50s 0:03:10 - +Rule sol88 1988 only - May 4 11:56:45s 0:03:15 - +Rule sol88 1988 only - May 5 11:56:40s 0:03:20 - +Rule sol88 1988 only - May 6 11:56:35s 0:03:25 - +Rule sol88 1988 only - May 7 11:56:30s 0:03:30 - +Rule sol88 1988 only - May 8 11:56:25s 0:03:35 - +Rule sol88 1988 only - May 9 11:56:25s 0:03:35 - +Rule sol88 1988 only - May 10 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 11 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 12 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 13 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 14 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 15 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 16 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 17 11:56:20s 0:03:40 - +Rule sol88 1988 only - May 18 11:56:25s 0:03:35 - +Rule sol88 1988 only - May 19 11:56:25s 0:03:35 - +Rule sol88 1988 only - May 20 11:56:30s 0:03:30 - +Rule sol88 1988 only - May 21 11:56:35s 0:03:25 - +Rule sol88 1988 only - May 22 11:56:40s 0:03:20 - +Rule sol88 1988 only - May 23 11:56:45s 0:03:15 - +Rule sol88 1988 only - May 24 11:56:50s 0:03:10 - +Rule sol88 1988 only - May 25 11:56:55s 0:03:05 - +Rule sol88 1988 only - May 26 11:57:00s 0:03:00 - +Rule sol88 1988 only - May 27 11:57:05s 0:02:55 - +Rule sol88 1988 only - May 28 11:57:15s 0:02:45 - +Rule sol88 1988 only - May 29 11:57:20s 0:02:40 - +Rule sol88 1988 only - May 30 11:57:30s 0:02:30 - +Rule sol88 1988 only - May 31 11:57:40s 0:02:20 - +Rule sol88 1988 only - Jun 1 11:57:50s 0:02:10 - +Rule sol88 1988 only - Jun 2 11:57:55s 0:02:05 - +Rule sol88 1988 only - Jun 3 11:58:05s 0:01:55 - +Rule sol88 1988 only - Jun 4 11:58:15s 0:01:45 - +Rule sol88 1988 only - Jun 5 11:58:30s 0:01:30 - +Rule sol88 1988 only - Jun 6 11:58:40s 0:01:20 - +Rule sol88 1988 only - Jun 7 11:58:50s 0:01:10 - +Rule sol88 1988 only - Jun 8 11:59:00s 0:01:00 - +Rule sol88 1988 only - Jun 9 11:59:15s 0:00:45 - +Rule sol88 1988 only - Jun 10 11:59:25s 0:00:35 - +Rule sol88 1988 only - Jun 11 11:59:35s 0:00:25 - +Rule sol88 1988 only - Jun 12 11:59:50s 0:00:10 - +Rule sol88 1988 only - Jun 13 12:00:00s 0:00:00 - +Rule sol88 1988 only - Jun 14 12:00:15s -0:00:15 - +Rule sol88 1988 only - Jun 15 12:00:25s -0:00:25 - +Rule sol88 1988 only - Jun 16 12:00:40s -0:00:40 - +Rule sol88 1988 only - Jun 17 12:00:55s -0:00:55 - +Rule sol88 1988 only - Jun 18 12:01:05s -0:01:05 - +Rule sol88 1988 only - Jun 19 12:01:20s -0:01:20 - +Rule sol88 1988 only - Jun 20 12:01:30s -0:01:30 - +Rule sol88 1988 only - Jun 21 12:01:45s -0:01:45 - +Rule sol88 1988 only - Jun 22 12:02:00s -0:02:00 - +Rule sol88 1988 only - Jun 23 12:02:10s -0:02:10 - +Rule sol88 1988 only - Jun 24 12:02:25s -0:02:25 - +Rule sol88 1988 only - Jun 25 12:02:35s -0:02:35 - +Rule sol88 1988 only - Jun 26 12:02:50s -0:02:50 - +Rule sol88 1988 only - Jun 27 12:03:00s -0:03:00 - +Rule sol88 1988 only - Jun 28 12:03:15s -0:03:15 - +Rule sol88 1988 only - Jun 29 12:03:25s -0:03:25 - +Rule sol88 1988 only - Jun 30 12:03:40s -0:03:40 - +Rule sol88 1988 only - Jul 1 12:03:50s -0:03:50 - +Rule sol88 1988 only - Jul 2 12:04:00s -0:04:00 - +Rule sol88 1988 only - Jul 3 12:04:10s -0:04:10 - +Rule sol88 1988 only - Jul 4 12:04:25s -0:04:25 - +Rule sol88 1988 only - Jul 5 12:04:35s -0:04:35 - +Rule sol88 1988 only - Jul 6 12:04:45s -0:04:45 - +Rule sol88 1988 only - Jul 7 12:04:55s -0:04:55 - +Rule sol88 1988 only - Jul 8 12:05:05s -0:05:05 - +Rule sol88 1988 only - Jul 9 12:05:10s -0:05:10 - +Rule sol88 1988 only - Jul 10 12:05:20s -0:05:20 - +Rule sol88 1988 only - Jul 11 12:05:30s -0:05:30 - +Rule sol88 1988 only - Jul 12 12:05:35s -0:05:35 - +Rule sol88 1988 only - Jul 13 12:05:45s -0:05:45 - +Rule sol88 1988 only - Jul 14 12:05:50s -0:05:50 - +Rule sol88 1988 only - Jul 15 12:05:55s -0:05:55 - +Rule sol88 1988 only - Jul 16 12:06:00s -0:06:00 - +Rule sol88 1988 only - Jul 17 12:06:05s -0:06:05 - +Rule sol88 1988 only - Jul 18 12:06:10s -0:06:10 - +Rule sol88 1988 only - Jul 19 12:06:15s -0:06:15 - +Rule sol88 1988 only - Jul 20 12:06:20s -0:06:20 - +Rule sol88 1988 only - Jul 21 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jul 22 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jul 23 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jul 24 12:06:30s -0:06:30 - +Rule sol88 1988 only - Jul 25 12:06:30s -0:06:30 - +Rule sol88 1988 only - Jul 26 12:06:30s -0:06:30 - +Rule sol88 1988 only - Jul 27 12:06:30s -0:06:30 - +Rule sol88 1988 only - Jul 28 12:06:30s -0:06:30 - +Rule sol88 1988 only - Jul 29 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jul 30 12:06:25s -0:06:25 - +Rule sol88 1988 only - Jul 31 12:06:20s -0:06:20 - +Rule sol88 1988 only - Aug 1 12:06:15s -0:06:15 - +Rule sol88 1988 only - Aug 2 12:06:15s -0:06:15 - +Rule sol88 1988 only - Aug 3 12:06:10s -0:06:10 - +Rule sol88 1988 only - Aug 4 12:06:05s -0:06:05 - +Rule sol88 1988 only - Aug 5 12:05:55s -0:05:55 - +Rule sol88 1988 only - Aug 6 12:05:50s -0:05:50 - +Rule sol88 1988 only - Aug 7 12:05:45s -0:05:45 - +Rule sol88 1988 only - Aug 8 12:05:35s -0:05:35 - +Rule sol88 1988 only - Aug 9 12:05:25s -0:05:25 - +Rule sol88 1988 only - Aug 10 12:05:20s -0:05:20 - +Rule sol88 1988 only - Aug 11 12:05:10s -0:05:10 - +Rule sol88 1988 only - Aug 12 12:05:00s -0:05:00 - +Rule sol88 1988 only - Aug 13 12:04:50s -0:04:50 - +Rule sol88 1988 only - Aug 14 12:04:35s -0:04:35 - +Rule sol88 1988 only - Aug 15 12:04:25s -0:04:25 - +Rule sol88 1988 only - Aug 16 12:04:15s -0:04:15 - +Rule sol88 1988 only - Aug 17 12:04:00s -0:04:00 - +Rule sol88 1988 only - Aug 18 12:03:50s -0:03:50 - +Rule sol88 1988 only - Aug 19 12:03:35s -0:03:35 - +Rule sol88 1988 only - Aug 20 12:03:20s -0:03:20 - +Rule sol88 1988 only - Aug 21 12:03:05s -0:03:05 - +Rule sol88 1988 only - Aug 22 12:02:50s -0:02:50 - +Rule sol88 1988 only - Aug 23 12:02:35s -0:02:35 - +Rule sol88 1988 only - Aug 24 12:02:20s -0:02:20 - +Rule sol88 1988 only - Aug 25 12:02:00s -0:02:00 - +Rule sol88 1988 only - Aug 26 12:01:45s -0:01:45 - +Rule sol88 1988 only - Aug 27 12:01:30s -0:01:30 - +Rule sol88 1988 only - Aug 28 12:01:10s -0:01:10 - +Rule sol88 1988 only - Aug 29 12:00:50s -0:00:50 - +Rule sol88 1988 only - Aug 30 12:00:35s -0:00:35 - +Rule sol88 1988 only - Aug 31 12:00:15s -0:00:15 - +Rule sol88 1988 only - Sep 1 11:59:55s 0:00:05 - +Rule sol88 1988 only - Sep 2 11:59:35s 0:00:25 - +Rule sol88 1988 only - Sep 3 11:59:20s 0:00:40 - +Rule sol88 1988 only - Sep 4 11:59:00s 0:01:00 - +Rule sol88 1988 only - Sep 5 11:58:40s 0:01:20 - +Rule sol88 1988 only - Sep 6 11:58:20s 0:01:40 - +Rule sol88 1988 only - Sep 7 11:58:00s 0:02:00 - +Rule sol88 1988 only - Sep 8 11:57:35s 0:02:25 - +Rule sol88 1988 only - Sep 9 11:57:15s 0:02:45 - +Rule sol88 1988 only - Sep 10 11:56:55s 0:03:05 - +Rule sol88 1988 only - Sep 11 11:56:35s 0:03:25 - +Rule sol88 1988 only - Sep 12 11:56:15s 0:03:45 - +Rule sol88 1988 only - Sep 13 11:55:50s 0:04:10 - +Rule sol88 1988 only - Sep 14 11:55:30s 0:04:30 - +Rule sol88 1988 only - Sep 15 11:55:10s 0:04:50 - +Rule sol88 1988 only - Sep 16 11:54:50s 0:05:10 - +Rule sol88 1988 only - Sep 17 11:54:25s 0:05:35 - +Rule sol88 1988 only - Sep 18 11:54:05s 0:05:55 - +Rule sol88 1988 only - Sep 19 11:53:45s 0:06:15 - +Rule sol88 1988 only - Sep 20 11:53:25s 0:06:35 - +Rule sol88 1988 only - Sep 21 11:53:00s 0:07:00 - +Rule sol88 1988 only - Sep 22 11:52:40s 0:07:20 - +Rule sol88 1988 only - Sep 23 11:52:20s 0:07:40 - +Rule sol88 1988 only - Sep 24 11:52:00s 0:08:00 - +Rule sol88 1988 only - Sep 25 11:51:40s 0:08:20 - +Rule sol88 1988 only - Sep 26 11:51:15s 0:08:45 - +Rule sol88 1988 only - Sep 27 11:50:55s 0:09:05 - +Rule sol88 1988 only - Sep 28 11:50:35s 0:09:25 - +Rule sol88 1988 only - Sep 29 11:50:15s 0:09:45 - +Rule sol88 1988 only - Sep 30 11:49:55s 0:10:05 - +Rule sol88 1988 only - Oct 1 11:49:35s 0:10:25 - +Rule sol88 1988 only - Oct 2 11:49:20s 0:10:40 - +Rule sol88 1988 only - Oct 3 11:49:00s 0:11:00 - +Rule sol88 1988 only - Oct 4 11:48:40s 0:11:20 - +Rule sol88 1988 only - Oct 5 11:48:25s 0:11:35 - +Rule sol88 1988 only - Oct 6 11:48:05s 0:11:55 - +Rule sol88 1988 only - Oct 7 11:47:50s 0:12:10 - +Rule sol88 1988 only - Oct 8 11:47:30s 0:12:30 - +Rule sol88 1988 only - Oct 9 11:47:15s 0:12:45 - +Rule sol88 1988 only - Oct 10 11:47:00s 0:13:00 - +Rule sol88 1988 only - Oct 11 11:46:45s 0:13:15 - +Rule sol88 1988 only - Oct 12 11:46:30s 0:13:30 - +Rule sol88 1988 only - Oct 13 11:46:15s 0:13:45 - +Rule sol88 1988 only - Oct 14 11:46:00s 0:14:00 - +Rule sol88 1988 only - Oct 15 11:45:45s 0:14:15 - +Rule sol88 1988 only - Oct 16 11:45:35s 0:14:25 - +Rule sol88 1988 only - Oct 17 11:45:20s 0:14:40 - +Rule sol88 1988 only - Oct 18 11:45:10s 0:14:50 - +Rule sol88 1988 only - Oct 19 11:45:00s 0:15:00 - +Rule sol88 1988 only - Oct 20 11:44:45s 0:15:15 - +Rule sol88 1988 only - Oct 21 11:44:40s 0:15:20 - +Rule sol88 1988 only - Oct 22 11:44:30s 0:15:30 - +Rule sol88 1988 only - Oct 23 11:44:20s 0:15:40 - +Rule sol88 1988 only - Oct 24 11:44:10s 0:15:50 - +Rule sol88 1988 only - Oct 25 11:44:05s 0:15:55 - +Rule sol88 1988 only - Oct 26 11:44:00s 0:16:00 - +Rule sol88 1988 only - Oct 27 11:43:55s 0:16:05 - +Rule sol88 1988 only - Oct 28 11:43:50s 0:16:10 - +Rule sol88 1988 only - Oct 29 11:43:45s 0:16:15 - +Rule sol88 1988 only - Oct 30 11:43:40s 0:16:20 - +Rule sol88 1988 only - Oct 31 11:43:40s 0:16:20 - +Rule sol88 1988 only - Nov 1 11:43:35s 0:16:25 - +Rule sol88 1988 only - Nov 2 11:43:35s 0:16:25 - +Rule sol88 1988 only - Nov 3 11:43:35s 0:16:25 - +Rule sol88 1988 only - Nov 4 11:43:35s 0:16:25 - +Rule sol88 1988 only - Nov 5 11:43:40s 0:16:20 - +Rule sol88 1988 only - Nov 6 11:43:40s 0:16:20 - +Rule sol88 1988 only - Nov 7 11:43:45s 0:16:15 - +Rule sol88 1988 only - Nov 8 11:43:45s 0:16:15 - +Rule sol88 1988 only - Nov 9 11:43:50s 0:16:10 - +Rule sol88 1988 only - Nov 10 11:44:00s 0:16:00 - +Rule sol88 1988 only - Nov 11 11:44:05s 0:15:55 - +Rule sol88 1988 only - Nov 12 11:44:10s 0:15:50 - +Rule sol88 1988 only - Nov 13 11:44:20s 0:15:40 - +Rule sol88 1988 only - Nov 14 11:44:30s 0:15:30 - +Rule sol88 1988 only - Nov 15 11:44:40s 0:15:20 - +Rule sol88 1988 only - Nov 16 11:44:50s 0:15:10 - +Rule sol88 1988 only - Nov 17 11:45:00s 0:15:00 - +Rule sol88 1988 only - Nov 18 11:45:15s 0:14:45 - +Rule sol88 1988 only - Nov 19 11:45:25s 0:14:35 - +Rule sol88 1988 only - Nov 20 11:45:40s 0:14:20 - +Rule sol88 1988 only - Nov 21 11:45:55s 0:14:05 - +Rule sol88 1988 only - Nov 22 11:46:10s 0:13:50 - +Rule sol88 1988 only - Nov 23 11:46:30s 0:13:30 - +Rule sol88 1988 only - Nov 24 11:46:45s 0:13:15 - +Rule sol88 1988 only - Nov 25 11:47:05s 0:12:55 - +Rule sol88 1988 only - Nov 26 11:47:20s 0:12:40 - +Rule sol88 1988 only - Nov 27 11:47:40s 0:12:20 - +Rule sol88 1988 only - Nov 28 11:48:00s 0:12:00 - +Rule sol88 1988 only - Nov 29 11:48:25s 0:11:35 - +Rule sol88 1988 only - Nov 30 11:48:45s 0:11:15 - +Rule sol88 1988 only - Dec 1 11:49:05s 0:10:55 - +Rule sol88 1988 only - Dec 2 11:49:30s 0:10:30 - +Rule sol88 1988 only - Dec 3 11:49:55s 0:10:05 - +Rule sol88 1988 only - Dec 4 11:50:15s 0:09:45 - +Rule sol88 1988 only - Dec 5 11:50:40s 0:09:20 - +Rule sol88 1988 only - Dec 6 11:51:05s 0:08:55 - +Rule sol88 1988 only - Dec 7 11:51:35s 0:08:25 - +Rule sol88 1988 only - Dec 8 11:52:00s 0:08:00 - +Rule sol88 1988 only - Dec 9 11:52:25s 0:07:35 - +Rule sol88 1988 only - Dec 10 11:52:55s 0:07:05 - +Rule sol88 1988 only - Dec 11 11:53:20s 0:06:40 - +Rule sol88 1988 only - Dec 12 11:53:50s 0:06:10 - +Rule sol88 1988 only - Dec 13 11:54:15s 0:05:45 - +Rule sol88 1988 only - Dec 14 11:54:45s 0:05:15 - +Rule sol88 1988 only - Dec 15 11:55:15s 0:04:45 - +Rule sol88 1988 only - Dec 16 11:55:45s 0:04:15 - +Rule sol88 1988 only - Dec 17 11:56:15s 0:03:45 - +Rule sol88 1988 only - Dec 18 11:56:40s 0:03:20 - +Rule sol88 1988 only - Dec 19 11:57:10s 0:02:50 - +Rule sol88 1988 only - Dec 20 11:57:40s 0:02:20 - +Rule sol88 1988 only - Dec 21 11:58:10s 0:01:50 - +Rule sol88 1988 only - Dec 22 11:58:40s 0:01:20 - +Rule sol88 1988 only - Dec 23 11:59:10s 0:00:50 - +Rule sol88 1988 only - Dec 24 11:59:40s 0:00:20 - +Rule sol88 1988 only - Dec 25 12:00:10s -0:00:10 - +Rule sol88 1988 only - Dec 26 12:00:40s -0:00:40 - +Rule sol88 1988 only - Dec 27 12:01:10s -0:01:10 - +Rule sol88 1988 only - Dec 28 12:01:40s -0:01:40 - +Rule sol88 1988 only - Dec 29 12:02:10s -0:02:10 - +Rule sol88 1988 only - Dec 30 12:02:35s -0:02:35 - +Rule sol88 1988 only - Dec 31 12:03:05s -0:03:05 - + +# Riyadh is at about 46 degrees 46 minutes East: 3 hrs, 7 mins, 4 secs +# Before and after 1988, we'll operate on local mean solar time. + +# Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] +Zone Asia/Riyadh88 3:07:04 - ?? 1988 + 3:07:04 sol88 ?? 1989 + 3:07:04 - ?? +# For backward compatibility... +Link Asia/Riyadh88 Mideast/Riyadh88 diff --git a/src/timezone/data/solar89 b/src/timezone/data/solar89 new file mode 100644 index 0000000000..a6d3d718d3 --- /dev/null +++ b/src/timezone/data/solar89 @@ -0,0 +1,393 @@ +# @(#)solar89 7.4 + +# Apparent noon times below are for Riyadh; they're a bit off for other places. +# Times were computed using a formula provided by the U. S. Naval Observatory: +# eqt = -105.8 * sin(l) + 596.2 * sin(2 * l) + 4.4 * sin(3 * l) +# -12.7 * sin(4 * l) - 429.0 * cos(l) - 2.1 * cos (2 * l) +# + 19.3 * cos(3 * l); +# where l is the "mean longitude of the Sun" given by +# l = 279.642 degrees + 0.985647 * d +# and d is the interval in days from January 0, 0 hours Universal Time +# (equaling the day of the year plus the fraction of a day from zero hours). +# The accuracy of the formula is plus or minus three seconds. +# +# Rounding to the nearest five seconds results in fewer than +# 256 different "time types"--a limit that's faced because time types are +# stored on disk as unsigned chars. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule sol89 1989 only - Jan 1 12:03:35s -0:03:35 - +Rule sol89 1989 only - Jan 2 12:04:05s -0:04:05 - +Rule sol89 1989 only - Jan 3 12:04:30s -0:04:30 - +Rule sol89 1989 only - Jan 4 12:05:00s -0:05:00 - +Rule sol89 1989 only - Jan 5 12:05:25s -0:05:25 - +Rule sol89 1989 only - Jan 6 12:05:50s -0:05:50 - +Rule sol89 1989 only - Jan 7 12:06:15s -0:06:15 - +Rule sol89 1989 only - Jan 8 12:06:45s -0:06:45 - +Rule sol89 1989 only - Jan 9 12:07:10s -0:07:10 - +Rule sol89 1989 only - Jan 10 12:07:35s -0:07:35 - +Rule sol89 1989 only - Jan 11 12:07:55s -0:07:55 - +Rule sol89 1989 only - Jan 12 12:08:20s -0:08:20 - +Rule sol89 1989 only - Jan 13 12:08:45s -0:08:45 - +Rule sol89 1989 only - Jan 14 12:09:05s -0:09:05 - +Rule sol89 1989 only - Jan 15 12:09:25s -0:09:25 - +Rule sol89 1989 only - Jan 16 12:09:45s -0:09:45 - +Rule sol89 1989 only - Jan 17 12:10:05s -0:10:05 - +Rule sol89 1989 only - Jan 18 12:10:25s -0:10:25 - +Rule sol89 1989 only - Jan 19 12:10:45s -0:10:45 - +Rule sol89 1989 only - Jan 20 12:11:05s -0:11:05 - +Rule sol89 1989 only - Jan 21 12:11:20s -0:11:20 - +Rule sol89 1989 only - Jan 22 12:11:35s -0:11:35 - +Rule sol89 1989 only - Jan 23 12:11:55s -0:11:55 - +Rule sol89 1989 only - Jan 24 12:12:10s -0:12:10 - +Rule sol89 1989 only - Jan 25 12:12:20s -0:12:20 - +Rule sol89 1989 only - Jan 26 12:12:35s -0:12:35 - +Rule sol89 1989 only - Jan 27 12:12:50s -0:12:50 - +Rule sol89 1989 only - Jan 28 12:13:00s -0:13:00 - +Rule sol89 1989 only - Jan 29 12:13:10s -0:13:10 - +Rule sol89 1989 only - Jan 30 12:13:20s -0:13:20 - +Rule sol89 1989 only - Jan 31 12:13:30s -0:13:30 - +Rule sol89 1989 only - Feb 1 12:13:40s -0:13:40 - +Rule sol89 1989 only - Feb 2 12:13:45s -0:13:45 - +Rule sol89 1989 only - Feb 3 12:13:55s -0:13:55 - +Rule sol89 1989 only - Feb 4 12:14:00s -0:14:00 - +Rule sol89 1989 only - Feb 5 12:14:05s -0:14:05 - +Rule sol89 1989 only - Feb 6 12:14:10s -0:14:10 - +Rule sol89 1989 only - Feb 7 12:14:10s -0:14:10 - +Rule sol89 1989 only - Feb 8 12:14:15s -0:14:15 - +Rule sol89 1989 only - Feb 9 12:14:15s -0:14:15 - +Rule sol89 1989 only - Feb 10 12:14:20s -0:14:20 - +Rule sol89 1989 only - Feb 11 12:14:20s -0:14:20 - +Rule sol89 1989 only - Feb 12 12:14:20s -0:14:20 - +Rule sol89 1989 only - Feb 13 12:14:15s -0:14:15 - +Rule sol89 1989 only - Feb 14 12:14:15s -0:14:15 - +Rule sol89 1989 only - Feb 15 12:14:10s -0:14:10 - +Rule sol89 1989 only - Feb 16 12:14:10s -0:14:10 - +Rule sol89 1989 only - Feb 17 12:14:05s -0:14:05 - +Rule sol89 1989 only - Feb 18 12:14:00s -0:14:00 - +Rule sol89 1989 only - Feb 19 12:13:55s -0:13:55 - +Rule sol89 1989 only - Feb 20 12:13:50s -0:13:50 - +Rule sol89 1989 only - Feb 21 12:13:40s -0:13:40 - +Rule sol89 1989 only - Feb 22 12:13:35s -0:13:35 - +Rule sol89 1989 only - Feb 23 12:13:25s -0:13:25 - +Rule sol89 1989 only - Feb 24 12:13:15s -0:13:15 - +Rule sol89 1989 only - Feb 25 12:13:05s -0:13:05 - +Rule sol89 1989 only - Feb 26 12:12:55s -0:12:55 - +Rule sol89 1989 only - Feb 27 12:12:45s -0:12:45 - +Rule sol89 1989 only - Feb 28 12:12:35s -0:12:35 - +Rule sol89 1989 only - Mar 1 12:12:25s -0:12:25 - +Rule sol89 1989 only - Mar 2 12:12:10s -0:12:10 - +Rule sol89 1989 only - Mar 3 12:12:00s -0:12:00 - +Rule sol89 1989 only - Mar 4 12:11:45s -0:11:45 - +Rule sol89 1989 only - Mar 5 12:11:35s -0:11:35 - +Rule sol89 1989 only - Mar 6 12:11:20s -0:11:20 - +Rule sol89 1989 only - Mar 7 12:11:05s -0:11:05 - +Rule sol89 1989 only - Mar 8 12:10:50s -0:10:50 - +Rule sol89 1989 only - Mar 9 12:10:35s -0:10:35 - +Rule sol89 1989 only - Mar 10 12:10:20s -0:10:20 - +Rule sol89 1989 only - Mar 11 12:10:05s -0:10:05 - +Rule sol89 1989 only - Mar 12 12:09:50s -0:09:50 - +Rule sol89 1989 only - Mar 13 12:09:30s -0:09:30 - +Rule sol89 1989 only - Mar 14 12:09:15s -0:09:15 - +Rule sol89 1989 only - Mar 15 12:09:00s -0:09:00 - +Rule sol89 1989 only - Mar 16 12:08:40s -0:08:40 - +Rule sol89 1989 only - Mar 17 12:08:25s -0:08:25 - +Rule sol89 1989 only - Mar 18 12:08:05s -0:08:05 - +Rule sol89 1989 only - Mar 19 12:07:50s -0:07:50 - +Rule sol89 1989 only - Mar 20 12:07:30s -0:07:30 - +Rule sol89 1989 only - Mar 21 12:07:15s -0:07:15 - +Rule sol89 1989 only - Mar 22 12:06:55s -0:06:55 - +Rule sol89 1989 only - Mar 23 12:06:35s -0:06:35 - +Rule sol89 1989 only - Mar 24 12:06:20s -0:06:20 - +Rule sol89 1989 only - Mar 25 12:06:00s -0:06:00 - +Rule sol89 1989 only - Mar 26 12:05:40s -0:05:40 - +Rule sol89 1989 only - Mar 27 12:05:25s -0:05:25 - +Rule sol89 1989 only - Mar 28 12:05:05s -0:05:05 - +Rule sol89 1989 only - Mar 29 12:04:50s -0:04:50 - +Rule sol89 1989 only - Mar 30 12:04:30s -0:04:30 - +Rule sol89 1989 only - Mar 31 12:04:10s -0:04:10 - +Rule sol89 1989 only - Apr 1 12:03:55s -0:03:55 - +Rule sol89 1989 only - Apr 2 12:03:35s -0:03:35 - +Rule sol89 1989 only - Apr 3 12:03:20s -0:03:20 - +Rule sol89 1989 only - Apr 4 12:03:00s -0:03:00 - +Rule sol89 1989 only - Apr 5 12:02:45s -0:02:45 - +Rule sol89 1989 only - Apr 6 12:02:25s -0:02:25 - +Rule sol89 1989 only - Apr 7 12:02:10s -0:02:10 - +Rule sol89 1989 only - Apr 8 12:01:50s -0:01:50 - +Rule sol89 1989 only - Apr 9 12:01:35s -0:01:35 - +Rule sol89 1989 only - Apr 10 12:01:20s -0:01:20 - +Rule sol89 1989 only - Apr 11 12:01:05s -0:01:05 - +Rule sol89 1989 only - Apr 12 12:00:50s -0:00:50 - +Rule sol89 1989 only - Apr 13 12:00:35s -0:00:35 - +Rule sol89 1989 only - Apr 14 12:00:20s -0:00:20 - +Rule sol89 1989 only - Apr 15 12:00:05s -0:00:05 - +Rule sol89 1989 only - Apr 16 11:59:50s 0:00:10 - +Rule sol89 1989 only - Apr 17 11:59:35s 0:00:25 - +Rule sol89 1989 only - Apr 18 11:59:20s 0:00:40 - +Rule sol89 1989 only - Apr 19 11:59:10s 0:00:50 - +Rule sol89 1989 only - Apr 20 11:58:55s 0:01:05 - +Rule sol89 1989 only - Apr 21 11:58:45s 0:01:15 - +Rule sol89 1989 only - Apr 22 11:58:30s 0:01:30 - +Rule sol89 1989 only - Apr 23 11:58:20s 0:01:40 - +Rule sol89 1989 only - Apr 24 11:58:10s 0:01:50 - +Rule sol89 1989 only - Apr 25 11:58:00s 0:02:00 - +Rule sol89 1989 only - Apr 26 11:57:50s 0:02:10 - +Rule sol89 1989 only - Apr 27 11:57:40s 0:02:20 - +Rule sol89 1989 only - Apr 28 11:57:30s 0:02:30 - +Rule sol89 1989 only - Apr 29 11:57:20s 0:02:40 - +Rule sol89 1989 only - Apr 30 11:57:15s 0:02:45 - +Rule sol89 1989 only - May 1 11:57:05s 0:02:55 - +Rule sol89 1989 only - May 2 11:57:00s 0:03:00 - +Rule sol89 1989 only - May 3 11:56:50s 0:03:10 - +Rule sol89 1989 only - May 4 11:56:45s 0:03:15 - +Rule sol89 1989 only - May 5 11:56:40s 0:03:20 - +Rule sol89 1989 only - May 6 11:56:35s 0:03:25 - +Rule sol89 1989 only - May 7 11:56:30s 0:03:30 - +Rule sol89 1989 only - May 8 11:56:30s 0:03:30 - +Rule sol89 1989 only - May 9 11:56:25s 0:03:35 - +Rule sol89 1989 only - May 10 11:56:25s 0:03:35 - +Rule sol89 1989 only - May 11 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 12 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 13 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 14 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 15 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 16 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 17 11:56:20s 0:03:40 - +Rule sol89 1989 only - May 18 11:56:25s 0:03:35 - +Rule sol89 1989 only - May 19 11:56:25s 0:03:35 - +Rule sol89 1989 only - May 20 11:56:30s 0:03:30 - +Rule sol89 1989 only - May 21 11:56:35s 0:03:25 - +Rule sol89 1989 only - May 22 11:56:35s 0:03:25 - +Rule sol89 1989 only - May 23 11:56:40s 0:03:20 - +Rule sol89 1989 only - May 24 11:56:45s 0:03:15 - +Rule sol89 1989 only - May 25 11:56:55s 0:03:05 - +Rule sol89 1989 only - May 26 11:57:00s 0:03:00 - +Rule sol89 1989 only - May 27 11:57:05s 0:02:55 - +Rule sol89 1989 only - May 28 11:57:15s 0:02:45 - +Rule sol89 1989 only - May 29 11:57:20s 0:02:40 - +Rule sol89 1989 only - May 30 11:57:30s 0:02:30 - +Rule sol89 1989 only - May 31 11:57:35s 0:02:25 - +Rule sol89 1989 only - Jun 1 11:57:45s 0:02:15 - +Rule sol89 1989 only - Jun 2 11:57:55s 0:02:05 - +Rule sol89 1989 only - Jun 3 11:58:05s 0:01:55 - +Rule sol89 1989 only - Jun 4 11:58:15s 0:01:45 - +Rule sol89 1989 only - Jun 5 11:58:25s 0:01:35 - +Rule sol89 1989 only - Jun 6 11:58:35s 0:01:25 - +Rule sol89 1989 only - Jun 7 11:58:45s 0:01:15 - +Rule sol89 1989 only - Jun 8 11:59:00s 0:01:00 - +Rule sol89 1989 only - Jun 9 11:59:10s 0:00:50 - +Rule sol89 1989 only - Jun 10 11:59:20s 0:00:40 - +Rule sol89 1989 only - Jun 11 11:59:35s 0:00:25 - +Rule sol89 1989 only - Jun 12 11:59:45s 0:00:15 - +Rule sol89 1989 only - Jun 13 12:00:00s 0:00:00 - +Rule sol89 1989 only - Jun 14 12:00:10s -0:00:10 - +Rule sol89 1989 only - Jun 15 12:00:25s -0:00:25 - +Rule sol89 1989 only - Jun 16 12:00:35s -0:00:35 - +Rule sol89 1989 only - Jun 17 12:00:50s -0:00:50 - +Rule sol89 1989 only - Jun 18 12:01:05s -0:01:05 - +Rule sol89 1989 only - Jun 19 12:01:15s -0:01:15 - +Rule sol89 1989 only - Jun 20 12:01:30s -0:01:30 - +Rule sol89 1989 only - Jun 21 12:01:40s -0:01:40 - +Rule sol89 1989 only - Jun 22 12:01:55s -0:01:55 - +Rule sol89 1989 only - Jun 23 12:02:10s -0:02:10 - +Rule sol89 1989 only - Jun 24 12:02:20s -0:02:20 - +Rule sol89 1989 only - Jun 25 12:02:35s -0:02:35 - +Rule sol89 1989 only - Jun 26 12:02:45s -0:02:45 - +Rule sol89 1989 only - Jun 27 12:03:00s -0:03:00 - +Rule sol89 1989 only - Jun 28 12:03:10s -0:03:10 - +Rule sol89 1989 only - Jun 29 12:03:25s -0:03:25 - +Rule sol89 1989 only - Jun 30 12:03:35s -0:03:35 - +Rule sol89 1989 only - Jul 1 12:03:45s -0:03:45 - +Rule sol89 1989 only - Jul 2 12:04:00s -0:04:00 - +Rule sol89 1989 only - Jul 3 12:04:10s -0:04:10 - +Rule sol89 1989 only - Jul 4 12:04:20s -0:04:20 - +Rule sol89 1989 only - Jul 5 12:04:30s -0:04:30 - +Rule sol89 1989 only - Jul 6 12:04:40s -0:04:40 - +Rule sol89 1989 only - Jul 7 12:04:50s -0:04:50 - +Rule sol89 1989 only - Jul 8 12:05:00s -0:05:00 - +Rule sol89 1989 only - Jul 9 12:05:10s -0:05:10 - +Rule sol89 1989 only - Jul 10 12:05:20s -0:05:20 - +Rule sol89 1989 only - Jul 11 12:05:25s -0:05:25 - +Rule sol89 1989 only - Jul 12 12:05:35s -0:05:35 - +Rule sol89 1989 only - Jul 13 12:05:40s -0:05:40 - +Rule sol89 1989 only - Jul 14 12:05:50s -0:05:50 - +Rule sol89 1989 only - Jul 15 12:05:55s -0:05:55 - +Rule sol89 1989 only - Jul 16 12:06:00s -0:06:00 - +Rule sol89 1989 only - Jul 17 12:06:05s -0:06:05 - +Rule sol89 1989 only - Jul 18 12:06:10s -0:06:10 - +Rule sol89 1989 only - Jul 19 12:06:15s -0:06:15 - +Rule sol89 1989 only - Jul 20 12:06:20s -0:06:20 - +Rule sol89 1989 only - Jul 21 12:06:20s -0:06:20 - +Rule sol89 1989 only - Jul 22 12:06:25s -0:06:25 - +Rule sol89 1989 only - Jul 23 12:06:25s -0:06:25 - +Rule sol89 1989 only - Jul 24 12:06:30s -0:06:30 - +Rule sol89 1989 only - Jul 25 12:06:30s -0:06:30 - +Rule sol89 1989 only - Jul 26 12:06:30s -0:06:30 - +Rule sol89 1989 only - Jul 27 12:06:30s -0:06:30 - +Rule sol89 1989 only - Jul 28 12:06:30s -0:06:30 - +Rule sol89 1989 only - Jul 29 12:06:25s -0:06:25 - +Rule sol89 1989 only - Jul 30 12:06:25s -0:06:25 - +Rule sol89 1989 only - Jul 31 12:06:20s -0:06:20 - +Rule sol89 1989 only - Aug 1 12:06:20s -0:06:20 - +Rule sol89 1989 only - Aug 2 12:06:15s -0:06:15 - +Rule sol89 1989 only - Aug 3 12:06:10s -0:06:10 - +Rule sol89 1989 only - Aug 4 12:06:05s -0:06:05 - +Rule sol89 1989 only - Aug 5 12:06:00s -0:06:00 - +Rule sol89 1989 only - Aug 6 12:05:50s -0:05:50 - +Rule sol89 1989 only - Aug 7 12:05:45s -0:05:45 - +Rule sol89 1989 only - Aug 8 12:05:35s -0:05:35 - +Rule sol89 1989 only - Aug 9 12:05:30s -0:05:30 - +Rule sol89 1989 only - Aug 10 12:05:20s -0:05:20 - +Rule sol89 1989 only - Aug 11 12:05:10s -0:05:10 - +Rule sol89 1989 only - Aug 12 12:05:00s -0:05:00 - +Rule sol89 1989 only - Aug 13 12:04:50s -0:04:50 - +Rule sol89 1989 only - Aug 14 12:04:40s -0:04:40 - +Rule sol89 1989 only - Aug 15 12:04:30s -0:04:30 - +Rule sol89 1989 only - Aug 16 12:04:15s -0:04:15 - +Rule sol89 1989 only - Aug 17 12:04:05s -0:04:05 - +Rule sol89 1989 only - Aug 18 12:03:50s -0:03:50 - +Rule sol89 1989 only - Aug 19 12:03:35s -0:03:35 - +Rule sol89 1989 only - Aug 20 12:03:25s -0:03:25 - +Rule sol89 1989 only - Aug 21 12:03:10s -0:03:10 - +Rule sol89 1989 only - Aug 22 12:02:55s -0:02:55 - +Rule sol89 1989 only - Aug 23 12:02:40s -0:02:40 - +Rule sol89 1989 only - Aug 24 12:02:20s -0:02:20 - +Rule sol89 1989 only - Aug 25 12:02:05s -0:02:05 - +Rule sol89 1989 only - Aug 26 12:01:50s -0:01:50 - +Rule sol89 1989 only - Aug 27 12:01:30s -0:01:30 - +Rule sol89 1989 only - Aug 28 12:01:15s -0:01:15 - +Rule sol89 1989 only - Aug 29 12:00:55s -0:00:55 - +Rule sol89 1989 only - Aug 30 12:00:40s -0:00:40 - +Rule sol89 1989 only - Aug 31 12:00:20s -0:00:20 - +Rule sol89 1989 only - Sep 1 12:00:00s 0:00:00 - +Rule sol89 1989 only - Sep 2 11:59:45s 0:00:15 - +Rule sol89 1989 only - Sep 3 11:59:25s 0:00:35 - +Rule sol89 1989 only - Sep 4 11:59:05s 0:00:55 - +Rule sol89 1989 only - Sep 5 11:58:45s 0:01:15 - +Rule sol89 1989 only - Sep 6 11:58:25s 0:01:35 - +Rule sol89 1989 only - Sep 7 11:58:05s 0:01:55 - +Rule sol89 1989 only - Sep 8 11:57:45s 0:02:15 - +Rule sol89 1989 only - Sep 9 11:57:20s 0:02:40 - +Rule sol89 1989 only - Sep 10 11:57:00s 0:03:00 - +Rule sol89 1989 only - Sep 11 11:56:40s 0:03:20 - +Rule sol89 1989 only - Sep 12 11:56:20s 0:03:40 - +Rule sol89 1989 only - Sep 13 11:56:00s 0:04:00 - +Rule sol89 1989 only - Sep 14 11:55:35s 0:04:25 - +Rule sol89 1989 only - Sep 15 11:55:15s 0:04:45 - +Rule sol89 1989 only - Sep 16 11:54:55s 0:05:05 - +Rule sol89 1989 only - Sep 17 11:54:35s 0:05:25 - +Rule sol89 1989 only - Sep 18 11:54:10s 0:05:50 - +Rule sol89 1989 only - Sep 19 11:53:50s 0:06:10 - +Rule sol89 1989 only - Sep 20 11:53:30s 0:06:30 - +Rule sol89 1989 only - Sep 21 11:53:10s 0:06:50 - +Rule sol89 1989 only - Sep 22 11:52:45s 0:07:15 - +Rule sol89 1989 only - Sep 23 11:52:25s 0:07:35 - +Rule sol89 1989 only - Sep 24 11:52:05s 0:07:55 - +Rule sol89 1989 only - Sep 25 11:51:45s 0:08:15 - +Rule sol89 1989 only - Sep 26 11:51:25s 0:08:35 - +Rule sol89 1989 only - Sep 27 11:51:05s 0:08:55 - +Rule sol89 1989 only - Sep 28 11:50:40s 0:09:20 - +Rule sol89 1989 only - Sep 29 11:50:20s 0:09:40 - +Rule sol89 1989 only - Sep 30 11:50:00s 0:10:00 - +Rule sol89 1989 only - Oct 1 11:49:45s 0:10:15 - +Rule sol89 1989 only - Oct 2 11:49:25s 0:10:35 - +Rule sol89 1989 only - Oct 3 11:49:05s 0:10:55 - +Rule sol89 1989 only - Oct 4 11:48:45s 0:11:15 - +Rule sol89 1989 only - Oct 5 11:48:30s 0:11:30 - +Rule sol89 1989 only - Oct 6 11:48:10s 0:11:50 - +Rule sol89 1989 only - Oct 7 11:47:50s 0:12:10 - +Rule sol89 1989 only - Oct 8 11:47:35s 0:12:25 - +Rule sol89 1989 only - Oct 9 11:47:20s 0:12:40 - +Rule sol89 1989 only - Oct 10 11:47:00s 0:13:00 - +Rule sol89 1989 only - Oct 11 11:46:45s 0:13:15 - +Rule sol89 1989 only - Oct 12 11:46:30s 0:13:30 - +Rule sol89 1989 only - Oct 13 11:46:15s 0:13:45 - +Rule sol89 1989 only - Oct 14 11:46:00s 0:14:00 - +Rule sol89 1989 only - Oct 15 11:45:50s 0:14:10 - +Rule sol89 1989 only - Oct 16 11:45:35s 0:14:25 - +Rule sol89 1989 only - Oct 17 11:45:20s 0:14:40 - +Rule sol89 1989 only - Oct 18 11:45:10s 0:14:50 - +Rule sol89 1989 only - Oct 19 11:45:00s 0:15:00 - +Rule sol89 1989 only - Oct 20 11:44:50s 0:15:10 - +Rule sol89 1989 only - Oct 21 11:44:40s 0:15:20 - +Rule sol89 1989 only - Oct 22 11:44:30s 0:15:30 - +Rule sol89 1989 only - Oct 23 11:44:20s 0:15:40 - +Rule sol89 1989 only - Oct 24 11:44:10s 0:15:50 - +Rule sol89 1989 only - Oct 25 11:44:05s 0:15:55 - +Rule sol89 1989 only - Oct 26 11:44:00s 0:16:00 - +Rule sol89 1989 only - Oct 27 11:43:50s 0:16:10 - +Rule sol89 1989 only - Oct 28 11:43:45s 0:16:15 - +Rule sol89 1989 only - Oct 29 11:43:40s 0:16:20 - +Rule sol89 1989 only - Oct 30 11:43:40s 0:16:20 - +Rule sol89 1989 only - Oct 31 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 1 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 2 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 3 11:43:30s 0:16:30 - +Rule sol89 1989 only - Nov 4 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 5 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 6 11:43:35s 0:16:25 - +Rule sol89 1989 only - Nov 7 11:43:40s 0:16:20 - +Rule sol89 1989 only - Nov 8 11:43:45s 0:16:15 - +Rule sol89 1989 only - Nov 9 11:43:50s 0:16:10 - +Rule sol89 1989 only - Nov 10 11:43:55s 0:16:05 - +Rule sol89 1989 only - Nov 11 11:44:00s 0:16:00 - +Rule sol89 1989 only - Nov 12 11:44:05s 0:15:55 - +Rule sol89 1989 only - Nov 13 11:44:15s 0:15:45 - +Rule sol89 1989 only - Nov 14 11:44:25s 0:15:35 - +Rule sol89 1989 only - Nov 15 11:44:35s 0:15:25 - +Rule sol89 1989 only - Nov 16 11:44:45s 0:15:15 - +Rule sol89 1989 only - Nov 17 11:44:55s 0:15:05 - +Rule sol89 1989 only - Nov 18 11:45:10s 0:14:50 - +Rule sol89 1989 only - Nov 19 11:45:20s 0:14:40 - +Rule sol89 1989 only - Nov 20 11:45:35s 0:14:25 - +Rule sol89 1989 only - Nov 21 11:45:50s 0:14:10 - +Rule sol89 1989 only - Nov 22 11:46:05s 0:13:55 - +Rule sol89 1989 only - Nov 23 11:46:25s 0:13:35 - +Rule sol89 1989 only - Nov 24 11:46:40s 0:13:20 - +Rule sol89 1989 only - Nov 25 11:47:00s 0:13:00 - +Rule sol89 1989 only - Nov 26 11:47:20s 0:12:40 - +Rule sol89 1989 only - Nov 27 11:47:35s 0:12:25 - +Rule sol89 1989 only - Nov 28 11:47:55s 0:12:05 - +Rule sol89 1989 only - Nov 29 11:48:20s 0:11:40 - +Rule sol89 1989 only - Nov 30 11:48:40s 0:11:20 - +Rule sol89 1989 only - Dec 1 11:49:00s 0:11:00 - +Rule sol89 1989 only - Dec 2 11:49:25s 0:10:35 - +Rule sol89 1989 only - Dec 3 11:49:50s 0:10:10 - +Rule sol89 1989 only - Dec 4 11:50:15s 0:09:45 - +Rule sol89 1989 only - Dec 5 11:50:35s 0:09:25 - +Rule sol89 1989 only - Dec 6 11:51:00s 0:09:00 - +Rule sol89 1989 only - Dec 7 11:51:30s 0:08:30 - +Rule sol89 1989 only - Dec 8 11:51:55s 0:08:05 - +Rule sol89 1989 only - Dec 9 11:52:20s 0:07:40 - +Rule sol89 1989 only - Dec 10 11:52:50s 0:07:10 - +Rule sol89 1989 only - Dec 11 11:53:15s 0:06:45 - +Rule sol89 1989 only - Dec 12 11:53:45s 0:06:15 - +Rule sol89 1989 only - Dec 13 11:54:10s 0:05:50 - +Rule sol89 1989 only - Dec 14 11:54:40s 0:05:20 - +Rule sol89 1989 only - Dec 15 11:55:10s 0:04:50 - +Rule sol89 1989 only - Dec 16 11:55:40s 0:04:20 - +Rule sol89 1989 only - Dec 17 11:56:05s 0:03:55 - +Rule sol89 1989 only - Dec 18 11:56:35s 0:03:25 - +Rule sol89 1989 only - Dec 19 11:57:05s 0:02:55 - +Rule sol89 1989 only - Dec 20 11:57:35s 0:02:25 - +Rule sol89 1989 only - Dec 21 11:58:05s 0:01:55 - +Rule sol89 1989 only - Dec 22 11:58:35s 0:01:25 - +Rule sol89 1989 only - Dec 23 11:59:05s 0:00:55 - +Rule sol89 1989 only - Dec 24 11:59:35s 0:00:25 - +Rule sol89 1989 only - Dec 25 12:00:05s -0:00:05 - +Rule sol89 1989 only - Dec 26 12:00:35s -0:00:35 - +Rule sol89 1989 only - Dec 27 12:01:05s -0:01:05 - +Rule sol89 1989 only - Dec 28 12:01:35s -0:01:35 - +Rule sol89 1989 only - Dec 29 12:02:00s -0:02:00 - +Rule sol89 1989 only - Dec 30 12:02:30s -0:02:30 - +Rule sol89 1989 only - Dec 31 12:03:00s -0:03:00 - + +# Riyadh is at about 46 degrees 46 minutes East: 3 hrs, 7 mins, 4 secs +# Before and after 1989, we'll operate on local mean solar time. + +# Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] +Zone Asia/Riyadh89 3:07:04 - ?? 1989 + 3:07:04 sol89 ?? 1990 + 3:07:04 - ?? +# For backward compatibility... +Link Asia/Riyadh89 Mideast/Riyadh89 diff --git a/src/timezone/data/southamerica b/src/timezone/data/southamerica new file mode 100644 index 0000000000..8528df1c49 --- /dev/null +++ b/src/timezone/data/southamerica @@ -0,0 +1,934 @@ +# @(#)southamerica 7.50 + +# This data is by no means authoritative; if you think you know better, +# go ahead and edit the file (and please send any changes to +# tz@elsie.nci.nih.gov for general use in the future). + +# From Paul Eggert (1999-07-07): +# A good source for time zone historical data outside the U.S. is +# Thomas G. Shanks, The International Atlas (5th edition), +# San Diego: ACS Publications, Inc. (1999). +# +# Gwillim Law writes that a good source +# for recent time zone data is the International Air Transport +# Association's Standard Schedules Information Manual (IATA SSIM), +# published semiannually. Law sent in several helpful summaries +# of the IATA's data after 1990. +# +# Except where otherwise noted, Shanks is the source for entries through 1990, +# and IATA SSIM is the source for entries after 1990. +# +# Earlier editions of these tables used the North American style (e.g. ARST and +# ARDT for Argentine Standard and Daylight Time), but the following quote +# suggests that it's better to use European style (e.g. ART and ARST). +# I suggest the use of _Summer time_ instead of the more cumbersome +# _daylight-saving time_. _Summer time_ seems to be in general use +# in Europe and South America. +# -- E O Cutler, _New York Times_ (1937-02-14), quoted in +# H L Mencken, _The American Language: Supplement I_ (1960), p 466 +# +# Earlier editions of these tables also used the North American style +# for time zones in Brazil, but this was incorrect, as Brazilians say +# "summer time". Reinaldo Goulart, a Sao Paulo businessman active in +# the railroad sector, writes (1999-07-06): +# The subject of time zones is currently a matter of discussion/debate in +# Brazil. Let's say that "the Brasilia time" is considered the +# "official time" because Brasilia is the capital city. +# The other three time zones are called "Brasilia time "minus one" or +# "plus one" or "plus two". As far as I know there is no such +# name/designation as "Eastern Time" or "Central Time". +# So I invented the following (English-language) abbreviations for now. +# Corrections are welcome! +# std dst +# -2:00 FNT FNST Fernando de Noronha +# -3:00 BRT BRST Brasilia +# -4:00 AMT AMST Amazon +# -5:00 ACT ACST Acre + +############################################################################### + +############################################################################### + +# Argentina + +# From Bob Devine (1988-01-28): +# Argentina: first Sunday in October to first Sunday in April since 1976. +# Double Summer time from 1969 to 1974. Switches at midnight. + +# From U. S. Naval Observatory (1988-01-199): +# ARGENTINA 3 H BEHIND UTC + +# From Hernan G. Otero (1995-06-26): +# I am sending modifications to the Argentine time zone table... +# AR was chosen because they are the ISO letters that represent Argentina. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Arg 1930 only - Dec 1 0:00 1:00 S +Rule Arg 1931 only - Apr 1 0:00 0 - +Rule Arg 1931 only - Oct 15 0:00 1:00 S +Rule Arg 1932 1940 - Mar 1 0:00 0 - +Rule Arg 1932 1939 - Nov 1 0:00 1:00 S +Rule Arg 1940 only - Jul 1 0:00 1:00 S +Rule Arg 1941 only - Jun 15 0:00 0 - +Rule Arg 1941 only - Oct 15 0:00 1:00 S +Rule Arg 1943 only - Aug 1 0:00 0 - +Rule Arg 1943 only - Oct 15 0:00 1:00 S +Rule Arg 1946 only - Mar 1 0:00 0 - +Rule Arg 1946 only - Oct 1 0:00 1:00 S +Rule Arg 1963 only - Oct 1 0:00 0 - +Rule Arg 1963 only - Dec 15 0:00 1:00 S +Rule Arg 1964 1966 - Mar 1 0:00 0 - +Rule Arg 1964 1966 - Oct 15 0:00 1:00 S +Rule Arg 1967 only - Apr 2 0:00 0 - +Rule Arg 1967 1968 - Oct Sun>=1 0:00 1:00 S +Rule Arg 1968 1969 - Apr Sun>=1 0:00 0 - +Rule Arg 1974 only - Jan 23 0:00 1:00 S +Rule Arg 1974 only - May 1 0:00 0 - +Rule Arg 1988 only - Dec 1 0:00 1:00 S +# +# From Hernan G. Otero (1995-06-26): +# These corrections were contributed by InterSoft Argentina S.A., +# obtaining the data from the: +# Talleres de Hidrografia Naval Argentina +# (Argentine Naval Hydrography Institute) +# +# Shanks stops after 1992-03-01; go with Otero. +Rule Arg 1989 1993 - Mar Sun>=1 0:00 0 - +Rule Arg 1989 1992 - Oct Sun>=15 0:00 1:00 S +# +# From Hernan G. Otero (1995-06-26): +# From this moment on, the law that mandated the daylight saving +# time corrections was derogated and no more modifications +# to the time zones (for daylight saving) are now made. +# +# From Rives McDow (2000-01-10): +# On October 3, 1999, 0:00 local, Argentina implemented daylight savings time, +# which did not result in the switch of a time zone, as they stayed 9 hours +# from the International Date Line. +Rule Arg 1999 only - Oct Sun>=1 0:00 1:00 S +Rule Arg 2000 only - Mar Sun>=1 0:00 0 - +# +# From Peter Gradelski via Steffen Thorsen (2000-03-01): +# We just checked with our Sao Paulo office and they say the government of +# Argentina decided not to become one of the countries that go on or off DST. +# So Buenos Aires should be -3 hours from GMT at all times. +# +# From Fabian L. Arce Jofre (2000-04-04): +# The law that claimed DST for Argentina was derogated by President Fernando +# de la Rua on March 2, 2000, because it would make people spend more energy +# in the winter time, rather than less. The change took effect on March 3. +# +# From Mariano Absatz (2001-06-06): +# one of the major newspapers here in Argentina said that the 1999 +# Timezone Law (which never was effectively applied) will (would?) be +# in effect.... The article is at +# http://ar.clarin.com/diario/2001-06-06/e-01701.htm +# ... The Law itself is "Ley No 25155", sanctioned on 1999-08-25, enacted +# 1999-09-17, and published 1999-09-21. The official publication is at: +# http://www.boletin.jus.gov.ar/BON/Primera/1999/09-Septiembre/21/PDF/BO21-09-99LEG.PDF +# Regretfully, you have to subscribe (and pay) for the on-line version.... +# +# (2001-06-12): +# the timezone for Argentina will not change next Sunday. +# Apparently it will do so on Sunday 24th.... +# http://ar.clarin.com/diario/2001-06-12/s-03501.htm +# +# (2001-06-25): +# Last Friday (yes, the last working day before the date of the change), the +# Senate annulled the 1999 law that introduced the changes later postponed. +# http://www.clarin.com.ar/diario/2001-06-22/s-03601.htm +# It remains the vote of the Deputies..., but it will be the same.... +# This kind of things had always been done this way in Argentina. +# We are still -03:00 all year round in all of the country. +# +# +# From Paul Eggert (2002-01-22): +# +# Hora de verano para la Republica Argentina (2000-10-01) +# says that standard time in Argentina from 1894-10-31 +# to 1920-05-01 was -4:16:48.25. Go with this more-precise value +# over Shanks. + +# Unless otherwise specified, data are from Shanks through 1992, from +# the IATA otherwise. As noted below, Shanks says that +# America/Cordoba split into 7 subregions during 1991/1992, but we +# haven't verified this yet so for now we'll keep it a single region. +# +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# +# Buenos Aires (BA), Capital Federal (CF), Santa Cruz (SC), +# Tierra del Fuego, Antartida e Islas del Atlantico Sur (TF) +Zone America/Buenos_Aires -3:53:48 - LMT 1894 Oct 31 + -4:16:48 - CMT 1920 May # Cordoba Mean Time + -4:00 - ART 1930 Dec + -4:00 Arg AR%sT 1969 Oct 5 + -3:00 Arg AR%sT 1999 Oct 3 + -4:00 Arg AR%sT 2000 Mar 3 + -3:00 - ART +# +# Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN), Chaco (CC), +# Formosa (FM), Salta (SA), Tucuman (TM), Santiago del Estero (SE), +# Cordoba (CB), La Rioja (LR), San Juan (SJ), San Luis (SL), La Pampa (LP), +# Neuquen (NQ), Rio Negro (RN), Chubut (CH) +# +# Shanks also makes the following claims, which we haven't verified: +# - Formosa switched to -3:00 on 1991-01-07. +# - La Rioja and San Juan switched to -4:00 on 1991-03-01 +# and then to -3:00 on 1991-05-07. +# - Misiones switched to -3:00 on 1990-12-29. +# - Chaco switched to -3:00 on 1991-01-04. +# - San Luis switched to -4:00 on 1990-03-14, then to -3:00 on 1990-10-15, +# then to -4:00 on 1991-03-01, then to -3:00 on 1991-06-01. +# - Santiago del Estero switched to -4:00 on 1991-04-01, +# then to -3:00 on 1991-04-26. +# If we need to add Zones for these areas, we may need to have a subdirectory +# for Argentina, as e.g. "America/San_Luis" is too ambiguious. +# +Zone America/Cordoba -4:16:48 - LMT 1894 Oct 31 + -4:16:48 - CMT 1920 May + -4:00 - ART 1930 Dec + -4:00 Arg AR%sT 1969 Oct 5 + -3:00 Arg AR%sT 1991 Mar 3 + -4:00 - WART 1991 Oct 20 + -3:00 Arg AR%sT 1999 Oct 3 + -4:00 Arg AR%sT 2000 Mar 3 + -3:00 - ART +# +# Jujuy (JY) +Zone America/Jujuy -4:21:12 - LMT 1894 Oct 31 + -4:16:48 - CMT 1920 May + -4:00 - ART 1930 Dec + -4:00 Arg AR%sT 1969 Oct 5 + -3:00 Arg AR%sT 1990 Mar 4 + -4:00 - WART 1990 Oct 28 + -4:00 1:00 WARST 1991 Mar 17 + -4:00 - WART 1991 Oct 6 + -3:00 1:00 ARST 1992 + -3:00 Arg AR%sT 1999 Oct 3 + -4:00 Arg AR%sT 2000 Mar 3 + -3:00 - ART +# +# Catamarca (CT) +Zone America/Catamarca -4:23:08 - LMT 1894 Oct 31 + -4:16:48 - CMT 1920 May + -4:00 - ART 1930 Dec + -4:00 Arg AR%sT 1969 Oct 5 + -3:00 Arg AR%sT 1991 Mar 3 + -4:00 - WART 1991 Oct 20 + -3:00 Arg AR%sT 1999 Oct 3 + -4:00 Arg AR%sT 2000 Mar 3 + -3:00 - ART +# +# Mendoza (MZ) +Zone America/Mendoza -4:35:16 - LMT 1894 Oct 31 + -4:16:48 - CMT 1920 May + -4:00 - ART 1930 Dec + -4:00 Arg AR%sT 1969 Oct 5 + -3:00 Arg AR%sT 1990 Mar 4 + -4:00 - WART 1990 Oct 15 + -4:00 1:00 WARST 1991 Mar 1 + -4:00 - WART 1991 Oct 15 + -4:00 1:00 WARST 1992 Mar 1 + -4:00 - WART 1992 Oct 18 + -3:00 Arg AR%sT 1999 Oct 3 + -4:00 Arg AR%sT 2000 Mar 3 + -3:00 - ART + +# Aruba +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Aruba -4:40:24 - LMT 1912 Feb 12 # Oranjestad + -4:30 - ANT 1965 # Netherlands Antilles Time + -4:00 - AST + +# Bolivia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/La_Paz -4:32:36 - LMT 1890 + -4:32:36 - CMT 1931 Oct 15 # Calamarca MT + -4:32:36 1:00 BOST 1932 Mar 21 # Bolivia ST + -4:00 - BOT # Bolivia Time + +# Brazil + +# From Paul Eggert (1993-11-18): +# The mayor of Rio recently attempted to change the time zone rules +# just in his city, in order to leave more summer time for the tourist trade. +# The rule change lasted only part of the day; +# the federal government refused to follow the city's rules, and business +# was in a chaos, so the mayor backed down that afternoon. + +# From IATA SSIM (1996-02): +# _Only_ the following states in BR1 observe DST: Rio Grande do Sul (RS), +# Santa Catarina (SC), Parana (PR), Sao Paulo (SP), Rio de Janeiro (RJ), +# Espirito Santo (ES), Minas Gerais (MG), Bahia (BA), Goias (GO), +# Distrito Federal (DF), Tocantins (TO), Sergipe [SE] and Alagoas [AL]. +# [The last three states are new to this issue of the IATA SSIM.] + +# From Gwillim Law (1996-10-07): +# Geography, history (Tocantins was part of Goias until 1989), and other +# sources of time zone information lead me to believe that AL, SE, and TO were +# always in BR1, and so the only change was whether or not they observed DST.... +# The earliest issue of the SSIM I have is 2/91. Each issue from then until +# 9/95 says that DST is observed only in the ten states I quoted from 9/95, +# along with Mato Grosso (MT) and Mato Grosso do Sul (MS), which are in BR2 +# (UTC-4).... The other two time zones given for Brazil are BR3, which is +# UTC-5, no DST, and applies only in the state of Acre (AC); and BR4, which is +# UTC-2, and applies to Fernando de Noronha (formerly FN, but I believe it's +# become part of the state of Pernambuco). The boundary between BR1 and BR2 +# has never been clearly stated. They've simply been called East and West. +# However, some conclusions can be drawn from another IATA manual: the Airline +# Coding Directory, which lists close to 400 airports in Brazil. For each +# airport it gives a time zone which is coded to the SSIM. From that +# information, I'm led to conclude that the states of Amapa (AP), Ceara (CE), +# Maranhao (MA), Paraiba (PR), Pernambuco (PE), Piaui (PI), and Rio Grande do +# Norte (RN), and the eastern part of Para (PA) are all in BR1 without DST. + +# From Marcos Tadeu (1998-09-27): +# +# Brazilian official page +# + +# From Jesper Norgaard (2000-11-03): +# [For an official list of which regions in Brazil use which time zones, see:] +# http://pcdsh01.on.br/Fusbr.htm +# http://pcdsh01.on.br/Fusbrhv.htm + +# From Celso Doria via David Madeo (2002-10-09): +# The reason for the delay this year has to do with elections in Brazil. +# +# Unlike in the United States, elections in Brazil are 100% computerized and +# the results are known almost immediately. Yesterday, it was the first +# round of the elections when 115 million Brazilians voted for President, +# Governor, Senators, Federal Deputies, and State Deputies. Nobody is +# counting (or re-counting) votes anymore and we know there will be a second +# round for the Presidency and also for some Governors. The 2nd round will +# take place on October 27th. +# +# The reason why the DST will only begin November 3rd is that the thousands +# of electoral machines used cannot have their time changed, and since the +# Constitution says the elections must begin at 8:00 AM and end at 5:00 PM, +# the Government decided to postpone DST, instead of changing the Constitution +# (maybe, for the next elections, it will be possible to change the clock)... + +# From Paul Eggert (2002-10-10): +# The official decrees referenced below are mostly taken from +# +# Decretos sobre o Horario de Verao no Brasil +# (2001-09-20, in Portuguese). +# The official site for all decrees, including those not related to time, is +# +# Presidencia da Republica, Subchefia para Assuntos Juridicos, Decretos +# (in Portuguese). + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Decree 20,466 (1931-10-01) +# Decree 21,896 (1932-01-10) +Rule Brazil 1931 only - Oct 3 11:00 1:00 S +Rule Brazil 1932 1933 - Apr 1 0:00 0 - +Rule Brazil 1932 only - Oct 3 0:00 1:00 S +# Decree 23,195 (1933-10-10) +# revoked DST. +# Decree 27,496 (1949-11-24) +# Decree 27,998 (1950-04-13) +Rule Brazil 1949 1952 - Dec 1 0:00 1:00 S +Rule Brazil 1950 only - Apr 16 1:00 0 - +Rule Brazil 1951 1952 - Apr 1 0:00 0 - +# Decree 32,308 (1953-02-24) +Rule Brazil 1953 only - Mar 1 0:00 0 - +# Decree 34,724 (1953-11-30) +# revoked DST. +# Decree 52,700 (1963-10-18) +# established DST from 1963-10-23 00:00 to 1964-02-29 00:00 +# in SP, RJ, GB, MG, ES, due to the prolongation of the drought. +# Decree 53,071 (1963-12-03) +# extended the above decree to all of the national territory on 12-09. +Rule Brazil 1963 only - Dec 9 0:00 1:00 S +# Decree 53,604 (1964-02-25) +# extended summer time by one day to 1964-03-01 00:00 (start of school). +Rule Brazil 1964 only - Mar 1 0:00 0 - +# Decree 55,639 (1965-01-27) +Rule Brazil 1965 only - Jan 31 0:00 1:00 S +Rule Brazil 1965 only - Mar 31 0:00 0 - +# Decree 57,303 (1965-11-22) +Rule Brazil 1965 only - Dec 1 0:00 1:00 S +# Decree 57,843 (1966-02-18) +Rule Brazil 1966 1968 - Mar 1 0:00 0 - +Rule Brazil 1966 1967 - Nov 1 0:00 1:00 S +# Decree 63,429 (1968-10-15) +# revoked DST. +# Decree 91,698 (1985-09-27) +Rule Brazil 1985 only - Nov 2 0:00 1:00 S +# Decree 92,310 (1986-01-21) +# Decree 92,463 (1986-03-13) +Rule Brazil 1986 only - Mar 15 0:00 0 - +# Decree 93,316 (1986-10-01) +Rule Brazil 1986 only - Oct 25 0:00 1:00 S +Rule Brazil 1987 only - Feb 14 0:00 0 - +# Decree 94,922 (1987-09-22) +Rule Brazil 1987 only - Oct 25 0:00 1:00 S +Rule Brazil 1988 only - Feb 7 0:00 0 - +# Decree 96,676 (1988-09-12) +# except for the states of AC, AM, PA, RR, RO, and AP (then a territory) +Rule Brazil 1988 only - Oct 16 0:00 1:00 S +Rule Brazil 1989 only - Jan 29 0:00 0 - +# Decree 98,077 (1989-08-21) +# with the same exceptions +Rule Brazil 1989 only - Oct 15 0:00 1:00 S +Rule Brazil 1990 only - Feb 11 0:00 0 - +# Decree 99,530 (1990-09-17) +# adopted by RS, SC, PR, SP, RJ, ES, MG, GO, MS, DF. +# Decree 99,629 (1990-10-19) adds BA, MT. +Rule Brazil 1990 only - Oct 21 0:00 1:00 S +Rule Brazil 1991 only - Feb 17 0:00 0 - +# Unnumbered decree (1991-09-25) +# adopted by RS, SC, PR, SP, RJ, ES, MG, BA, GO, MT, MS, DF. +Rule Brazil 1991 only - Oct 20 0:00 1:00 S +Rule Brazil 1992 only - Feb 9 0:00 0 - +# Unnumbered decree (1992-10-16) +# adopted by same states. +Rule Brazil 1992 only - Oct 25 0:00 1:00 S +Rule Brazil 1993 only - Jan 31 0:00 0 - +# Decree 942 (1993-09-28) +# adopted by same states, plus AM. +# Decree 1,252 (1994-09-22) +# adopted by same states, minus AM and MT. +# Decree 1,636 (1995-09-14) +# adopted by same states, plus MT and TO. +# Decree 1,674 (1995-10-13) +# adds AL, SE. +Rule Brazil 1993 1995 - Oct Sun>=11 0:00 1:00 S +Rule Brazil 1994 1995 - Feb Sun>=15 0:00 0 - +Rule Brazil 1996 only - Feb 11 0:00 0 - +# Decree 2,000 (1996-09-04) +# adopted by same states, minus AL, SE. +Rule Brazil 1996 only - Oct 6 0:00 1:00 S +Rule Brazil 1997 only - Feb 16 0:00 0 - +# From Daniel C. Sobral (1998-02-12): +# In 1997, the DS began on October 6. The stated reason was that +# because international television networks ignored Brazil's policy on DS, +# they bought the wrong times on satellite for coverage of Pope's visit. +# This year, the ending date of DS was postponed to March 1 +# to help dealing with the shortages of electric power. +# +# From Paul Eggert (1998-02-25): +# +# Brazil Prepares for Papal Visit +# , +# Church Net UK (1997-10-02). +# +# Decree 2,317 (1997-09-04), adopted by same states. +Rule Brazil 1997 only - Oct 6 0:00 1:00 S +# Decree 2,495 +# (1998-02-10) +Rule Brazil 1998 only - Mar 1 0:00 0 - +# Decree 2,780 (1998-09-11) +# adopted by the same states as before. +Rule Brazil 1998 only - Oct 11 0:00 1:00 S +Rule Brazil 1999 only - Feb 21 0:00 0 - +# Decree 3,150 +# (1999-08-23) adopted by same states. +# Decree 3,188 (1999-09-30) +# adds SE, AL, PB, PE, RN, CE, PI, MA and RR. +Rule Brazil 1999 only - Oct 3 0:00 1:00 S +Rule Brazil 2000 only - Feb 27 0:00 0 - +# Decree 3,592 (2000-09-06) +# adopted by the same states as before. +# Decree 3,630 (2000-10-13) +# repeals DST in PE and RR, effective 2000-10-15 00:00. +# Decree 3,632 (2000-10-17) +# repeals DST in SE, AL, PB, RN, CE, PI and MA, effective 2000-10-22 00:00. +# Decree 3,916 +# (2001-09-13) reestablishes DST in AL, CE, MA, PB, PE, PI, RN, SE. +Rule Brazil 2000 2001 - Oct Sun>=8 0:00 1:00 S +Rule Brazil 2001 max - Feb Sun>=15 0:00 0 - +# Decree 4,399 (2002-10-01) repeals DST in AL, CE, MA, PB, PE, PI, RN, SE. +# +Rule Brazil 2002 only - Nov 3 0:00 1:00 S +# Decree 4,844 (2003-09-24; corrected 2003-09-26) repeals DST in BA, MT, TO. +# +Rule Brazil 2003 max - Oct Sun>=15 0:00 1:00 S +# The latest ruleset listed above says that the following states observe DST: +# DF, ES, GO, MG, MS, PR, RJ, RS, SC, SP. +# +# For dates after mid-2004, the above rules with TO="max" are guesses +# and are quite possibly wrong, but are more likely than no DST at all. + + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +# +# Fernando de Noronha (administratively part of PE) +Zone America/Noronha -2:09:40 - LMT 1914 + -2:00 Brazil FN%sT 1990 Sep 17 + -2:00 - FNT 1999 Sep 30 + -2:00 Brazil FN%sT 2000 Oct 15 + -2:00 - FNT 2001 Sep 13 + -2:00 Brazil FN%sT 2002 Oct 1 + -2:00 - FNT +# Other Atlantic islands have no permanent settlement. +# These include Trindade and Martin Vaz (administratively part of ES), +# Atol das Rocas (RN), and Penedos de Sao Pedro e Sao Paulo (PE). +# Fernando de Noronha was a separate territory from 1942-09-02 to 1989-01-01; +# it also included the Penedos. +# +# Amapa (AP), east Para (PA) +# East Para includes Belem, Maraba, Serra Norte, and Sao Felix do Xingu. +# The division between east and west Para is the river Xingu. +# In the north a very small part from the river Javary (now Jari I guess, +# the border with Amapa) to the Amazon, then to the Xingu. +Zone America/Belem -3:13:56 - LMT 1914 + -3:00 Brazil BR%sT 1988 Sep 12 + -3:00 - BRT +# +# Maranhao (MA), Piaui (PI), Ceara (CE), Rio Grande do Norte (RN), +# Paraiba (PB) +Zone America/Fortaleza -2:34:00 - LMT 1914 + -3:00 Brazil BR%sT 1990 Sep 17 + -3:00 - BRT 1999 Sep 30 + -3:00 Brazil BR%sT 2000 Oct 22 + -3:00 - BRT 2001 Sep 13 + -3:00 Brazil BR%sT 2002 Oct 1 + -3:00 - BRT +# +# Pernambuco (PE) (except Atlantic islands) +Zone America/Recife -2:19:36 - LMT 1914 + -3:00 Brazil BR%sT 1990 Sep 17 + -3:00 - BRT 1999 Sep 30 + -3:00 Brazil BR%sT 2000 Oct 15 + -3:00 - BRT 2001 Sep 13 + -3:00 Brazil BR%sT 2002 Oct 1 + -3:00 - BRT +# +# Tocantins (TO) +Zone America/Araguaina -3:12:48 - LMT 1914 + -3:00 Brazil BR%sT 1990 Sep 17 + -3:00 - BRT 1995 Sep 14 + -3:00 Brazil BR%sT 2003 Sep 24 + -3:00 - BRT +# +# Alagoas (AL), Sergipe (SE) +Zone America/Maceio -2:22:52 - LMT 1914 + -3:00 Brazil BR%sT 1990 Sep 17 + -3:00 - BRT 1995 Oct 13 + -3:00 Brazil BR%sT 1996 Sep 4 + -3:00 - BRT 1999 Sep 30 + -3:00 Brazil BR%sT 2000 Oct 22 + -3:00 - BRT 2001 Sep 13 + -3:00 Brazil BR%sT 2002 Oct 1 + -3:00 - BRT +# +# Bahia (BA) +# There are too many Salvadors elsewhere, so use America/Bahia instead +# of America/Salvador. +Zone America/Bahia -2:34:04 - LMT 1914 + -3:00 Brazil BR%sT 2003 Sep 24 + -3:00 - BRT +# +# Goias (GO), Distrito Federal (DF), Minas Gerais (MG), +# Espirito Santo (ES), Rio de Janeiro (RJ), Sao Paulo (SP), Parana (PR), +# Santa Catarina (SC), Rio Grande do Sul (RS) +Zone America/Sao_Paulo -3:06:28 - LMT 1914 + -3:00 Brazil BR%sT 1963 Oct 23 00:00 + -3:00 1:00 BRST 1964 + -3:00 Brazil BR%sT +# +# Mato Grosso do Sul (MS) +Zone America/Campo_Grande -3:38:28 - LMT 1914 + -4:00 Brazil AM%sT +# +# Mato Grosso (MT) +Zone America/Cuiaba -3:44:20 - LMT 1914 + -4:00 Brazil AM%sT 1994 Sep 22 + -4:00 - AMT 1995 Sep 14 + -4:00 Brazil AM%sT 2003 Sep 24 + -4:00 - AMT +# +# west Para (PA), Rondonia (RO) +# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem. +Zone America/Porto_Velho -4:15:36 - LMT 1914 + -4:00 Brazil AM%sT 1988 Sep 12 + -4:00 - AMT +# +# Roraima (RR) +Zone America/Boa_Vista -4:02:40 - LMT 1914 + -4:00 Brazil AM%sT 1988 Sep 12 + -4:00 - AMT 1999 Sep 30 + -4:00 Brazil AM%sT 2000 Oct 15 + -4:00 - AMT +# +# east Amazonas (AM): Boca do Acre, Jutai, Manaus, Floriano Peixoto +# The great circle line from Tabatinga to Porto Acre divides +# east from west Amazonas. +Zone America/Manaus -4:00:04 - LMT 1914 + -4:00 Brazil AM%sT 1988 Sep 12 + -4:00 - AMT 1993 Sep 28 + -4:00 Brazil AM%sT 1994 Sep 22 + -4:00 - AMT +# +# west Amazonas (AM): Atalaia do Norte, Boca do Maoco, Benjamin Constant, +# Eirunepe, Envira, Ipixuna +Zone America/Eirunepe -4:39:28 - LMT 1914 + -5:00 Brazil AC%sT 1988 Sep 12 + -5:00 - ACT 1993 Sep 28 + -5:00 Brazil AC%sT 1994 Sep 22 + -5:00 - ACT +# +# Acre (AC) +Zone America/Rio_Branco -4:31:12 - LMT 1914 + -5:00 Brazil AC%sT 1988 Sep 12 + -5:00 - ACT + + +# Chile + +# From Eduardo Krell (1995-10-19): +# The law says to switch to DST at midnight [24:00] on the second SATURDAY +# of October.... The law is the same for March and October. +# (1998-09-29): +# Because of the drought this year, the government decided to go into +# DST earlier (saturday 9/26 at 24:00). This is a one-time change only ... +# (unless there's another dry season next year, I guess). + +# From Julio I. Pacheco Troncoso (1999-03-18): +# Because of the same drought, the government decided to end DST later, +# on April 3, (one-time change). + +# From Gwillim Law (2001-05-04): +# I came across another article in "La Tercera" about Chilean DST. +# +# It clearly confirms my earlier suggestion, that DST begins at 22:00 +# on Easter Island.... But it also seems to be saying that the +# observance of DST in Chile began in 1966, rather than 1969 as +# ... [Shanks] has it.... +# +# My translation: +# +# "The Chilean Army has announced that summer time will begin tomorrow, +# Saturday, October 14 in continental Chile, insular Chile, and +# Antarctica, as provided by Supreme Decree 25 of January 11, 1966. +# By the preceding, official time in continental Chile and Chilean +# Antarctic, and official time in Western Insular Chile, which applies +# to Easter Island and Sala y Gomez Island, will be set forward at +# midnight and at 22:00, respectively, by 20 minutes." + +# From Paul Eggert (2001-05-04): +# Go with this article in preference to Shanks's 1969 date for modern DST. +# Assume this rule has been used since DST was introduced in the islands. + +# From Paul Eggert (2002-10-24): +# gives many details that +# disagree with the following table, but we haven't had time to compare them. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Chile 1918 only - Sep 1 0:00 1:00 S +Rule Chile 1919 only - Jul 2 0:00 0 - +Rule Chile 1927 1931 - Sep 1 0:00 1:00 S +Rule Chile 1928 1932 - Apr 1 0:00 0 - +Rule Chile 1966 1997 - Oct Sun>=9 4:00u 1:00 S +Rule Chile 1967 1998 - Mar Sun>=9 3:00u 0 - +Rule Chile 1998 only - Sep 27 4:00u 1:00 S +Rule Chile 1999 only - Apr 4 3:00u 0 - +Rule Chile 1999 max - Oct Sun>=9 4:00u 1:00 S +Rule Chile 2000 max - Mar Sun>=9 3:00u 0 - +# IATA SSIM anomalies: (1990-09) says 1990-09-16; (1992-02) says 1992-03-14; +# (1996-09) says 1998-03-08. Ignore these. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Santiago -4:42:40 - LMT 1890 + -4:42:40 - SMT 1910 # Santiago Mean Time + -5:00 Chile CL%sT 1932 Sep # Chile Time + -4:00 Chile CL%sT +Zone Pacific/Easter -7:17:28 - LMT 1890 # Mataveri + -7:17:28 - MMT 1932 Sep # Mataveri Mean Time + -7:00 Chile EAS%sT 1982 Mar 14 # Easter I Time + -6:00 Chile EAS%sT +# +# Sala y Gomez Island is like Pacific/Easter. +# Other Chilean locations, including Juan Fernandez Is, San Ambrosio, +# San Felix, and Antarctic bases, are like America/Santiago. + +# Colombia +# Shanks specifies 24:00 for 1992 transition times; go with IATA, +# as it seems implausible to change clocks at midnight New Year's Eve. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule CO 1992 only - May 2 0:00 1:00 S +Rule CO 1992 only - Dec 31 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Bogota -4:56:20 - LMT 1884 Mar 13 + -4:56:20 - BMT 1914 Nov 23 # Bogota Mean Time + -5:00 CO CO%sT # Colombia Time +# Malpelo, Providencia, San Andres +# no information; probably like America/Bogota + +# Curacao +# Shanks says that Bottom and Oranjestad have been at -4:00 since +# standard time was introduced on 1912-03-02; and that Kralendijk and Rincon +# used Kralendijk Mean Time (-4:33:08) from 1912-02-02 to 1965-01-01. +# This all predates our 1970 cutoff, though. +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Curacao -4:35:44 - LMT 1912 Feb 12 # Willemstad + -4:30 - ANT 1965 # Netherlands Antilles Time + -4:00 - AST + +# Ecuador +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Guayaquil -5:19:20 - LMT 1890 + -5:14:00 - QMT 1931 # Quito Mean Time + -5:00 - ECT # Ecuador Time +Zone Pacific/Galapagos -5:58:24 - LMT 1931 # Puerto Baquerizo Moreno + -5:00 - ECT 1986 + -6:00 - GALT # Galapagos Time + +# Falklands + +# From Paul Eggert (2001-03-05): +# Between 1990 and 2000 inclusive, Shanks and the IATA agree except +# the IATA gives 1996-09-08. Go with Shanks. + +# From Falkland Islands Government Office, London (2001-01-22) +# via Jesper Norgaard: +# ... the clocks revert back to Local Mean Time at 2 am on Sunday 15 +# April 2001 and advance one hour to summer time at 2 am on Sunday 2 +# September. It is anticipated that the clocks will revert back at 2 +# am on Sunday 21 April 2002 and advance to summer time at 2 am on +# Sunday 1 September. + +# From Rives McDow (2001-02-13): +# +# I have communicated several times with people there, and the last +# time I had communications that was helpful was in 1998. Here is +# what was said then: +# +# "The general rule was that Stanley used daylight saving and the Camp +# did not. However for various reasons many people in the Camp have +# started to use daylight saving (known locally as 'Stanley Time') +# There is no rule as to who uses daylight saving - it is a matter of +# personal choice and so it is impossible to draw a map showing who +# uses it and who does not. Any list would be out of date as soon as +# it was produced. This year daylight saving ended on April 18/19th +# and started again on September 12/13th. I do not know what the rule +# is, but can find out if you like. We do not change at the same time +# as UK or Chile." +# +# I did have in my notes that the rule was "Second Saturday in Sep at +# 0:00 until third Saturday in Apr at 0:00". I think that this does +# not agree in some cases with Shanks; is this true? +# +# Also, there is no mention in the list that some areas in the +# Falklands do not use DST. I have found in my communications there +# that these areas are on the western half of East Falkland and all of +# West Falkland. Stanley is the only place that consistently observes +# DST. Again, as in other places in the world, the farmers don't like +# it. West Falkland is almost entirely sheep farmers. +# +# I know one lady there that keeps a list of which farm keeps DST and +# which doesn't each year. She runs a shop in Stanley, and says that +# the list changes each year. She uses it to communicate to her +# customers, catching them when they are home for lunch or dinner. + +# From Paul Eggert (2001-03-05): +# For now, we'll just record the time in Stanley, since we have no +# better info. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Falk 1937 1938 - Sep lastSun 0:00 1:00 S +Rule Falk 1938 1942 - Mar Sun>=19 0:00 0 - +Rule Falk 1939 only - Oct 1 0:00 1:00 S +Rule Falk 1940 1942 - Sep lastSun 0:00 1:00 S +Rule Falk 1943 only - Jan 1 0:00 0 - +Rule Falk 1983 only - Sep lastSun 0:00 1:00 S +Rule Falk 1984 1985 - Apr lastSun 0:00 0 - +Rule Falk 1984 only - Sep 16 0:00 1:00 S +Rule Falk 1985 2000 - Sep Sun>=9 0:00 1:00 S +Rule Falk 1986 2000 - Apr Sun>=16 0:00 0 - +Rule Falk 2001 max - Apr Sun>=15 2:00 0 - +Rule Falk 2001 max - Sep Sun>=1 2:00 1:00 S +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/Stanley -3:51:24 - LMT 1890 + -3:51:24 - SMT 1912 Mar 12 # Stanley Mean Time + -4:00 Falk FK%sT 1983 May # Falkland Is Time + -3:00 Falk FK%sT 1985 Sep 15 + -4:00 Falk FK%sT + +# French Guiana +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Cayenne -3:29:20 - LMT 1911 Jul + -4:00 - GFT 1967 Oct # French Guiana Time + -3:00 - GFT + +# Guyana +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Guyana -3:52:40 - LMT 1915 Mar # Georgetown + -3:45 - GBGT 1966 May 26 # Br Guiana Time + -3:45 - GYT 1975 Jul 31 # Guyana Time + -3:00 - GYT 1991 +# IATA SSIM (1996-06) says -4:00. Assume a 1991 switch. + -4:00 - GYT + +# Paraguay +# From Paul Eggert (1999-10-29): +# Shanks (1999) says that spring transitions are from 01:00 -> 02:00, +# and autumn transitions are from 00:00 -> 23:00. Go with earlier +# editions of Shanks, and with the IATA, who say transitions occur at 00:00. +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Para 1975 1988 - Oct 1 0:00 1:00 S +Rule Para 1975 1978 - Mar 1 0:00 0 - +Rule Para 1979 1991 - Apr 1 0:00 0 - +Rule Para 1989 only - Oct 22 0:00 1:00 S +Rule Para 1990 only - Oct 1 0:00 1:00 S +Rule Para 1991 only - Oct 6 0:00 1:00 S +Rule Para 1992 only - Mar 1 0:00 0 - +Rule Para 1992 only - Oct 5 0:00 1:00 S +Rule Para 1993 only - Mar 31 0:00 0 - +Rule Para 1993 1995 - Oct 1 0:00 1:00 S +Rule Para 1994 1995 - Feb lastSun 0:00 0 - +Rule Para 1996 only - Mar 1 0:00 0 - +# IATA SSIM (2000-02) says 1999-10-10; ignore this for now. +# From Steffen Thorsen (2000-10-02): +# I have three independent reports that Paraguay changed to DST this Sunday +# (10-01). +# +# Translated by Gwillim Law (2001-02-27) from +# +# Noticias, a daily paper in Asuncion, Paraguay (2000-10-01) +# : +# Starting at 0:00 today, the clock will be set forward 60 minutes, in +# fulfillment of Decree No. 7,273 of the Executive Power.... The time change +# system has been operating for several years. Formerly there was a separate +# decree each year; the new law has the same effect, but permanently. Every +# year, the time will change on the first Sunday of October; likewise, the +# clock will be set back on the first Sunday of March. +# +# From Jesper Norgaard (2001-03-06) [an official URL saying similar things]: +# http://gateway.abc.com.py:8000/pub/pag04.mbr/artic?FHA=2001-03-03-02.24.52.900592 +# +Rule Para 1996 2001 - Oct Sun>=1 0:00 1:00 S +# IATA SSIM (1997-09) says Mar 1; go with Shanks. +Rule Para 1997 only - Feb lastSun 0:00 0 - +# Shanks says 1999-02-28; IATA SSIM (1999-02) says 1999-02-27, but +# (1999-09) reports no date; go with above sources and Gerd Knops (2001-02-27). +Rule Para 1998 2001 - Mar Sun>=1 0:00 0 - +# From Rives McDow (2002-02-28): +# A decree was issued in Paraguay (no. 16350) on 2002-02-26 that changed the +# dst method to be from the first Sunday in September to the first Sunday in +# April. +Rule Para 2002 max - Apr Sun>=1 0:00 0 - +Rule Para 2002 max - Sep Sun>=1 0:00 1:00 S + + +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Asuncion -3:50:40 - LMT 1890 + -3:50:40 - AMT 1931 Oct 10 # Asuncion Mean Time + -4:00 - PYT 1972 Oct # Paraguay Time + -3:00 - PYT 1974 Apr + -4:00 Para PY%sT + +# Peru +# +# +# From Evelyn C. Leeper via Mark Brader (2003-10-26): +# When we were in Peru in 1985-1986, they apparently switched over +# sometime between December 29 and January 3 while we were on the Amazon. +# +# From Paul Eggert (2003-11-02): +# Shanks doesn't have this transition. Assume 1986 was like 1987. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +Rule Peru 1938 only - Jan 1 0:00 1:00 S +Rule Peru 1938 only - Apr 1 0:00 0 - +Rule Peru 1938 1939 - Sep lastSun 0:00 1:00 S +Rule Peru 1939 1940 - Mar Sun>=24 0:00 0 - +Rule Peru 1986 1987 - Jan 1 0:00 1:00 S +Rule Peru 1986 1987 - Apr 1 0:00 0 - +Rule Peru 1990 only - Jan 1 0:00 1:00 S +Rule Peru 1990 only - Apr 1 0:00 0 - +# IATA is ambiguous for 1993/1995; go with Shanks. +Rule Peru 1994 only - Jan 1 0:00 1:00 S +Rule Peru 1994 only - Apr 1 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Lima -5:08:12 - LMT 1890 + -5:08:36 - LMT 1908 Jul 28 # Lima Mean Time? + -5:00 Peru PE%sT # Peru Time + +# South Georgia +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone Atlantic/South_Georgia -2:26:08 - LMT 1890 # Grytviken + -2:00 - GST # South Georgia Time + +# South Sandwich Is +# uninhabited; scientific personnel have wintered + +# Suriname +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Paramaribo -3:40:40 - LMT 1911 + -3:40:52 - PMT 1935 # Paramaribo Mean Time + -3:40:36 - PMT 1945 Oct # The capital moved? + -3:30 - NEGT 1975 Nov 20 # Dutch Guiana Time + -3:30 - SRT 1984 Oct # Suriname Time + -3:00 - SRT + +# Trinidad and Tobago +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Port_of_Spain -4:06:04 - LMT 1912 Mar 2 + -4:00 - AST + +# Uruguay +# From Paul Eggert (1993-11-18): +# Uruguay wins the prize for the strangest peacetime manipulation of the rules. +# From Shanks: +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +# Whitman gives 1923 Oct 1; go with Shanks. +Rule Uruguay 1923 only - Oct 2 0:00 0:30 HS +Rule Uruguay 1924 1926 - Apr 1 0:00 0 - +Rule Uruguay 1924 1925 - Oct 1 0:00 0:30 HS +Rule Uruguay 1933 1935 - Oct lastSun 0:00 0:30 HS +# Shanks gives 1935 Apr 1 0:00 and 1936 Mar 30 0:00; go with Whitman. +Rule Uruguay 1934 1936 - Mar Sat>=25 23:30s 0 - +Rule Uruguay 1936 only - Nov 1 0:00 0:30 HS +Rule Uruguay 1937 1941 - Mar lastSun 0:00 0 - +# Whitman gives 1937 Oct 3; go with Shanks. +Rule Uruguay 1937 1940 - Oct lastSun 0:00 0:30 HS +# Whitman gives 1941 Oct 24 - 1942 Mar 27, 1942 Dec 14 - 1943 Apr 13, +# and 1943 Apr 13 ``to present time''; go with Shanks. +Rule Uruguay 1941 only - Aug 1 0:00 0 - +Rule Uruguay 1942 only - Jan 1 0:00 0:30 HS +Rule Uruguay 1942 only - Dec 14 0:00 1:00 S +Rule Uruguay 1943 only - Mar 14 0:00 0 - +Rule Uruguay 1959 only - May 24 0:00 1:00 S +Rule Uruguay 1959 only - Nov 15 0:00 0 - +Rule Uruguay 1960 only - Jan 17 0:00 1:00 S +Rule Uruguay 1960 only - Mar 6 0:00 0 - +Rule Uruguay 1965 1967 - Apr Sun>=1 0:00 1:00 S +Rule Uruguay 1965 only - Sep 26 0:00 0 - +Rule Uruguay 1966 1967 - Oct 31 0:00 0 - +Rule Uruguay 1968 1970 - May 27 0:00 0:30 HS +Rule Uruguay 1968 1970 - Dec 2 0:00 0 - +Rule Uruguay 1972 only - Apr 24 0:00 1:00 S +Rule Uruguay 1972 only - Aug 15 0:00 0 - +Rule Uruguay 1974 only - Mar 10 0:00 0:30 HS +Rule Uruguay 1974 only - Dec 22 0:00 1:00 S +Rule Uruguay 1976 only - Oct 1 0:00 0 - +Rule Uruguay 1977 only - Dec 4 0:00 1:00 S +Rule Uruguay 1978 only - Apr 1 0:00 0 - +Rule Uruguay 1979 only - Oct 1 0:00 1:00 S +Rule Uruguay 1980 only - May 1 0:00 0 - +Rule Uruguay 1987 only - Dec 14 0:00 1:00 S +Rule Uruguay 1988 only - Mar 14 0:00 0 - +Rule Uruguay 1988 only - Dec 11 0:00 1:00 S +Rule Uruguay 1989 only - Mar 12 0:00 0 - +Rule Uruguay 1989 only - Oct 29 0:00 1:00 S +# Shanks says no DST was observed in 1990/1 and 1991/2, +# and that 1992/3's DST was from 10-25 to 03-01. Go with IATA. +Rule Uruguay 1990 1992 - Mar Sun>=1 0:00 0 - +Rule Uruguay 1990 1991 - Oct Sun>=21 0:00 1:00 S +Rule Uruguay 1992 only - Oct 18 0:00 1:00 S +Rule Uruguay 1993 only - Feb 28 0:00 0 - +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Montevideo -3:44:44 - LMT 1898 Jun 28 + -3:44:44 - MMT 1920 May 1 # Montevideo MT + -3:30 Uruguay UY%sT 1942 Dec 14 # Uruguay Time + -3:00 Uruguay UY%sT + +# Venezuela +# Zone NAME GMTOFF RULES FORMAT [UNTIL] +Zone America/Caracas -4:27:44 - LMT 1890 + -4:27:40 - CMT 1912 Feb 12 # Caracas Mean Time? + -4:30 - VET 1965 # Venezuela Time + -4:00 - VET diff --git a/src/timezone/data/systemv b/src/timezone/data/systemv new file mode 100644 index 0000000000..c6a6b6404b --- /dev/null +++ b/src/timezone/data/systemv @@ -0,0 +1,50 @@ +# @(#)systemv 7.3 + +# Old rules, should the need arise. +# No attempt is made to handle Newfoundland, since it cannot be expressed +# using the System V "TZ" scheme (half-hour offset), or anything outside +# North America (no support for non-standard DST start/end dates), nor +# the change in the DST rules in the US in 1987 (which occurred before +# the old rules were written). +# +# If you need the old rules, uncomment ## lines and comment-out Link lines. +# Compile this *without* leap second correction for true conformance. + +# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S +## Rule SystemV min 1973 - Apr lastSun 2:00 1:00 D +## Rule SystemV min 1973 - Oct lastSun 2:00 0 S +## Rule SystemV 1974 only - Jan 6 2:00 1:00 D +## Rule SystemV 1974 only - Nov lastSun 2:00 0 S +## Rule SystemV 1975 only - Feb 23 2:00 1:00 D +## Rule SystemV 1975 only - Oct lastSun 2:00 0 S +## Rule SystemV 1976 max - Apr lastSun 2:00 1:00 D +## Rule SystemV 1976 max - Oct lastSun 2:00 0 S + +# Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] +## Zone SystemV/AST4ADT -4:00 SystemV A%sT +## Zone SystemV/EST5EDT -5:00 SystemV E%sT +## Zone SystemV/CST6CDT -6:00 SystemV C%sT +## Zone SystemV/MST7MDT -7:00 SystemV M%sT +## Zone SystemV/PST8PDT -8:00 SystemV P%sT +## Zone SystemV/YST9YDT -9:00 SystemV Y%sT +## Zone SystemV/AST4 -4:00 - AST +## Zone SystemV/EST5 -5:00 - EST +## Zone SystemV/CST6 -6:00 - CST +## Zone SystemV/MST7 -7:00 - MST +## Zone SystemV/PST8 -8:00 - PST +## Zone SystemV/YST9 -9:00 - YST +## Zone SystemV/HST10 -10:00 - HST +# For now... +Link America/Halifax SystemV/AST4ADT +Link America/New_York SystemV/EST5EDT +Link America/Chicago SystemV/CST6CDT +Link America/Denver SystemV/MST7MDT +Link America/Los_Angeles SystemV/PST8PDT +Link America/Anchorage SystemV/YST9YDT +Link America/Puerto_Rico SystemV/AST4 +Link America/Indianapolis SystemV/EST5 +Link America/Regina SystemV/CST6 +Link America/Phoenix SystemV/MST7 +Link Pacific/Pitcairn SystemV/PST8 +Link Pacific/Gambier SystemV/YST9 +Link Pacific/Honolulu SystemV/HST10 diff --git a/src/timezone/data/yearistype.sh b/src/timezone/data/yearistype.sh new file mode 100755 index 0000000000..8d796f1f21 --- /dev/null +++ b/src/timezone/data/yearistype.sh @@ -0,0 +1,37 @@ +#! /bin/sh + +: '@(#)yearistype.sh 7.7' + +case $#-$1 in + 2-|2-0*|2-*[!0-9]*) + echo "$0: wild year - $1" >&2 + exit 1 ;; +esac + +case $#-$2 in + 2-even) + case $1 in + *[24680]) exit 0 ;; + *) exit 1 ;; + esac ;; + 2-nonpres|2-nonuspres) + case $1 in + *[02468][048]|*[13579][26]) exit 1 ;; + *) exit 0 ;; + esac ;; + 2-odd) + case $1 in + *[13579]) exit 0 ;; + *) exit 1 ;; + esac ;; + 2-uspres) + case $1 in + *[02468][048]|*[13579][26]) exit 0 ;; + *) exit 1 ;; + esac ;; + 2-*) + echo "$0: wild type - $2" >&2 ;; +esac + +echo "$0: usage is $0 year even|odd|uspres|nonpres|nonuspres" >&2 +exit 1 diff --git a/src/timezone/data/zone.tab b/src/timezone/data/zone.tab new file mode 100644 index 0000000000..be41eb1831 --- /dev/null +++ b/src/timezone/data/zone.tab @@ -0,0 +1,402 @@ +# @(#)zone.tab 1.29 +# +# TZ zone descriptions +# +# From Paul Eggert (1996-08-05): +# +# This file contains a table with the following columns: +# 1. ISO 3166 2-character country code. See the file `iso3166.tab'. +# 2. Latitude and longitude of the zone's principal location +# in ISO 6709 sign-degrees-minutes-seconds format, +# either +-DDMM+-DDDMM or +-DDMMSS+-DDDMMSS, +# first latitude (+ is north), then longitude (+ is east). +# 3. Zone name used in value of TZ environment variable. +# 4. Comments; present if and only if the country has multiple rows. +# +# Columns are separated by a single tab. +# The table is sorted first by country, then an order within the country that +# (1) makes some geographical sense, and +# (2) puts the most populous zones first, where that does not contradict (1). +# +# Lines beginning with `#' are comments. +# +#country- +#code coordinates TZ comments +AD +4230+00131 Europe/Andorra +AE +2518+05518 Asia/Dubai +AF +3431+06912 Asia/Kabul +AG +1703-06148 America/Antigua +AI +1812-06304 America/Anguilla +AL +4120+01950 Europe/Tirane +AM +4011+04430 Asia/Yerevan +AN +1211-06900 America/Curacao +AO -0848+01314 Africa/Luanda +AQ -7750+16636 Antarctica/McMurdo McMurdo Station, Ross Island +AQ -9000+00000 Antarctica/South_Pole Amundsen-Scott Station, South Pole +AQ -6734-06808 Antarctica/Rothera Rothera Station, Adelaide Island +AQ -6448-06406 Antarctica/Palmer Palmer Station, Anvers Island +AQ -6736+06253 Antarctica/Mawson Mawson Station, Holme Bay +AQ -6835+07758 Antarctica/Davis Davis Station, Vestfold Hills +AQ -6617+11031 Antarctica/Casey Casey Station, Bailey Peninsula +AQ -7824+10654 Antarctica/Vostok Vostok Station, S Magnetic Pole +AQ -6640+14001 Antarctica/DumontDUrville Dumont-d'Urville Base, Terre Adelie +AQ -690022+0393524 Antarctica/Syowa Syowa Station, E Ongul I +AR -3436-05827 America/Buenos_Aires E Argentina (BA, DF, SC, TF) +AR -3124-06411 America/Cordoba most locations (CB,CC,CH,CN,ER,FM,LP,LR,MN,NQ,RN,SA,SE,SF,SJ,SL,TM) +AR -2411-06518 America/Jujuy Jujuy (JY) +AR -2828-06547 America/Catamarca Catamarca (CT) +AR -3253-06849 America/Mendoza Mendoza (MZ) +AS -1416-17042 Pacific/Pago_Pago +AT +4813+01620 Europe/Vienna +AU -3133+15905 Australia/Lord_Howe Lord Howe Island +AU -4253+14719 Australia/Hobart Tasmania +AU -3749+14458 Australia/Melbourne Victoria +AU -3352+15113 Australia/Sydney New South Wales - most locations +AU -3157+14127 Australia/Broken_Hill New South Wales - Yancowinna +AU -2728+15302 Australia/Brisbane Queensland - most locations +AU -2016+14900 Australia/Lindeman Queensland - Holiday Islands +AU -3455+13835 Australia/Adelaide South Australia +AU -1228+13050 Australia/Darwin Northern Territory +AU -3157+11551 Australia/Perth Western Australia +AW +1230-06858 America/Aruba +AZ +4023+04951 Asia/Baku +BA +4352+01825 Europe/Sarajevo +BB +1306-05937 America/Barbados +BD +2343+09025 Asia/Dhaka +BE +5050+00420 Europe/Brussels +BF +1222-00131 Africa/Ouagadougou +BG +4241+02319 Europe/Sofia +BH +2623+05035 Asia/Bahrain +BI -0323+02922 Africa/Bujumbura +BJ +0629+00237 Africa/Porto-Novo +BM +3217-06446 Atlantic/Bermuda +BN +0456+11455 Asia/Brunei +BO -1630-06809 America/La_Paz +BR -0351-03225 America/Noronha Atlantic islands +BR -0127-04829 America/Belem Amapa, E Para +BR -0343-03830 America/Fortaleza NE Brazil (MA, PI, CE, RN, PB) +BR -0803-03454 America/Recife Pernambuco +BR -0712-04812 America/Araguaina Tocantins +BR -0940-03543 America/Maceio Alagoas, Sergipe +BR -1259-03831 America/Bahia Bahia +BR -2332-04637 America/Sao_Paulo S & SE Brazil (GO, DF, MG, ES, RJ, SP, PR, SC, RS) +BR -2027-05437 America/Campo_Grande Mato Grosso do Sul +BR -1535-05605 America/Cuiaba Mato Grosso +BR -0846-06354 America/Porto_Velho W Para, Rondonia +BR +0249-06040 America/Boa_Vista Roraima +BR -0308-06001 America/Manaus E Amazonas +BR -0640-06952 America/Eirunepe W Amazonas +BR -0958-06748 America/Rio_Branco Acre +BS +2505-07721 America/Nassau +BT +2728+08939 Asia/Thimphu +BW -2545+02555 Africa/Gaborone +BY +5354+02734 Europe/Minsk +BZ +1730-08812 America/Belize +CA +4734-05243 America/St_Johns Newfoundland Island +CA +4439-06336 America/Halifax Atlantic Time - Nova Scotia (most places), NB, W Labrador, E Quebec & PEI +CA +4612-05957 America/Glace_Bay Atlantic Time - Nova Scotia - places that did not observe DST 1966-1971 +CA +5320-06025 America/Goose_Bay Atlantic Time - E Labrador +CA +4531-07334 America/Montreal Eastern Time - Quebec - most locations +CA +4339-07923 America/Toronto Eastern Time - Ontario - most locations +CA +4901-08816 America/Nipigon Eastern Time - Ontario & Quebec - places that did not observe DST 1967-1973 +CA +4823-08915 America/Thunder_Bay Eastern Time - Thunder Bay, Ontario +CA +6608-06544 America/Pangnirtung Eastern Standard Time - Pangnirtung, Nunavut +CA +6344-06828 America/Iqaluit Eastern Standard Time - east Nunavut +CA +6245-09210 America/Rankin_Inlet Eastern Standard Time - central Nunavut +CA +4953-09709 America/Winnipeg Central Time - Manitoba & west Ontario +CA +4843-09429 America/Rainy_River Central Time - Rainy River & Fort Frances, Ontario +CA +6903-10505 America/Cambridge_Bay Central Time - west Nunavut +CA +5024-10439 America/Regina Central Standard Time - Saskatchewan - most locations +CA +5017-10750 America/Swift_Current Central Standard Time - Saskatchewan - midwest +CA +5333-11328 America/Edmonton Mountain Time - Alberta, east British Columbia & west Saskatchewan +CA +6227-11421 America/Yellowknife Mountain Time - central Northwest Territories +CA +6825-11330 America/Inuvik Mountain Time - west Northwest Territories +CA +5946-12014 America/Dawson_Creek Mountain Standard Time - Dawson Creek & Fort Saint John, British Columbia +CA +4916-12307 America/Vancouver Pacific Time - west British Columbia +CA +6043-13503 America/Whitehorse Pacific Time - south Yukon +CA +6404-13925 America/Dawson Pacific Time - north Yukon +CC -1210+09655 Indian/Cocos +CD -0418+01518 Africa/Kinshasa west Dem. Rep. of Congo +CD -1140+02728 Africa/Lubumbashi east Dem. Rep. of Congo +CF +0422+01835 Africa/Bangui +CG -0416+01517 Africa/Brazzaville +CH +4723+00832 Europe/Zurich +CI +0519-00402 Africa/Abidjan +CK -2114-15946 Pacific/Rarotonga +CL -3327-07040 America/Santiago most locations +CL -2710-10927 Pacific/Easter Easter Island & Sala y Gomez +CM +0403+00942 Africa/Douala +CN +3114+12128 Asia/Shanghai east China - Beijing, Guangdong, Shanghai, etc. +CN +4545+12641 Asia/Harbin Heilongjiang +CN +2934+10635 Asia/Chongqing central China - Gansu, Guizhou, Sichuan, Yunnan, etc. +CN +4348+08735 Asia/Urumqi Tibet & most of Xinjiang Uyghur +CN +3929+07559 Asia/Kashgar southwest Xinjiang Uyghur +CO +0436-07405 America/Bogota +CR +0956-08405 America/Costa_Rica +CS +4450+02030 Europe/Belgrade +CU +2308-08222 America/Havana +CV +1455-02331 Atlantic/Cape_Verde +CX -1025+10543 Indian/Christmas +CY +3510+03322 Asia/Nicosia +CZ +5005+01426 Europe/Prague +DE +5230+01322 Europe/Berlin +DJ +1136+04309 Africa/Djibouti +DK +5540+01235 Europe/Copenhagen +DM +1518-06124 America/Dominica +DO +1828-06954 America/Santo_Domingo +DZ +3647+00303 Africa/Algiers +EC -0210-07950 America/Guayaquil mainland +EC -0054-08936 Pacific/Galapagos Galapagos Islands +EE +5925+02445 Europe/Tallinn +EG +3003+03115 Africa/Cairo +EH +2709-01312 Africa/El_Aaiun +ER +1520+03853 Africa/Asmera +ES +4024-00341 Europe/Madrid mainland +ES +3553-00519 Africa/Ceuta Ceuta & Melilla +ES +2806-01524 Atlantic/Canary Canary Islands +ET +0902+03842 Africa/Addis_Ababa +FI +6010+02458 Europe/Helsinki +FJ -1808+17825 Pacific/Fiji +FK -5142-05751 Atlantic/Stanley +FM +0931+13808 Pacific/Yap Yap +FM +0725+15147 Pacific/Truk Truk (Chuuk) +FM +0658+15813 Pacific/Ponape Ponape (Pohnpei) +FM +0519+16259 Pacific/Kosrae Kosrae +FO +6201-00646 Atlantic/Faeroe +FR +4852+00220 Europe/Paris +GA +0023+00927 Africa/Libreville +GB +512830-0001845 Europe/London Great Britain +GB +5435-00555 Europe/Belfast Northern Ireland +GD +1203-06145 America/Grenada +GE +4143+04449 Asia/Tbilisi +GF +0456-05220 America/Cayenne +GH +0533-00013 Africa/Accra +GI +3608-00521 Europe/Gibraltar +GL +6411-05144 America/Godthab most locations +GL +7646-01840 America/Danmarkshavn east coast, north of Scoresbysund +GL +7030-02215 America/Scoresbysund Scoresbysund / Ittoqqortoormiit +GL +7634-06847 America/Thule Thule / Pituffik +GM +1328-01639 Africa/Banjul +GN +0931-01343 Africa/Conakry +GP +1614-06132 America/Guadeloupe +GQ +0345+00847 Africa/Malabo +GR +3758+02343 Europe/Athens +GS -5416-03632 Atlantic/South_Georgia +GT +1438-09031 America/Guatemala +GU +1328+14445 Pacific/Guam +GW +1151-01535 Africa/Bissau +GY +0648-05810 America/Guyana +HK +2217+11409 Asia/Hong_Kong +HN +1406-08713 America/Tegucigalpa +HR +4548+01558 Europe/Zagreb +HT +1832-07220 America/Port-au-Prince +HU +4730+01905 Europe/Budapest +ID -0610+10648 Asia/Jakarta Java & Sumatra +ID -0002+10920 Asia/Pontianak west & central Borneo +ID -0507+11924 Asia/Makassar east & south Borneo, Celebes, Bali, Nusa Tengarra, west Timor +ID -0232+14042 Asia/Jayapura Irian Jaya & the Moluccas +IE +5320-00615 Europe/Dublin +IL +3146+03514 Asia/Jerusalem +IN +2232+08822 Asia/Calcutta +IO -0720+07225 Indian/Chagos +IQ +3321+04425 Asia/Baghdad +IR +3540+05126 Asia/Tehran +IS +6409-02151 Atlantic/Reykjavik +IT +4154+01229 Europe/Rome +JM +1800-07648 America/Jamaica +JO +3157+03556 Asia/Amman +JP +353916+1394441 Asia/Tokyo +KE -0117+03649 Africa/Nairobi +KG +4254+07436 Asia/Bishkek +KH +1133+10455 Asia/Phnom_Penh +KI +0125+17300 Pacific/Tarawa Gilbert Islands +KI -0308-17105 Pacific/Enderbury Phoenix Islands +KI +0152-15720 Pacific/Kiritimati Line Islands +KM -1141+04316 Indian/Comoro +KN +1718-06243 America/St_Kitts +KP +3901+12545 Asia/Pyongyang +KR +3733+12658 Asia/Seoul +KW +2920+04759 Asia/Kuwait +KY +1918-08123 America/Cayman +KZ +4315+07657 Asia/Almaty most locations +KZ +4448+06528 Asia/Qyzylorda Qyzylorda (Kyzylorda, Kzyl-Orda) +KZ +5017+05710 Asia/Aqtobe Aqtobe (Aktobe) +KZ +4431+05016 Asia/Aqtau Atyrau (Atirau, Gur'yev), Mangghystau (Mankistau) +KZ +5113+05121 Asia/Oral West Kazakhstan +LA +1758+10236 Asia/Vientiane +LB +3353+03530 Asia/Beirut +LC +1401-06100 America/St_Lucia +LI +4709+00931 Europe/Vaduz +LK +0656+07951 Asia/Colombo +LR +0618-01047 Africa/Monrovia +LS -2928+02730 Africa/Maseru +LT +5441+02519 Europe/Vilnius +LU +4936+00609 Europe/Luxembourg +LV +5657+02406 Europe/Riga +LY +3254+01311 Africa/Tripoli +MA +3339-00735 Africa/Casablanca +MC +4342+00723 Europe/Monaco +MD +4700+02850 Europe/Chisinau +MG -1855+04731 Indian/Antananarivo +MH +0709+17112 Pacific/Majuro most locations +MH +0905+16720 Pacific/Kwajalein Kwajalein +MK +4159+02126 Europe/Skopje +ML +1239-00800 Africa/Bamako southwest Mali +ML +1446-00301 Africa/Timbuktu northeast Mali +MM +1647+09610 Asia/Rangoon +MN +4755+10653 Asia/Ulaanbaatar most locations +MN +4801+09139 Asia/Hovd Bayan-Olgiy, Govi-Altai, Hovd, Uvs, Zavkhan +MN +4804+11430 Asia/Choibalsan Dornod, Sukhbaatar +MO +2214+11335 Asia/Macau +MP +1512+14545 Pacific/Saipan +MQ +1436-06105 America/Martinique +MR +1806-01557 Africa/Nouakchott +MS +1644-06213 America/Montserrat +MT +3554+01431 Europe/Malta +MU -2010+05730 Indian/Mauritius +MV +0410+07330 Indian/Maldives +MW -1547+03500 Africa/Blantyre +MX +1924-09909 America/Mexico_City Central Time - most locations +MX +2105-08646 America/Cancun Central Time - Quintana Roo +MX +2058-08937 America/Merida Central Time - Campeche, Yucatan +MX +2540-10019 America/Monterrey Central Time - Coahuila, Durango, Nuevo Leon, Tamaulipas +MX +2313-10625 America/Mazatlan Mountain Time - S Baja, Nayarit, Sinaloa +MX +2838-10605 America/Chihuahua Mountain Time - Chihuahua +MX +2904-11058 America/Hermosillo Mountain Standard Time - Sonora +MX +3232-11701 America/Tijuana Pacific Time +MY +0310+10142 Asia/Kuala_Lumpur peninsular Malaysia +MY +0133+11020 Asia/Kuching Sabah & Sarawak +MZ -2558+03235 Africa/Maputo +NA -2234+01706 Africa/Windhoek +NC -2216+16530 Pacific/Noumea +NE +1331+00207 Africa/Niamey +NF -2903+16758 Pacific/Norfolk +NG +0627+00324 Africa/Lagos +NI +1209-08617 America/Managua +NL +5222+00454 Europe/Amsterdam +NO +5955+01045 Europe/Oslo +NP +2743+08519 Asia/Katmandu +NR -0031+16655 Pacific/Nauru +NU -1901+16955 Pacific/Niue +NZ -3652+17446 Pacific/Auckland most locations +NZ -4357-17633 Pacific/Chatham Chatham Islands +OM +2336+05835 Asia/Muscat +PA +0858-07932 America/Panama +PE -1203-07703 America/Lima +PF -1732-14934 Pacific/Tahiti Society Islands +PF -0900-13930 Pacific/Marquesas Marquesas Islands +PF -2308-13457 Pacific/Gambier Gambier Islands +PG -0930+14710 Pacific/Port_Moresby +PH +1435+12100 Asia/Manila +PK +2452+06703 Asia/Karachi +PL +5215+02100 Europe/Warsaw +PM +4703-05620 America/Miquelon +PN -2504-13005 Pacific/Pitcairn +PR +182806-0660622 America/Puerto_Rico +PS +3130+03428 Asia/Gaza +PT +3843-00908 Europe/Lisbon mainland +PT +3238-01654 Atlantic/Madeira Madeira Islands +PT +3744-02540 Atlantic/Azores Azores +PW +0720+13429 Pacific/Palau +PY -2516-05740 America/Asuncion +QA +2517+05132 Asia/Qatar +RE -2052+05528 Indian/Reunion +RO +4426+02606 Europe/Bucharest +RU +5443+02030 Europe/Kaliningrad Moscow-01 - Kaliningrad +RU +5545+03735 Europe/Moscow Moscow+00 - west Russia +RU +5312+05009 Europe/Samara Moscow+01 - Caspian Sea +RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals +RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia +RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk +RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River +RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal +RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River +RU +4310+13156 Asia/Vladivostok Moscow+07 - Amur River +RU +4658+14242 Asia/Sakhalin Moscow+07 - Sakhalin Island +RU +5934+15048 Asia/Magadan Moscow+08 - Magadan +RU +5301+15839 Asia/Kamchatka Moscow+09 - Kamchatka +RU +6445+17729 Asia/Anadyr Moscow+10 - Bering Sea +RW -0157+03004 Africa/Kigali +SA +2438+04643 Asia/Riyadh +SB -0932+16012 Pacific/Guadalcanal +SC -0440+05528 Indian/Mahe +SD +1536+03232 Africa/Khartoum +SE +5920+01803 Europe/Stockholm +SG +0117+10351 Asia/Singapore +SH -1555-00542 Atlantic/St_Helena +SI +4603+01431 Europe/Ljubljana +SJ +7800+01600 Arctic/Longyearbyen Svalbard +SJ +7059-00805 Atlantic/Jan_Mayen Jan Mayen +SK +4809+01707 Europe/Bratislava +SL +0830-01315 Africa/Freetown +SM +4355+01228 Europe/San_Marino +SN +1440-01726 Africa/Dakar +SO +0204+04522 Africa/Mogadishu +SR +0550-05510 America/Paramaribo +ST +0020+00644 Africa/Sao_Tome +SV +1342-08912 America/El_Salvador +SY +3330+03618 Asia/Damascus +SZ -2618+03106 Africa/Mbabane +TC +2128-07108 America/Grand_Turk +TD +1207+01503 Africa/Ndjamena +TF -492110+0701303 Indian/Kerguelen +TG +0608+00113 Africa/Lome +TH +1345+10031 Asia/Bangkok +TJ +3835+06848 Asia/Dushanbe +TK -0922-17114 Pacific/Fakaofo +TL -0833+12535 Asia/Dili +TM +3757+05823 Asia/Ashgabat +TN +3648+01011 Africa/Tunis +TO -2110+17510 Pacific/Tongatapu +TR +4101+02858 Europe/Istanbul +TT +1039-06131 America/Port_of_Spain +TV -0831+17913 Pacific/Funafuti +TW +2503+12130 Asia/Taipei +TZ -0648+03917 Africa/Dar_es_Salaam +UA +5026+03031 Europe/Kiev most locations +UA +4837+02218 Europe/Uzhgorod Ruthenia +UA +4750+03510 Europe/Zaporozhye Zaporozh'ye, E Lugansk +UA +4457+03406 Europe/Simferopol central Crimea +UG +0019+03225 Africa/Kampala +UM +1700-16830 Pacific/Johnston Johnston Atoll +UM +2813-17722 Pacific/Midway Midway Islands +UM +1917+16637 Pacific/Wake Wake Island +US +404251-0740023 America/New_York Eastern Time +US +421953-0830245 America/Detroit Eastern Time - Michigan - most locations +US +381515-0854534 America/Louisville Eastern Time - Kentucky - Louisville area +US +364947-0845057 America/Kentucky/Monticello Eastern Time - Kentucky - Wayne County +US +394606-0860929 America/Indianapolis Eastern Standard Time - Indiana - most locations +US +382232-0862041 America/Indiana/Marengo Eastern Standard Time - Indiana - Crawford County +US +411745-0863730 America/Indiana/Knox Eastern Standard Time - Indiana - Starke County +US +384452-0850402 America/Indiana/Vevay Eastern Standard Time - Indiana - Switzerland County +US +415100-0873900 America/Chicago Central Time +US +450628-0873651 America/Menominee Central Time - Michigan - Wisconsin border +US +470659-1011757 America/North_Dakota/Center Central Time - North Dakota - Oliver County +US +394421-1045903 America/Denver Mountain Time +US +433649-1161209 America/Boise Mountain Time - south Idaho & east Oregon +US +364708-1084111 America/Shiprock Mountain Time - Navajo +US +332654-1120424 America/Phoenix Mountain Standard Time - Arizona +US +340308-1181434 America/Los_Angeles Pacific Time +US +611305-1495401 America/Anchorage Alaska Time +US +581807-1342511 America/Juneau Alaska Time - Alaska panhandle +US +593249-1394338 America/Yakutat Alaska Time - Alaska panhandle neck +US +643004-1652423 America/Nome Alaska Time - west Alaska +US +515248-1763929 America/Adak Aleutian Islands +US +211825-1575130 Pacific/Honolulu Hawaii +UY -3453-05611 America/Montevideo +UZ +3940+06648 Asia/Samarkand west Uzbekistan +UZ +4120+06918 Asia/Tashkent east Uzbekistan +VA +4154+01227 Europe/Vatican +VC +1309-06114 America/St_Vincent +VE +1030-06656 America/Caracas +VG +1827-06437 America/Tortola +VI +1821-06456 America/St_Thomas +VN +1045+10640 Asia/Saigon +VU -1740+16825 Pacific/Efate +WF -1318-17610 Pacific/Wallis +WS -1350-17144 Pacific/Apia +YE +1245+04512 Asia/Aden +YT -1247+04514 Indian/Mayotte +ZA -2615+02800 Africa/Johannesburg +ZM -1525+02817 Africa/Lusaka +ZW -1750+03103 Africa/Harare diff --git a/src/timezone/difftime.c b/src/timezone/difftime.c new file mode 100644 index 0000000000..a4aa631d15 --- /dev/null +++ b/src/timezone/difftime.c @@ -0,0 +1,83 @@ +/* +** This file is in the public domain, so clarified as of +** June 5, 1996 by Arthur David Olson (arthur_david_olson@nih.gov). +*/ + +#ifndef lint +#ifndef NOID +static char elsieid[] = "@(#)difftime.c 7.9"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/*LINTLIBRARY*/ + +#include "private.h" + +/* +** Algorithm courtesy Paul Eggert (eggert@twinsun.com). +*/ + +#ifdef HAVE_LONG_DOUBLE +#define long_double long double +#endif /* defined HAVE_LONG_DOUBLE */ +#ifndef HAVE_LONG_DOUBLE +#define long_double double +#endif /* !defined HAVE_LONG_DOUBLE */ + +double +difftime(time1, time0) +const time_t time1; +const time_t time0; +{ + time_t delta; + time_t hibit; + + { + time_t tt; + double d; + long_double ld; + + if (sizeof tt < sizeof d) + return (double) time1 - (double) time0; + if (sizeof tt < sizeof ld) + return (long_double) time1 - (long_double) time0; + } + if (time1 < time0) + return -difftime(time0, time1); + /* + ** As much as possible, avoid loss of precision + ** by computing the difference before converting to double. + */ + delta = time1 - time0; + if (delta >= 0) + return delta; + /* + ** Repair delta overflow. + */ + hibit = (~ (time_t) 0) << (TYPE_BIT(time_t) - 1); + /* + ** The following expression rounds twice, which means + ** the result may not be the closest to the true answer. + ** For example, suppose time_t is 64-bit signed int, + ** long_double is IEEE 754 double with default rounding, + ** time1 = 9223372036854775807 and time0 = -1536. + ** Then the true difference is 9223372036854777343, + ** which rounds to 9223372036854777856 + ** with a total error of 513. + ** But delta overflows to -9223372036854774273, + ** which rounds to -9223372036854774784, and correcting + ** this by subtracting 2 * (long_double) hibit + ** (i.e. by adding 2**64 = 18446744073709551616) + ** yields 9223372036854776832, which + ** rounds to 9223372036854775808 + ** with a total error of 1535 instead. + ** This problem occurs only with very large differences. + ** It's too painful to fix this portably. + ** We are not alone in this problem; + ** some C compilers round twice when converting + ** large unsigned types to small floating types, + ** so if time_t is unsigned the "return delta" above + ** has the same double-rounding problem with those compilers. + */ + return delta - 2 * (long_double) hibit; +} diff --git a/src/timezone/ialloc.c b/src/timezone/ialloc.c new file mode 100644 index 0000000000..ea457aeb66 --- /dev/null +++ b/src/timezone/ialloc.c @@ -0,0 +1,81 @@ +#ifndef lint +#ifndef NOID +static char elsieid[] = "@(#)ialloc.c 8.29"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/*LINTLIBRARY*/ + +#include "private.h" + +#define nonzero(n) (((n) == 0) ? 1 : (n)) + +char * +imalloc(n) +const int n; +{ + return malloc((size_t) nonzero(n)); +} + +char * +icalloc(nelem, elsize) +int nelem; +int elsize; +{ + if (nelem == 0 || elsize == 0) + nelem = elsize = 1; + return calloc((size_t) nelem, (size_t) elsize); +} + +void * +irealloc(pointer, size) +void * const pointer; +const int size; +{ + if (pointer == NULL) + return imalloc(size); + return realloc((void *) pointer, (size_t) nonzero(size)); +} + +char * +icatalloc(old, new) +char * const old; +const char * const new; +{ + register char * result; + register int oldsize, newsize; + + newsize = (new == NULL) ? 0 : strlen(new); + if (old == NULL) + oldsize = 0; + else if (newsize == 0) + return old; + else oldsize = strlen(old); + if ((result = irealloc(old, oldsize + newsize + 1)) != NULL) + if (new != NULL) + (void) strcpy(result + oldsize, new); + return result; +} + +char * +icpyalloc(string) +const char * const string; +{ + return icatalloc((char *) NULL, string); +} + +void +ifree(p) +char * const p; +{ + if (p != NULL) + (void) free(p); +} + +void +icfree(p) +char * const p; +{ + if (p != NULL) + (void) free(p); +} diff --git a/src/timezone/localtime.c b/src/timezone/localtime.c new file mode 100644 index 0000000000..33e22a5e20 --- /dev/null +++ b/src/timezone/localtime.c @@ -0,0 +1,1707 @@ +/* +** This file is in the public domain, so clarified as of +** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). +*/ + +#ifndef lint +#ifndef NOID +static char elsieid[] = "@(#)localtime.c 7.78"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/* +** Leap second handling from Bradley White (bww@k.gp.cs.cmu.edu). +** POSIX-style TZ environment variable handling from Guy Harris +** (guy@auspex.com). +*/ + +/*LINTLIBRARY*/ + +#include "private.h" +#include "tzfile.h" +#include "fcntl.h" + +/* +** SunOS 4.1.1 headers lack O_BINARY. +*/ + +#ifdef O_BINARY +#define OPEN_MODE (O_RDONLY | O_BINARY) +#endif /* defined O_BINARY */ +#ifndef O_BINARY +#define OPEN_MODE O_RDONLY +#endif /* !defined O_BINARY */ + +#ifndef WILDABBR +/* +** Someone might make incorrect use of a time zone abbreviation: +** 1. They might reference tzname[0] before calling tzset (explicitly +** or implicitly). +** 2. They might reference tzname[1] before calling tzset (explicitly +** or implicitly). +** 3. They might reference tzname[1] after setting to a time zone +** in which Daylight Saving Time is never observed. +** 4. They might reference tzname[0] after setting to a time zone +** in which Standard Time is never observed. +** 5. They might reference tm.TM_ZONE after calling offtime. +** What's best to do in the above cases is open to debate; +** for now, we just set things up so that in any of the five cases +** WILDABBR is used. Another possibility: initialize tzname[0] to the +** string "tzname[0] used before set", and similarly for the other cases. +** And another: initialize tzname[0] to "ERA", with an explanation in the +** manual page of what this "time zone abbreviation" means (doing this so +** that tzname[0] has the "normal" length of three characters). +*/ +#define WILDABBR " " +#endif /* !defined WILDABBR */ + +static char wildabbr[] = "WILDABBR"; + +static const char gmt[] = "GMT"; + +/* +** The DST rules to use if TZ has no rules and we can't load TZDEFRULES. +** We default to US rules as of 1999-08-17. +** POSIX 1003.1 section 8.1.1 says that the default DST rules are +** implementation dependent; for historical reasons, US rules are a +** common default. +*/ +#ifndef TZDEFRULESTRING +#define TZDEFRULESTRING ",M4.1.0,M10.5.0" +#endif /* !defined TZDEFDST */ + +struct ttinfo { /* time type information */ + long tt_gmtoff; /* UTC offset in seconds */ + int tt_isdst; /* used to set tm_isdst */ + int tt_abbrind; /* abbreviation list index */ + int tt_ttisstd; /* TRUE if transition is std time */ + int tt_ttisgmt; /* TRUE if transition is UTC */ +}; + +struct lsinfo { /* leap second information */ + time_t ls_trans; /* transition time */ + long ls_corr; /* correction to apply */ +}; + +#define BIGGEST(a, b) (((a) > (b)) ? (a) : (b)) + +#ifdef TZNAME_MAX +#define MY_TZNAME_MAX TZNAME_MAX +#endif /* defined TZNAME_MAX */ +#ifndef TZNAME_MAX +#define MY_TZNAME_MAX 255 +#endif /* !defined TZNAME_MAX */ + +struct state { + int leapcnt; + int timecnt; + int typecnt; + int charcnt; + time_t ats[TZ_MAX_TIMES]; + unsigned char types[TZ_MAX_TIMES]; + struct ttinfo ttis[TZ_MAX_TYPES]; + char chars[BIGGEST(BIGGEST(TZ_MAX_CHARS + 1, sizeof gmt), + (2 * (MY_TZNAME_MAX + 1)))]; + struct lsinfo lsis[TZ_MAX_LEAPS]; +}; + +struct rule { + int r_type; /* type of rule--see below */ + int r_day; /* day number of rule */ + int r_week; /* week number of rule */ + int r_mon; /* month number of rule */ + long r_time; /* transition time of rule */ +}; + +#define JULIAN_DAY 0 /* Jn - Julian day */ +#define DAY_OF_YEAR 1 /* n - day of year */ +#define MONTH_NTH_DAY_OF_WEEK 2 /* Mm.n.d - month, week, day of week */ + +/* +** Prototypes for static functions. +*/ + +static long detzcode P((const char * codep)); +static const char * getzname P((const char * strp)); +static const char * getnum P((const char * strp, int * nump, int min, + int max)); +static const char * getsecs P((const char * strp, long * secsp)); +static const char * getoffset P((const char * strp, long * offsetp)); +static const char * getrule P((const char * strp, struct rule * rulep)); +static void gmtload P((struct state * sp)); +static void gmtsub P((const time_t * timep, long offset, + struct tm * tmp)); +static void localsub P((const time_t * timep, long offset, + struct tm * tmp)); +static int increment_overflow P((int * number, int delta)); +static int normalize_overflow P((int * tensptr, int * unitsptr, + int base)); +static void settzname P((void)); +static time_t time1 P((struct tm * tmp, + void(*funcp) P((const time_t *, + long, struct tm *)), + long offset)); +static time_t time2 P((struct tm *tmp, + void(*funcp) P((const time_t *, + long, struct tm*)), + long offset, int * okayp)); +static time_t time2sub P((struct tm *tmp, + void(*funcp) P((const time_t *, + long, struct tm*)), + long offset, int * okayp, int do_norm_secs)); +static void timesub P((const time_t * timep, long offset, + const struct state * sp, struct tm * tmp)); +static int tmcomp P((const struct tm * atmp, + const struct tm * btmp)); +static time_t transtime P((time_t janfirst, int year, + const struct rule * rulep, long offset)); +static int tzload P((const char * name, struct state * sp)); +static int tzparse P((const char * name, struct state * sp, + int lastditch)); + +#ifdef ALL_STATE +static struct state * lclptr; +static struct state * gmtptr; +#endif /* defined ALL_STATE */ + +#ifndef ALL_STATE +static struct state lclmem; +static struct state gmtmem; +#define lclptr (&lclmem) +#define gmtptr (&gmtmem) +#endif /* State Farm */ + +#ifndef TZ_STRLEN_MAX +#define TZ_STRLEN_MAX 255 +#endif /* !defined TZ_STRLEN_MAX */ + +static char lcl_TZname[TZ_STRLEN_MAX + 1]; +static int lcl_is_set; +static int gmt_is_set; + +char * tzname[2] = { + wildabbr, + wildabbr +}; + +/* +** Section 4.12.3 of X3.159-1989 requires that +** Except for the strftime function, these functions [asctime, +** ctime, gmtime, localtime] return values in one of two static +** objects: a broken-down time structure and an array of char. +** Thanks to Paul Eggert (eggert@twinsun.com) for noting this. +*/ + +static struct tm tm; + +#ifdef USG_COMPAT +time_t timezone = 0; +int daylight = 0; +#endif /* defined USG_COMPAT */ + +#ifdef ALTZONE +time_t altzone = 0; +#endif /* defined ALTZONE */ + +static long +detzcode(codep) +const char * const codep; +{ + register long result; + register int i; + + result = (codep[0] & 0x80) ? ~0L : 0L; + for (i = 0; i < 4; ++i) + result = (result << 8) | (codep[i] & 0xff); + return result; +} + +static void +settzname P((void)) +{ + register struct state * const sp = lclptr; + register int i; + + tzname[0] = wildabbr; + tzname[1] = wildabbr; +#ifdef USG_COMPAT + daylight = 0; + timezone = 0; +#endif /* defined USG_COMPAT */ +#ifdef ALTZONE + altzone = 0; +#endif /* defined ALTZONE */ +#ifdef ALL_STATE + if (sp == NULL) { + tzname[0] = tzname[1] = gmt; + return; + } +#endif /* defined ALL_STATE */ + for (i = 0; i < sp->typecnt; ++i) { + register const struct ttinfo * const ttisp = &sp->ttis[i]; + + tzname[ttisp->tt_isdst] = + &sp->chars[ttisp->tt_abbrind]; +#ifdef USG_COMPAT + if (ttisp->tt_isdst) + daylight = 1; + if (i == 0 || !ttisp->tt_isdst) + timezone = -(ttisp->tt_gmtoff); +#endif /* defined USG_COMPAT */ +#ifdef ALTZONE + if (i == 0 || ttisp->tt_isdst) + altzone = -(ttisp->tt_gmtoff); +#endif /* defined ALTZONE */ + } + /* + ** And to get the latest zone names into tzname. . . + */ + for (i = 0; i < sp->timecnt; ++i) { + register const struct ttinfo * const ttisp = + &sp->ttis[ + sp->types[i]]; + + tzname[ttisp->tt_isdst] = + &sp->chars[ttisp->tt_abbrind]; + } +} + +static int +tzload(name, sp) +register const char * name; +register struct state * const sp; +{ + register const char * p; + register int i; + register int fid; + + if (name == NULL && (name = TZDEFAULT) == NULL) + return -1; + { + register int doaccess; + /* + ** Section 4.9.1 of the C standard says that + ** "FILENAME_MAX expands to an integral constant expression + ** that is the size needed for an array of char large enough + ** to hold the longest file name string that the implementation + ** guarantees can be opened." + */ + char fullname[FILENAME_MAX + 1]; + + if (name[0] == ':') + ++name; + doaccess = name[0] == '/'; + if (!doaccess) { + if ((p = TZDIR) == NULL) + return -1; + if ((strlen(p) + strlen(name) + 1) >= sizeof fullname) + return -1; + (void) strcpy(fullname, p); + (void) strcat(fullname, "/"); + (void) strcat(fullname, name); + /* + ** Set doaccess if '.' (as in "../") shows up in name. + */ + if (strchr(name, '.') != NULL) + doaccess = TRUE; + name = fullname; + } + if (doaccess && access(name, R_OK) != 0) + return -1; + if ((fid = open(name, OPEN_MODE)) == -1) + return -1; + } + { + struct tzhead * tzhp; + union { + struct tzhead tzhead; + char buf[sizeof *sp + sizeof *tzhp]; + } u; + int ttisstdcnt; + int ttisgmtcnt; + + i = read(fid, u.buf, sizeof u.buf); + if (close(fid) != 0) + return -1; + ttisstdcnt = (int) detzcode(u.tzhead.tzh_ttisstdcnt); + ttisgmtcnt = (int) detzcode(u.tzhead.tzh_ttisgmtcnt); + sp->leapcnt = (int) detzcode(u.tzhead.tzh_leapcnt); + sp->timecnt = (int) detzcode(u.tzhead.tzh_timecnt); + sp->typecnt = (int) detzcode(u.tzhead.tzh_typecnt); + sp->charcnt = (int) detzcode(u.tzhead.tzh_charcnt); + p = u.tzhead.tzh_charcnt + sizeof u.tzhead.tzh_charcnt; + if (sp->leapcnt < 0 || sp->leapcnt > TZ_MAX_LEAPS || + sp->typecnt <= 0 || sp->typecnt > TZ_MAX_TYPES || + sp->timecnt < 0 || sp->timecnt > TZ_MAX_TIMES || + sp->charcnt < 0 || sp->charcnt > TZ_MAX_CHARS || + (ttisstdcnt != sp->typecnt && ttisstdcnt != 0) || + (ttisgmtcnt != sp->typecnt && ttisgmtcnt != 0)) + return -1; + if (i - (p - u.buf) < sp->timecnt * 4 + /* ats */ + sp->timecnt + /* types */ + sp->typecnt * (4 + 2) + /* ttinfos */ + sp->charcnt + /* chars */ + sp->leapcnt * (4 + 4) + /* lsinfos */ + ttisstdcnt + /* ttisstds */ + ttisgmtcnt) /* ttisgmts */ + return -1; + for (i = 0; i < sp->timecnt; ++i) { + sp->ats[i] = detzcode(p); + p += 4; + } + for (i = 0; i < sp->timecnt; ++i) { + sp->types[i] = (unsigned char) *p++; + if (sp->types[i] >= sp->typecnt) + return -1; + } + for (i = 0; i < sp->typecnt; ++i) { + register struct ttinfo * ttisp; + + ttisp = &sp->ttis[i]; + ttisp->tt_gmtoff = detzcode(p); + p += 4; + ttisp->tt_isdst = (unsigned char) *p++; + if (ttisp->tt_isdst != 0 && ttisp->tt_isdst != 1) + return -1; + ttisp->tt_abbrind = (unsigned char) *p++; + if (ttisp->tt_abbrind < 0 || + ttisp->tt_abbrind > sp->charcnt) + return -1; + } + for (i = 0; i < sp->charcnt; ++i) + sp->chars[i] = *p++; + sp->chars[i] = '\0'; /* ensure '\0' at end */ + for (i = 0; i < sp->leapcnt; ++i) { + register struct lsinfo * lsisp; + + lsisp = &sp->lsis[i]; + lsisp->ls_trans = detzcode(p); + p += 4; + lsisp->ls_corr = detzcode(p); + p += 4; + } + for (i = 0; i < sp->typecnt; ++i) { + register struct ttinfo * ttisp; + + ttisp = &sp->ttis[i]; + if (ttisstdcnt == 0) + ttisp->tt_ttisstd = FALSE; + else { + ttisp->tt_ttisstd = *p++; + if (ttisp->tt_ttisstd != TRUE && + ttisp->tt_ttisstd != FALSE) + return -1; + } + } + for (i = 0; i < sp->typecnt; ++i) { + register struct ttinfo * ttisp; + + ttisp = &sp->ttis[i]; + if (ttisgmtcnt == 0) + ttisp->tt_ttisgmt = FALSE; + else { + ttisp->tt_ttisgmt = *p++; + if (ttisp->tt_ttisgmt != TRUE && + ttisp->tt_ttisgmt != FALSE) + return -1; + } + } + } + return 0; +} + +static const int mon_lengths[2][MONSPERYEAR] = { + { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }, + { 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 } +}; + +static const int year_lengths[2] = { + DAYSPERNYEAR, DAYSPERLYEAR +}; + +/* +** Given a pointer into a time zone string, scan until a character that is not +** a valid character in a zone name is found. Return a pointer to that +** character. +*/ + +static const char * +getzname(strp) +register const char * strp; +{ + register char c; + + while ((c = *strp) != '\0' && !is_digit(c) && c != ',' && c != '-' && + c != '+') + ++strp; + return strp; +} + +/* +** Given a pointer into a time zone string, extract a number from that string. +** Check that the number is within a specified range; if it is not, return +** NULL. +** Otherwise, return a pointer to the first character not part of the number. +*/ + +static const char * +getnum(strp, nump, min, max) +register const char * strp; +int * const nump; +const int min; +const int max; +{ + register char c; + register int num; + + if (strp == NULL || !is_digit(c = *strp)) + return NULL; + num = 0; + do { + num = num * 10 + (c - '0'); + if (num > max) + return NULL; /* illegal value */ + c = *++strp; + } while (is_digit(c)); + if (num < min) + return NULL; /* illegal value */ + *nump = num; + return strp; +} + +/* +** Given a pointer into a time zone string, extract a number of seconds, +** in hh[:mm[:ss]] form, from the string. +** If any error occurs, return NULL. +** Otherwise, return a pointer to the first character not part of the number +** of seconds. +*/ + +static const char * +getsecs(strp, secsp) +register const char * strp; +long * const secsp; +{ + int num; + + /* + ** `HOURSPERDAY * DAYSPERWEEK - 1' allows quasi-Posix rules like + ** "M10.4.6/26", which does not conform to Posix, + ** but which specifies the equivalent of + ** ``02:00 on the first Sunday on or after 23 Oct''. + */ + strp = getnum(strp, &num, 0, HOURSPERDAY * DAYSPERWEEK - 1); + if (strp == NULL) + return NULL; + *secsp = num * (long) SECSPERHOUR; + if (*strp == ':') { + ++strp; + strp = getnum(strp, &num, 0, MINSPERHOUR - 1); + if (strp == NULL) + return NULL; + *secsp += num * SECSPERMIN; + if (*strp == ':') { + ++strp; + /* `SECSPERMIN' allows for leap seconds. */ + strp = getnum(strp, &num, 0, SECSPERMIN); + if (strp == NULL) + return NULL; + *secsp += num; + } + } + return strp; +} + +/* +** Given a pointer into a time zone string, extract an offset, in +** [+-]hh[:mm[:ss]] form, from the string. +** If any error occurs, return NULL. +** Otherwise, return a pointer to the first character not part of the time. +*/ + +static const char * +getoffset(strp, offsetp) +register const char * strp; +long * const offsetp; +{ + register int neg = 0; + + if (*strp == '-') { + neg = 1; + ++strp; + } else if (*strp == '+') + ++strp; + strp = getsecs(strp, offsetp); + if (strp == NULL) + return NULL; /* illegal time */ + if (neg) + *offsetp = -*offsetp; + return strp; +} + +/* +** Given a pointer into a time zone string, extract a rule in the form +** date[/time]. See POSIX section 8 for the format of "date" and "time". +** If a valid rule is not found, return NULL. +** Otherwise, return a pointer to the first character not part of the rule. +*/ + +static const char * +getrule(strp, rulep) +const char * strp; +register struct rule * const rulep; +{ + if (*strp == 'J') { + /* + ** Julian day. + */ + rulep->r_type = JULIAN_DAY; + ++strp; + strp = getnum(strp, &rulep->r_day, 1, DAYSPERNYEAR); + } else if (*strp == 'M') { + /* + ** Month, week, day. + */ + rulep->r_type = MONTH_NTH_DAY_OF_WEEK; + ++strp; + strp = getnum(strp, &rulep->r_mon, 1, MONSPERYEAR); + if (strp == NULL) + return NULL; + if (*strp++ != '.') + return NULL; + strp = getnum(strp, &rulep->r_week, 1, 5); + if (strp == NULL) + return NULL; + if (*strp++ != '.') + return NULL; + strp = getnum(strp, &rulep->r_day, 0, DAYSPERWEEK - 1); + } else if (is_digit(*strp)) { + /* + ** Day of year. + */ + rulep->r_type = DAY_OF_YEAR; + strp = getnum(strp, &rulep->r_day, 0, DAYSPERLYEAR - 1); + } else return NULL; /* invalid format */ + if (strp == NULL) + return NULL; + if (*strp == '/') { + /* + ** Time specified. + */ + ++strp; + strp = getsecs(strp, &rulep->r_time); + } else rulep->r_time = 2 * SECSPERHOUR; /* default = 2:00:00 */ + return strp; +} + +/* +** Given the Epoch-relative time of January 1, 00:00:00 UTC, in a year, the +** year, a rule, and the offset from UTC at the time that rule takes effect, +** calculate the Epoch-relative time that rule takes effect. +*/ + +static time_t +transtime(janfirst, year, rulep, offset) +const time_t janfirst; +const int year; +register const struct rule * const rulep; +const long offset; +{ + register int leapyear; + register time_t value; + register int i; + int d, m1, yy0, yy1, yy2, dow; + + INITIALIZE(value); + leapyear = isleap(year); + switch (rulep->r_type) { + + case JULIAN_DAY: + /* + ** Jn - Julian day, 1 == January 1, 60 == March 1 even in leap + ** years. + ** In non-leap years, or if the day number is 59 or less, just + ** add SECSPERDAY times the day number-1 to the time of + ** January 1, midnight, to get the day. + */ + value = janfirst + (rulep->r_day - 1) * SECSPERDAY; + if (leapyear && rulep->r_day >= 60) + value += SECSPERDAY; + break; + + case DAY_OF_YEAR: + /* + ** n - day of year. + ** Just add SECSPERDAY times the day number to the time of + ** January 1, midnight, to get the day. + */ + value = janfirst + rulep->r_day * SECSPERDAY; + break; + + case MONTH_NTH_DAY_OF_WEEK: + /* + ** Mm.n.d - nth "dth day" of month m. + */ + value = janfirst; + for (i = 0; i < rulep->r_mon - 1; ++i) + value += mon_lengths[leapyear][i] * SECSPERDAY; + + /* + ** Use Zeller's Congruence to get day-of-week of first day of + ** month. + */ + m1 = (rulep->r_mon + 9) % 12 + 1; + yy0 = (rulep->r_mon <= 2) ? (year - 1) : year; + yy1 = yy0 / 100; + yy2 = yy0 % 100; + dow = ((26 * m1 - 2) / 10 + + 1 + yy2 + yy2 / 4 + yy1 / 4 - 2 * yy1) % 7; + if (dow < 0) + dow += DAYSPERWEEK; + + /* + ** "dow" is the day-of-week of the first day of the month. Get + ** the day-of-month (zero-origin) of the first "dow" day of the + ** month. + */ + d = rulep->r_day - dow; + if (d < 0) + d += DAYSPERWEEK; + for (i = 1; i < rulep->r_week; ++i) { + if (d + DAYSPERWEEK >= + mon_lengths[leapyear][rulep->r_mon - 1]) + break; + d += DAYSPERWEEK; + } + + /* + ** "d" is the day-of-month (zero-origin) of the day we want. + */ + value += d * SECSPERDAY; + break; + } + + /* + ** "value" is the Epoch-relative time of 00:00:00 UTC on the day in + ** question. To get the Epoch-relative time of the specified local + ** time on that day, add the transition time and the current offset + ** from UTC. + */ + return value + rulep->r_time + offset; +} + +/* +** Given a POSIX section 8-style TZ string, fill in the rule tables as +** appropriate. +*/ + +static int +tzparse(name, sp, lastditch) +const char * name; +register struct state * const sp; +const int lastditch; +{ + const char * stdname; + const char * dstname; + size_t stdlen; + size_t dstlen; + long stdoffset; + long dstoffset; + register time_t * atp; + register unsigned char * typep; + register char * cp; + register int load_result; + + INITIALIZE(dstname); + stdname = name; + if (lastditch) { + stdlen = strlen(name); /* length of standard zone name */ + name += stdlen; + if (stdlen >= sizeof sp->chars) + stdlen = (sizeof sp->chars) - 1; + stdoffset = 0; + } else { + name = getzname(name); + stdlen = name - stdname; + if (stdlen < 3) + return -1; + if (*name == '\0') + return -1; + name = getoffset(name, &stdoffset); + if (name == NULL) + return -1; + } + load_result = tzload(TZDEFRULES, sp); + if (load_result != 0) + sp->leapcnt = 0; /* so, we're off a little */ + if (*name != '\0') { + dstname = name; + name = getzname(name); + dstlen = name - dstname; /* length of DST zone name */ + if (dstlen < 3) + return -1; + if (*name != '\0' && *name != ',' && *name != ';') { + name = getoffset(name, &dstoffset); + if (name == NULL) + return -1; + } else dstoffset = stdoffset - SECSPERHOUR; + if (*name == '\0' && load_result != 0) + name = TZDEFRULESTRING; + if (*name == ',' || *name == ';') { + struct rule start; + struct rule end; + register int year; + register time_t janfirst; + time_t starttime; + time_t endtime; + + ++name; + if ((name = getrule(name, &start)) == NULL) + return -1; + if (*name++ != ',') + return -1; + if ((name = getrule(name, &end)) == NULL) + return -1; + if (*name != '\0') + return -1; + sp->typecnt = 2; /* standard time and DST */ + /* + ** Two transitions per year, from EPOCH_YEAR to 2037. + */ + sp->timecnt = 2 * (2037 - EPOCH_YEAR + 1); + if (sp->timecnt > TZ_MAX_TIMES) + return -1; + sp->ttis[0].tt_gmtoff = -dstoffset; + sp->ttis[0].tt_isdst = 1; + sp->ttis[0].tt_abbrind = stdlen + 1; + sp->ttis[1].tt_gmtoff = -stdoffset; + sp->ttis[1].tt_isdst = 0; + sp->ttis[1].tt_abbrind = 0; + atp = sp->ats; + typep = sp->types; + janfirst = 0; + for (year = EPOCH_YEAR; year <= 2037; ++year) { + starttime = transtime(janfirst, year, &start, + stdoffset); + endtime = transtime(janfirst, year, &end, + dstoffset); + if (starttime > endtime) { + *atp++ = endtime; + *typep++ = 1; /* DST ends */ + *atp++ = starttime; + *typep++ = 0; /* DST begins */ + } else { + *atp++ = starttime; + *typep++ = 0; /* DST begins */ + *atp++ = endtime; + *typep++ = 1; /* DST ends */ + } + janfirst += year_lengths[isleap(year)] * + SECSPERDAY; + } + } else { + register long theirstdoffset; + register long theirdstoffset; + register long theiroffset; + register int isdst; + register int i; + register int j; + + if (*name != '\0') + return -1; + /* + ** Initial values of theirstdoffset and theirdstoffset. + */ + theirstdoffset = 0; + for (i = 0; i < sp->timecnt; ++i) { + j = sp->types[i]; + if (!sp->ttis[j].tt_isdst) { + theirstdoffset = + -sp->ttis[j].tt_gmtoff; + break; + } + } + theirdstoffset = 0; + for (i = 0; i < sp->timecnt; ++i) { + j = sp->types[i]; + if (sp->ttis[j].tt_isdst) { + theirdstoffset = + -sp->ttis[j].tt_gmtoff; + break; + } + } + /* + ** Initially we're assumed to be in standard time. + */ + isdst = FALSE; + theiroffset = theirstdoffset; + /* + ** Now juggle transition times and types + ** tracking offsets as you do. + */ + for (i = 0; i < sp->timecnt; ++i) { + j = sp->types[i]; + sp->types[i] = sp->ttis[j].tt_isdst; + if (sp->ttis[j].tt_ttisgmt) { + /* No adjustment to transition time */ + } else { + /* + ** If summer time is in effect, and the + ** transition time was not specified as + ** standard time, add the summer time + ** offset to the transition time; + ** otherwise, add the standard time + ** offset to the transition time. + */ + /* + ** Transitions from DST to DDST + ** will effectively disappear since + ** POSIX provides for only one DST + ** offset. + */ + if (isdst && !sp->ttis[j].tt_ttisstd) { + sp->ats[i] += dstoffset - + theirdstoffset; + } else { + sp->ats[i] += stdoffset - + theirstdoffset; + } + } + theiroffset = -sp->ttis[j].tt_gmtoff; + if (sp->ttis[j].tt_isdst) + theirdstoffset = theiroffset; + else theirstdoffset = theiroffset; + } + /* + ** Finally, fill in ttis. + ** ttisstd and ttisgmt need not be handled. + */ + sp->ttis[0].tt_gmtoff = -stdoffset; + sp->ttis[0].tt_isdst = FALSE; + sp->ttis[0].tt_abbrind = 0; + sp->ttis[1].tt_gmtoff = -dstoffset; + sp->ttis[1].tt_isdst = TRUE; + sp->ttis[1].tt_abbrind = stdlen + 1; + sp->typecnt = 2; + } + } else { + dstlen = 0; + sp->typecnt = 1; /* only standard time */ + sp->timecnt = 0; + sp->ttis[0].tt_gmtoff = -stdoffset; + sp->ttis[0].tt_isdst = 0; + sp->ttis[0].tt_abbrind = 0; + } + sp->charcnt = stdlen + 1; + if (dstlen != 0) + sp->charcnt += dstlen + 1; + if ((size_t) sp->charcnt > sizeof sp->chars) + return -1; + cp = sp->chars; + (void) strncpy(cp, stdname, stdlen); + cp += stdlen; + *cp++ = '\0'; + if (dstlen != 0) { + (void) strncpy(cp, dstname, dstlen); + *(cp + dstlen) = '\0'; + } + return 0; +} + +static void +gmtload(sp) +struct state * const sp; +{ + if (tzload(gmt, sp) != 0) + (void) tzparse(gmt, sp, TRUE); +} + +#ifndef STD_INSPIRED +/* +** A non-static declaration of tzsetwall in a system header file +** may cause a warning about this upcoming static declaration... +*/ +static +#endif /* !defined STD_INSPIRED */ +void +tzsetwall P((void)) +{ + if (lcl_is_set < 0) + return; + lcl_is_set = -1; + +#ifdef ALL_STATE + if (lclptr == NULL) { + lclptr = (struct state *) malloc(sizeof *lclptr); + if (lclptr == NULL) { + settzname(); /* all we can do */ + return; + } + } +#endif /* defined ALL_STATE */ + if (tzload((char *) NULL, lclptr) != 0) + gmtload(lclptr); + settzname(); +} + +void +tzset P((void)) +{ + register const char * name; + + name = getenv("TZ"); + if (name == NULL) { + tzsetwall(); + return; + } + + if (lcl_is_set > 0 && strcmp(lcl_TZname, name) == 0) + return; + lcl_is_set = strlen(name) < sizeof lcl_TZname; + if (lcl_is_set) + (void) strcpy(lcl_TZname, name); + +#ifdef ALL_STATE + if (lclptr == NULL) { + lclptr = (struct state *) malloc(sizeof *lclptr); + if (lclptr == NULL) { + settzname(); /* all we can do */ + return; + } + } +#endif /* defined ALL_STATE */ + if (*name == '\0') { + /* + ** User wants it fast rather than right. + */ + lclptr->leapcnt = 0; /* so, we're off a little */ + lclptr->timecnt = 0; + lclptr->typecnt = 0; + lclptr->ttis[0].tt_isdst = 0; + lclptr->ttis[0].tt_gmtoff = 0; + lclptr->ttis[0].tt_abbrind = 0; + (void) strcpy(lclptr->chars, gmt); + } else if (tzload(name, lclptr) != 0) + if (name[0] == ':' || tzparse(name, lclptr, FALSE) != 0) + (void) gmtload(lclptr); + settzname(); +} + +/* +** The easy way to behave "as if no library function calls" localtime +** is to not call it--so we drop its guts into "localsub", which can be +** freely called. (And no, the PANS doesn't require the above behavior-- +** but it *is* desirable.) +** +** The unused offset argument is for the benefit of mktime variants. +*/ + +/*ARGSUSED*/ +static void +localsub(timep, offset, tmp) +const time_t * const timep; +const long offset; +struct tm * const tmp; +{ + register struct state * sp; + register const struct ttinfo * ttisp; + register int i; + const time_t t = *timep; + + sp = lclptr; +#ifdef ALL_STATE + if (sp == NULL) { + gmtsub(timep, offset, tmp); + return; + } +#endif /* defined ALL_STATE */ + if (sp->timecnt == 0 || t < sp->ats[0]) { + i = 0; + while (sp->ttis[i].tt_isdst) + if (++i >= sp->typecnt) { + i = 0; + break; + } + } else { + for (i = 1; i < sp->timecnt; ++i) + if (t < sp->ats[i]) + break; + i = sp->types[i - 1]; + } + ttisp = &sp->ttis[i]; + /* + ** To get (wrong) behavior that's compatible with System V Release 2.0 + ** you'd replace the statement below with + ** t += ttisp->tt_gmtoff; + ** timesub(&t, 0L, sp, tmp); + */ + timesub(&t, ttisp->tt_gmtoff, sp, tmp); + tmp->tm_isdst = ttisp->tt_isdst; + tzname[tmp->tm_isdst] = &sp->chars[ttisp->tt_abbrind]; +#ifdef TM_ZONE + tmp->TM_ZONE = &sp->chars[ttisp->tt_abbrind]; +#endif /* defined TM_ZONE */ +} + +struct tm * +localtime(timep) +const time_t * const timep; +{ + tzset(); + localsub(timep, 0L, &tm); + return &tm; +} + +/* +** Re-entrant version of localtime. +*/ + +struct tm * +localtime_r(timep, tm) +const time_t * const timep; +struct tm * tm; +{ + localsub(timep, 0L, tm); + return tm; +} + +/* +** gmtsub is to gmtime as localsub is to localtime. +*/ + +static void +gmtsub(timep, offset, tmp) +const time_t * const timep; +const long offset; +struct tm * const tmp; +{ + if (!gmt_is_set) { + gmt_is_set = TRUE; +#ifdef ALL_STATE + gmtptr = (struct state *) malloc(sizeof *gmtptr); + if (gmtptr != NULL) +#endif /* defined ALL_STATE */ + gmtload(gmtptr); + } + timesub(timep, offset, gmtptr, tmp); +#ifdef TM_ZONE + /* + ** Could get fancy here and deliver something such as + ** "UTC+xxxx" or "UTC-xxxx" if offset is non-zero, + ** but this is no time for a treasure hunt. + */ + if (offset != 0) + tmp->TM_ZONE = wildabbr; + else { +#ifdef ALL_STATE + if (gmtptr == NULL) + tmp->TM_ZONE = gmt; + else tmp->TM_ZONE = gmtptr->chars; +#endif /* defined ALL_STATE */ +#ifndef ALL_STATE + tmp->TM_ZONE = gmtptr->chars; +#endif /* State Farm */ + } +#endif /* defined TM_ZONE */ +} + +struct tm * +gmtime(timep) +const time_t * const timep; +{ + gmtsub(timep, 0L, &tm); + return &tm; +} + +/* +* Re-entrant version of gmtime. +*/ + +struct tm * +gmtime_r(timep, tm) +const time_t * const timep; +struct tm * tm; +{ + gmtsub(timep, 0L, tm); + return tm; +} + +#ifdef STD_INSPIRED + +struct tm * +offtime(timep, offset) +const time_t * const timep; +const long offset; +{ + gmtsub(timep, offset, &tm); + return &tm; +} + +#endif /* defined STD_INSPIRED */ + +static void +timesub(timep, offset, sp, tmp) +const time_t * const timep; +const long offset; +register const struct state * const sp; +register struct tm * const tmp; +{ + register const struct lsinfo * lp; + register long days; + register long rem; + register int y; + register int yleap; + register const int * ip; + register long corr; + register int hit; + register int i; + + corr = 0; + hit = 0; +#ifdef ALL_STATE + i = (sp == NULL) ? 0 : sp->leapcnt; +#endif /* defined ALL_STATE */ +#ifndef ALL_STATE + i = sp->leapcnt; +#endif /* State Farm */ + while (--i >= 0) { + lp = &sp->lsis[i]; + if (*timep >= lp->ls_trans) { + if (*timep == lp->ls_trans) { + hit = ((i == 0 && lp->ls_corr > 0) || + lp->ls_corr > sp->lsis[i - 1].ls_corr); + if (hit) + while (i > 0 && + sp->lsis[i].ls_trans == + sp->lsis[i - 1].ls_trans + 1 && + sp->lsis[i].ls_corr == + sp->lsis[i - 1].ls_corr + 1) { + ++hit; + --i; + } + } + corr = lp->ls_corr; + break; + } + } + days = *timep / SECSPERDAY; + rem = *timep % SECSPERDAY; +#ifdef mc68k + if (*timep == 0x80000000) { + /* + ** A 3B1 muffs the division on the most negative number. + */ + days = -24855; + rem = -11648; + } +#endif /* defined mc68k */ + rem += (offset - corr); + while (rem < 0) { + rem += SECSPERDAY; + --days; + } + while (rem >= SECSPERDAY) { + rem -= SECSPERDAY; + ++days; + } + tmp->tm_hour = (int) (rem / SECSPERHOUR); + rem = rem % SECSPERHOUR; + tmp->tm_min = (int) (rem / SECSPERMIN); + /* + ** A positive leap second requires a special + ** representation. This uses "... ??:59:60" et seq. + */ + tmp->tm_sec = (int) (rem % SECSPERMIN) + hit; + tmp->tm_wday = (int) ((EPOCH_WDAY + days) % DAYSPERWEEK); + if (tmp->tm_wday < 0) + tmp->tm_wday += DAYSPERWEEK; + y = EPOCH_YEAR; +#define LEAPS_THRU_END_OF(y) ((y) / 4 - (y) / 100 + (y) / 400) + while (days < 0 || days >= (long) year_lengths[yleap = isleap(y)]) { + register int newy; + + newy = y + days / DAYSPERNYEAR; + if (days < 0) + --newy; + days -= (newy - y) * DAYSPERNYEAR + + LEAPS_THRU_END_OF(newy - 1) - + LEAPS_THRU_END_OF(y - 1); + y = newy; + } + tmp->tm_year = y - TM_YEAR_BASE; + tmp->tm_yday = (int) days; + ip = mon_lengths[yleap]; + for (tmp->tm_mon = 0; days >= (long) ip[tmp->tm_mon]; ++(tmp->tm_mon)) + days = days - (long) ip[tmp->tm_mon]; + tmp->tm_mday = (int) (days + 1); + tmp->tm_isdst = 0; +#ifdef TM_GMTOFF + tmp->TM_GMTOFF = offset; +#endif /* defined TM_GMTOFF */ +} + +char * +ctime(timep) +const time_t * const timep; +{ +/* +** Section 4.12.3.2 of X3.159-1989 requires that +** The ctime function converts the calendar time pointed to by timer +** to local time in the form of a string. It is equivalent to +** asctime(localtime(timer)) +*/ + return asctime(localtime(timep)); +} + +char * +ctime_r(timep, buf) +const time_t * const timep; +char * buf; +{ + struct tm tm; + + return asctime_r(localtime_r(timep, &tm), buf); +} + +/* +** Adapted from code provided by Robert Elz, who writes: +** The "best" way to do mktime I think is based on an idea of Bob +** Kridle's (so its said...) from a long time ago. +** [kridle@xinet.com as of 1996-01-16.] +** It does a binary search of the time_t space. Since time_t's are +** just 32 bits, its a max of 32 iterations (even at 64 bits it +** would still be very reasonable). +*/ + +#ifndef WRONG +#define WRONG (-1) +#endif /* !defined WRONG */ + +/* +** Simplified normalize logic courtesy Paul Eggert (eggert@twinsun.com). +*/ + +static int +increment_overflow(number, delta) +int * number; +int delta; +{ + int number0; + + number0 = *number; + *number += delta; + return (*number < number0) != (delta < 0); +} + +static int +normalize_overflow(tensptr, unitsptr, base) +int * const tensptr; +int * const unitsptr; +const int base; +{ + register int tensdelta; + + tensdelta = (*unitsptr >= 0) ? + (*unitsptr / base) : + (-1 - (-1 - *unitsptr) / base); + *unitsptr -= tensdelta * base; + return increment_overflow(tensptr, tensdelta); +} + +static int +tmcomp(atmp, btmp) +register const struct tm * const atmp; +register const struct tm * const btmp; +{ + register int result; + + if ((result = (atmp->tm_year - btmp->tm_year)) == 0 && + (result = (atmp->tm_mon - btmp->tm_mon)) == 0 && + (result = (atmp->tm_mday - btmp->tm_mday)) == 0 && + (result = (atmp->tm_hour - btmp->tm_hour)) == 0 && + (result = (atmp->tm_min - btmp->tm_min)) == 0) + result = atmp->tm_sec - btmp->tm_sec; + return result; +} + +static time_t +time2sub(tmp, funcp, offset, okayp, do_norm_secs) +struct tm * const tmp; +void (* const funcp) P((const time_t*, long, struct tm*)); +const long offset; +int * const okayp; +const int do_norm_secs; +{ + register const struct state * sp; + register int dir; + register int bits; + register int i, j ; + register int saved_seconds; + time_t newt; + time_t t; + struct tm yourtm, mytm; + + *okayp = FALSE; + yourtm = *tmp; + if (do_norm_secs) { + if (normalize_overflow(&yourtm.tm_min, &yourtm.tm_sec, + SECSPERMIN)) + return WRONG; + } + if (normalize_overflow(&yourtm.tm_hour, &yourtm.tm_min, MINSPERHOUR)) + return WRONG; + if (normalize_overflow(&yourtm.tm_mday, &yourtm.tm_hour, HOURSPERDAY)) + return WRONG; + if (normalize_overflow(&yourtm.tm_year, &yourtm.tm_mon, MONSPERYEAR)) + return WRONG; + /* + ** Turn yourtm.tm_year into an actual year number for now. + ** It is converted back to an offset from TM_YEAR_BASE later. + */ + if (increment_overflow(&yourtm.tm_year, TM_YEAR_BASE)) + return WRONG; + while (yourtm.tm_mday <= 0) { + if (increment_overflow(&yourtm.tm_year, -1)) + return WRONG; + i = yourtm.tm_year + (1 < yourtm.tm_mon); + yourtm.tm_mday += year_lengths[isleap(i)]; + } + while (yourtm.tm_mday > DAYSPERLYEAR) { + i = yourtm.tm_year + (1 < yourtm.tm_mon); + yourtm.tm_mday -= year_lengths[isleap(i)]; + if (increment_overflow(&yourtm.tm_year, 1)) + return WRONG; + } + for ( ; ; ) { + i = mon_lengths[isleap(yourtm.tm_year)][yourtm.tm_mon]; + if (yourtm.tm_mday <= i) + break; + yourtm.tm_mday -= i; + if (++yourtm.tm_mon >= MONSPERYEAR) { + yourtm.tm_mon = 0; + if (increment_overflow(&yourtm.tm_year, 1)) + return WRONG; + } + } + if (increment_overflow(&yourtm.tm_year, -TM_YEAR_BASE)) + return WRONG; + if (yourtm.tm_sec >= 0 && yourtm.tm_sec < SECSPERMIN) + saved_seconds = 0; + else if (yourtm.tm_year + TM_YEAR_BASE < EPOCH_YEAR) { + /* + ** We can't set tm_sec to 0, because that might push the + ** time below the minimum representable time. + ** Set tm_sec to 59 instead. + ** This assumes that the minimum representable time is + ** not in the same minute that a leap second was deleted from, + ** which is a safer assumption than using 58 would be. + */ + if (increment_overflow(&yourtm.tm_sec, 1 - SECSPERMIN)) + return WRONG; + saved_seconds = yourtm.tm_sec; + yourtm.tm_sec = SECSPERMIN - 1; + } else { + saved_seconds = yourtm.tm_sec; + yourtm.tm_sec = 0; + } + /* + ** Divide the search space in half + ** (this works whether time_t is signed or unsigned). + */ + bits = TYPE_BIT(time_t) - 1; + /* + ** If time_t is signed, then 0 is just above the median, + ** assuming two's complement arithmetic. + ** If time_t is unsigned, then (1 << bits) is just above the median. + */ + t = TYPE_SIGNED(time_t) ? 0 : (((time_t) 1) << bits); + for ( ; ; ) { + (*funcp)(&t, offset, &mytm); + dir = tmcomp(&mytm, &yourtm); + if (dir != 0) { + if (bits-- < 0) + return WRONG; + if (bits < 0) + --t; /* may be needed if new t is minimal */ + else if (dir > 0) + t -= ((time_t) 1) << bits; + else t += ((time_t) 1) << bits; + continue; + } + if (yourtm.tm_isdst < 0 || mytm.tm_isdst == yourtm.tm_isdst) + break; + /* + ** Right time, wrong type. + ** Hunt for right time, right type. + ** It's okay to guess wrong since the guess + ** gets checked. + */ + /* + ** The (void *) casts are the benefit of SunOS 3.3 on Sun 2's. + */ + sp = (const struct state *) + (((void *) funcp == (void *) localsub) ? + lclptr : gmtptr); +#ifdef ALL_STATE + if (sp == NULL) + return WRONG; +#endif /* defined ALL_STATE */ + for (i = sp->typecnt - 1; i >= 0; --i) { + if (sp->ttis[i].tt_isdst != yourtm.tm_isdst) + continue; + for (j = sp->typecnt - 1; j >= 0; --j) { + if (sp->ttis[j].tt_isdst == yourtm.tm_isdst) + continue; + newt = t + sp->ttis[j].tt_gmtoff - + sp->ttis[i].tt_gmtoff; + (*funcp)(&newt, offset, &mytm); + if (tmcomp(&mytm, &yourtm) != 0) + continue; + if (mytm.tm_isdst != yourtm.tm_isdst) + continue; + /* + ** We have a match. + */ + t = newt; + goto label; + } + } + return WRONG; + } +label: + newt = t + saved_seconds; + if ((newt < t) != (saved_seconds < 0)) + return WRONG; + t = newt; + (*funcp)(&t, offset, tmp); + *okayp = TRUE; + return t; +} + +static time_t +time2(tmp, funcp, offset, okayp) +struct tm * const tmp; +void (* const funcp) P((const time_t*, long, struct tm*)); +const long offset; +int * const okayp; +{ + time_t t; + + /* + ** First try without normalization of seconds + ** (in case tm_sec contains a value associated with a leap second). + ** If that fails, try with normalization of seconds. + */ + t = time2sub(tmp, funcp, offset, okayp, FALSE); + return *okayp ? t : time2sub(tmp, funcp, offset, okayp, TRUE); +} + +static time_t +time1(tmp, funcp, offset) +struct tm * const tmp; +void (* const funcp) P((const time_t *, long, struct tm *)); +const long offset; +{ + register time_t t; + register const struct state * sp; + register int samei, otheri; + register int sameind, otherind; + register int i; + register int nseen; + int seen[TZ_MAX_TYPES]; + int types[TZ_MAX_TYPES]; + int okay; + + if (tmp->tm_isdst > 1) + tmp->tm_isdst = 1; + t = time2(tmp, funcp, offset, &okay); +#ifdef PCTS + /* + ** PCTS code courtesy Grant Sullivan (grant@osf.org). + */ + if (okay) + return t; + if (tmp->tm_isdst < 0) + tmp->tm_isdst = 0; /* reset to std and try again */ +#endif /* defined PCTS */ +#ifndef PCTS + if (okay || tmp->tm_isdst < 0) + return t; +#endif /* !defined PCTS */ + /* + ** We're supposed to assume that somebody took a time of one type + ** and did some math on it that yielded a "struct tm" that's bad. + ** We try to divine the type they started from and adjust to the + ** type they need. + */ + /* + ** The (void *) casts are the benefit of SunOS 3.3 on Sun 2's. + */ + sp = (const struct state *) (((void *) funcp == (void *) localsub) ? + lclptr : gmtptr); +#ifdef ALL_STATE + if (sp == NULL) + return WRONG; +#endif /* defined ALL_STATE */ + for (i = 0; i < sp->typecnt; ++i) + seen[i] = FALSE; + nseen = 0; + for (i = sp->timecnt - 1; i >= 0; --i) + if (!seen[sp->types[i]]) { + seen[sp->types[i]] = TRUE; + types[nseen++] = sp->types[i]; + } + for (sameind = 0; sameind < nseen; ++sameind) { + samei = types[sameind]; + if (sp->ttis[samei].tt_isdst != tmp->tm_isdst) + continue; + for (otherind = 0; otherind < nseen; ++otherind) { + otheri = types[otherind]; + if (sp->ttis[otheri].tt_isdst == tmp->tm_isdst) + continue; + tmp->tm_sec += sp->ttis[otheri].tt_gmtoff - + sp->ttis[samei].tt_gmtoff; + tmp->tm_isdst = !tmp->tm_isdst; + t = time2(tmp, funcp, offset, &okay); + if (okay) + return t; + tmp->tm_sec -= sp->ttis[otheri].tt_gmtoff - + sp->ttis[samei].tt_gmtoff; + tmp->tm_isdst = !tmp->tm_isdst; + } + } + return WRONG; +} + +time_t +mktime(tmp) +struct tm * const tmp; +{ + tzset(); + return time1(tmp, localsub, 0L); +} + +#ifdef STD_INSPIRED + +time_t +timelocal(tmp) +struct tm * const tmp; +{ + tmp->tm_isdst = -1; /* in case it wasn't initialized */ + return mktime(tmp); +} + +time_t +timegm(tmp) +struct tm * const tmp; +{ + tmp->tm_isdst = 0; + return time1(tmp, gmtsub, 0L); +} + +time_t +timeoff(tmp, offset) +struct tm * const tmp; +const long offset; +{ + tmp->tm_isdst = 0; + return time1(tmp, gmtsub, offset); +} + +#endif /* defined STD_INSPIRED */ + +#ifdef CMUCS + +/* +** The following is supplied for compatibility with +** previous versions of the CMUCS runtime library. +*/ + +long +gtime(tmp) +struct tm * const tmp; +{ + const time_t t = mktime(tmp); + + if (t == WRONG) + return -1; + return t; +} + +#endif /* defined CMUCS */ + +/* +** XXX--is the below the right way to conditionalize?? +*/ + +#ifdef STD_INSPIRED + +/* +** IEEE Std 1003.1-1988 (POSIX) legislates that 536457599 +** shall correspond to "Wed Dec 31 23:59:59 UTC 1986", which +** is not the case if we are accounting for leap seconds. +** So, we provide the following conversion routines for use +** when exchanging timestamps with POSIX conforming systems. +*/ + +static long +leapcorr(timep) +time_t * timep; +{ + register struct state * sp; + register struct lsinfo * lp; + register int i; + + sp = lclptr; + i = sp->leapcnt; + while (--i >= 0) { + lp = &sp->lsis[i]; + if (*timep >= lp->ls_trans) + return lp->ls_corr; + } + return 0; +} + +time_t +time2posix(t) +time_t t; +{ + tzset(); + return t - leapcorr(&t); +} + +time_t +posix2time(t) +time_t t; +{ + time_t x; + time_t y; + + tzset(); + /* + ** For a positive leap second hit, the result + ** is not unique. For a negative leap second + ** hit, the corresponding time doesn't exist, + ** so we return an adjacent second. + */ + x = t + leapcorr(&t); + y = x - leapcorr(&x); + if (y < t) { + do { + x++; + y = x - leapcorr(&x); + } while (y < t); + if (t != y) + return x - 1; + } else if (y > t) { + do { + --x; + y = x - leapcorr(&x); + } while (y > t); + if (t != y) + return x + 1; + } + return x; +} + +#endif /* defined STD_INSPIRED */ diff --git a/src/timezone/pgtz.c b/src/timezone/pgtz.c new file mode 100644 index 0000000000..7bb789340b --- /dev/null +++ b/src/timezone/pgtz.c @@ -0,0 +1,42 @@ +/*------------------------------------------------------------------------- + * + * pgtz.c + * Timezone Library Integration Functions + * + * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group + * + * IDENTIFICATION + * $PostgreSQL: pgsql/src/timezone/pgtz.c,v 1.1 2004/04/30 04:09:23 momjian Exp $ + * + *------------------------------------------------------------------------- + */ + +#include "pgtz.h" +#include "tzfile.h" + + +#ifdef WIN32 +static char tzdir[MAXPGPATH]; +static int done_tzdir = 0; +char *pgwin32_TZDIR(void) { + char *p; + if (done_tzdir) + return tzdir; + + if (GetModuleFileName(NULL,tzdir,MAXPGPATH) == 0) + return NULL; + + canonicalize_path(tzdir); + if ((p = last_path_separator(tzdir)) == NULL) + return NULL; + else + *p = '\0'; + + strcat(tzdir,"/../share/timezone"); + + done_tzdir=1; + return tzdir; +} +#else +#error pgwin32_TZDIR not implemented on non win32 yet! +#endif diff --git a/src/timezone/pgtz.h b/src/timezone/pgtz.h new file mode 100644 index 0000000000..17df71cbec --- /dev/null +++ b/src/timezone/pgtz.h @@ -0,0 +1,8 @@ +#include "postgres.h" + +#define NOID +#define HAVE_SYMLINK 0 +#define HAVE_SYS_WAIT_H 0 +#define TZDIR pgwin32_TZDIR() + +char *pgwin32_TZDIR(void); diff --git a/src/timezone/private.h b/src/timezone/private.h new file mode 100644 index 0000000000..9333529bcc --- /dev/null +++ b/src/timezone/private.h @@ -0,0 +1,294 @@ +#ifndef PRIVATE_H + +#define PRIVATE_H + +/* +** This file is in the public domain, so clarified as of +** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). +*/ + +/* +** This header is for use ONLY with the time conversion code. +** There is no guarantee that it will remain unchanged, +** or that it will remain at all. +** Do NOT copy it to any system include directory. +** Thank you! +*/ + +/* +** ID +*/ + +#ifndef lint +#ifndef NOID +static char privatehid[] = "@(#)private.h 7.53"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/* +** Defaults for preprocessor symbols. +** You can override these in your C compiler options, e.g. `-DHAVE_ADJTIME=0'. +*/ + +#ifndef HAVE_ADJTIME +#define HAVE_ADJTIME 1 +#endif /* !defined HAVE_ADJTIME */ + +#ifndef HAVE_GETTEXT +#define HAVE_GETTEXT 0 +#endif /* !defined HAVE_GETTEXT */ + +#ifndef HAVE_INCOMPATIBLE_CTIME_R +#define HAVE_INCOMPATIBLE_CTIME_R 0 +#endif /* !defined INCOMPATIBLE_CTIME_R */ + +#ifndef HAVE_SETTIMEOFDAY +#define HAVE_SETTIMEOFDAY 3 +#endif /* !defined HAVE_SETTIMEOFDAY */ + +#ifndef HAVE_STRERROR +#define HAVE_STRERROR 1 +#endif /* !defined HAVE_STRERROR */ + +#ifndef HAVE_SYMLINK +#define HAVE_SYMLINK 1 +#endif /* !defined HAVE_SYMLINK */ + +#ifndef HAVE_SYS_STAT_H +#define HAVE_SYS_STAT_H 1 +#endif /* !defined HAVE_SYS_STAT_H */ + +#ifndef HAVE_SYS_WAIT_H +#define HAVE_SYS_WAIT_H 1 +#endif /* !defined HAVE_SYS_WAIT_H */ + +#ifndef HAVE_UNISTD_H +#define HAVE_UNISTD_H 1 +#endif /* !defined HAVE_UNISTD_H */ + +#ifndef HAVE_UTMPX_H +#define HAVE_UTMPX_H 0 +#endif /* !defined HAVE_UTMPX_H */ + +#ifndef LOCALE_HOME +#define LOCALE_HOME "/usr/lib/locale" +#endif /* !defined LOCALE_HOME */ + +#if HAVE_INCOMPATIBLE_CTIME_R +#define asctime_r _incompatible_asctime_r +#define ctime_r _incompatible_ctime_r +#endif /* HAVE_INCOMPATIBLE_CTIME_R */ + +/* +** Nested includes +*/ + +#include "sys/types.h" /* for time_t */ +#include "stdio.h" +#include "errno.h" +#include "string.h" +#include "limits.h" /* for CHAR_BIT */ +#include "time.h" +#include "stdlib.h" + +#if HAVE_GETTEXT - 0 +#include "libintl.h" +#endif /* HAVE_GETTEXT - 0 */ + +#if HAVE_SYS_WAIT_H - 0 +#include /* for WIFEXITED and WEXITSTATUS */ +#endif /* HAVE_SYS_WAIT_H - 0 */ + +#ifndef WIFEXITED +#define WIFEXITED(status) (((status) & 0xff) == 0) +#endif /* !defined WIFEXITED */ +#ifndef WEXITSTATUS +#define WEXITSTATUS(status) (((status) >> 8) & 0xff) +#endif /* !defined WEXITSTATUS */ + +#if HAVE_UNISTD_H - 0 +#include "unistd.h" /* for F_OK and R_OK */ +#endif /* HAVE_UNISTD_H - 0 */ + +#if !(HAVE_UNISTD_H - 0) +#ifndef F_OK +#define F_OK 0 +#endif /* !defined F_OK */ +#ifndef R_OK +#define R_OK 4 +#endif /* !defined R_OK */ +#endif /* !(HAVE_UNISTD_H - 0) */ + +/* Unlike 's isdigit, this also works if c < 0 | c > UCHAR_MAX. */ +#define is_digit(c) ((unsigned)(c) - '0' <= 9) + +/* +** Workarounds for compilers/systems. +*/ + +/* +** SunOS 4.1.1 cc lacks prototypes. +*/ + +#ifndef P +#ifdef __STDC__ +#define P(x) x +#endif /* defined __STDC__ */ +#ifndef __STDC__ +#define P(x) () +#endif /* !defined __STDC__ */ +#endif /* !defined P */ + +/* +** SunOS 4.1.1 headers lack EXIT_SUCCESS. +*/ + +#ifndef EXIT_SUCCESS +#define EXIT_SUCCESS 0 +#endif /* !defined EXIT_SUCCESS */ + +/* +** SunOS 4.1.1 headers lack EXIT_FAILURE. +*/ + +#ifndef EXIT_FAILURE +#define EXIT_FAILURE 1 +#endif /* !defined EXIT_FAILURE */ + +/* +** SunOS 4.1.1 headers lack FILENAME_MAX. +*/ + +#ifndef FILENAME_MAX + +#ifndef MAXPATHLEN +#ifdef unix +#include "sys/param.h" +#endif /* defined unix */ +#endif /* !defined MAXPATHLEN */ + +#ifdef MAXPATHLEN +#define FILENAME_MAX MAXPATHLEN +#endif /* defined MAXPATHLEN */ +#ifndef MAXPATHLEN +#define FILENAME_MAX 1024 /* Pure guesswork */ +#endif /* !defined MAXPATHLEN */ + +#endif /* !defined FILENAME_MAX */ + +/* +** SunOS 4.1.1 libraries lack remove. +*/ + +#ifndef remove +extern int unlink P((const char * filename)); +#define remove unlink +#endif /* !defined remove */ + +/* +** Some ancient errno.h implementations don't declare errno. +** But some newer errno.h implementations define it as a macro. +** Fix the former without affecting the latter. +*/ +#ifndef errno +extern int errno; +#endif /* !defined errno */ + +/* +** Private function declarations. +*/ +char * icalloc P((int nelem, int elsize)); +char * icatalloc P((char * old, const char * new)); +char * icpyalloc P((const char * string)); +char * imalloc P((int n)); +void * irealloc P((void * pointer, int size)); +void icfree P((char * pointer)); +void ifree P((char * pointer)); +char * scheck P((const char *string, const char *format)); + + +/* +** Finally, some convenience items. +*/ + +#ifndef TRUE +#define TRUE 1 +#endif /* !defined TRUE */ + +#ifndef FALSE +#define FALSE 0 +#endif /* !defined FALSE */ + +#ifndef TYPE_BIT +#define TYPE_BIT(type) (sizeof (type) * CHAR_BIT) +#endif /* !defined TYPE_BIT */ + +#ifndef TYPE_SIGNED +#define TYPE_SIGNED(type) (((type) -1) < 0) +#endif /* !defined TYPE_SIGNED */ + +#ifndef INT_STRLEN_MAXIMUM +/* +** 302 / 1000 is log10(2.0) rounded up. +** Subtract one for the sign bit if the type is signed; +** add one for integer division truncation; +** add one more for a minus sign if the type is signed. +*/ +#define INT_STRLEN_MAXIMUM(type) \ + ((TYPE_BIT(type) - TYPE_SIGNED(type)) * 302 / 1000 + 1 + TYPE_SIGNED(type)) +#endif /* !defined INT_STRLEN_MAXIMUM */ + +/* +** INITIALIZE(x) +*/ + +#ifndef GNUC_or_lint +#ifdef lint +#define GNUC_or_lint +#endif /* defined lint */ +#ifndef lint +#ifdef __GNUC__ +#define GNUC_or_lint +#endif /* defined __GNUC__ */ +#endif /* !defined lint */ +#endif /* !defined GNUC_or_lint */ + +#ifndef INITIALIZE +#ifdef GNUC_or_lint +#define INITIALIZE(x) ((x) = 0) +#endif /* defined GNUC_or_lint */ +#ifndef GNUC_or_lint +#define INITIALIZE(x) +#endif /* !defined GNUC_or_lint */ +#endif /* !defined INITIALIZE */ + +/* +** For the benefit of GNU folk... +** `_(MSGID)' uses the current locale's message library string for MSGID. +** The default is to use gettext if available, and use MSGID otherwise. +*/ + +#ifndef _ +#if HAVE_GETTEXT - 0 +#define _(msgid) gettext(msgid) +#else /* !(HAVE_GETTEXT - 0) */ +#define _(msgid) msgid +#endif /* !(HAVE_GETTEXT - 0) */ +#endif /* !defined _ */ + +#ifndef TZ_DOMAIN +#define TZ_DOMAIN "tz" +#endif /* !defined TZ_DOMAIN */ + +#if HAVE_INCOMPATIBLE_CTIME_R +#undef asctime_r +#undef ctime_r +char *asctime_r P((struct tm const *, char *)); +char *ctime_r P((time_t const *, char *)); +#endif /* HAVE_INCOMPATIBLE_CTIME_R */ + +/* +** UNIX was a registered trademark of The Open Group in 2003. +*/ + +#endif /* !defined PRIVATE_H */ diff --git a/src/timezone/scheck.c b/src/timezone/scheck.c new file mode 100644 index 0000000000..6bcfe87950 --- /dev/null +++ b/src/timezone/scheck.c @@ -0,0 +1,59 @@ +#ifndef lint +#ifndef NOID +static char elsieid[] = "@(#)scheck.c 8.15"; +#endif /* !defined lint */ +#endif /* !defined NOID */ + +/*LINTLIBRARY*/ + +#include "private.h" + +char * +scheck(string, format) +const char * const string; +const char * const format; +{ + register char * fbuf; + register const char * fp; + register char * tp; + register int c; + register char * result; + char dummy; + static char nada; + + result = &nada; + if (string == NULL || format == NULL) + return result; + fbuf = imalloc((int) (2 * strlen(format) + 4)); + if (fbuf == NULL) + return result; + fp = format; + tp = fbuf; + while ((*tp++ = c = *fp++) != '\0') { + if (c != '%') + continue; + if (*fp == '%') { + *tp++ = *fp++; + continue; + } + *tp++ = '*'; + if (*fp == '*') + ++fp; + while (is_digit(*fp)) + *tp++ = *fp++; + if (*fp == 'l' || *fp == 'h') + *tp++ = *fp++; + else if (*fp == '[') + do *tp++ = *fp++; + while (*fp != '\0' && *fp != ']'); + if ((*tp++ = *fp++) == '\0') + break; + } + *(tp - 1) = '%'; + *tp++ = 'c'; + *tp = '\0'; + if (sscanf(string, fbuf, &dummy) != 1) + result = (char *) format; + ifree(fbuf); + return result; +} diff --git a/src/timezone/tzfile.h b/src/timezone/tzfile.h new file mode 100644 index 0000000000..2d07a867e2 --- /dev/null +++ b/src/timezone/tzfile.h @@ -0,0 +1,188 @@ +#ifndef TZFILE_H + +#define TZFILE_H + +/* +** This file is in the public domain, so clarified as of +** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). +*/ + +/* +** This header is for use ONLY with the time conversion code. +** There is no guarantee that it will remain unchanged, +** or that it will remain at all. +** Do NOT copy it to any system include directory. +** Thank you! +*/ + +/* +** ID +*/ + +#ifndef lint +#ifndef NOID +static char tzfilehid[] = "@(#)tzfile.h 7.14"; +#endif /* !defined NOID */ +#endif /* !defined lint */ + +/* +** Information about time zone files. +*/ + +#ifndef TZDIR +#define TZDIR "/usr/local/etc/zoneinfo" /* Time zone object file directory */ +#endif /* !defined TZDIR */ + +#ifndef TZDEFAULT +#define TZDEFAULT "localtime" +#endif /* !defined TZDEFAULT */ + +#ifndef TZDEFRULES +#define TZDEFRULES "posixrules" +#endif /* !defined TZDEFRULES */ + +/* +** Each file begins with. . . +*/ + +#define TZ_MAGIC "TZif" + +struct tzhead { + char tzh_magic[4]; /* TZ_MAGIC */ + char tzh_reserved[16]; /* reserved for future use */ + char tzh_ttisgmtcnt[4]; /* coded number of trans. time flags */ + char tzh_ttisstdcnt[4]; /* coded number of trans. time flags */ + char tzh_leapcnt[4]; /* coded number of leap seconds */ + char tzh_timecnt[4]; /* coded number of transition times */ + char tzh_typecnt[4]; /* coded number of local time types */ + char tzh_charcnt[4]; /* coded number of abbr. chars */ +}; + +/* +** . . .followed by. . . +** +** tzh_timecnt (char [4])s coded transition times a la time(2) +** tzh_timecnt (unsigned char)s types of local time starting at above +** tzh_typecnt repetitions of +** one (char [4]) coded UTC offset in seconds +** one (unsigned char) used to set tm_isdst +** one (unsigned char) that's an abbreviation list index +** tzh_charcnt (char)s '\0'-terminated zone abbreviations +** tzh_leapcnt repetitions of +** one (char [4]) coded leap second transition times +** one (char [4]) total correction after above +** tzh_ttisstdcnt (char)s indexed by type; if TRUE, transition +** time is standard time, if FALSE, +** transition time is wall clock time +** if absent, transition times are +** assumed to be wall clock time +** tzh_ttisgmtcnt (char)s indexed by type; if TRUE, transition +** time is UTC, if FALSE, +** transition time is local time +** if absent, transition times are +** assumed to be local time +*/ + +/* +** In the current implementation, "tzset()" refuses to deal with files that +** exceed any of the limits below. +*/ + +#ifndef TZ_MAX_TIMES +/* +** The TZ_MAX_TIMES value below is enough to handle a bit more than a +** year's worth of solar time (corrected daily to the nearest second) or +** 138 years of Pacific Presidential Election time +** (where there are three time zone transitions every fourth year). +*/ +#define TZ_MAX_TIMES 370 +#endif /* !defined TZ_MAX_TIMES */ + +#ifndef TZ_MAX_TYPES +#ifndef NOSOLAR +#define TZ_MAX_TYPES 256 /* Limited by what (unsigned char)'s can hold */ +#endif /* !defined NOSOLAR */ +#ifdef NOSOLAR +/* +** Must be at least 14 for Europe/Riga as of Jan 12 1995, +** as noted by Earl Chew . +*/ +#define TZ_MAX_TYPES 20 /* Maximum number of local time types */ +#endif /* !defined NOSOLAR */ +#endif /* !defined TZ_MAX_TYPES */ + +#ifndef TZ_MAX_CHARS +#define TZ_MAX_CHARS 50 /* Maximum number of abbreviation characters */ + /* (limited by what unsigned chars can hold) */ +#endif /* !defined TZ_MAX_CHARS */ + +#ifndef TZ_MAX_LEAPS +#define TZ_MAX_LEAPS 50 /* Maximum number of leap second corrections */ +#endif /* !defined TZ_MAX_LEAPS */ + +#define SECSPERMIN 60 +#define MINSPERHOUR 60 +#define HOURSPERDAY 24 +#define DAYSPERWEEK 7 +#define DAYSPERNYEAR 365 +#define DAYSPERLYEAR 366 +#define SECSPERHOUR (SECSPERMIN * MINSPERHOUR) +#define SECSPERDAY ((long) SECSPERHOUR * HOURSPERDAY) +#define MONSPERYEAR 12 + +#define TM_SUNDAY 0 +#define TM_MONDAY 1 +#define TM_TUESDAY 2 +#define TM_WEDNESDAY 3 +#define TM_THURSDAY 4 +#define TM_FRIDAY 5 +#define TM_SATURDAY 6 + +#define TM_JANUARY 0 +#define TM_FEBRUARY 1 +#define TM_MARCH 2 +#define TM_APRIL 3 +#define TM_MAY 4 +#define TM_JUNE 5 +#define TM_JULY 6 +#define TM_AUGUST 7 +#define TM_SEPTEMBER 8 +#define TM_OCTOBER 9 +#define TM_NOVEMBER 10 +#define TM_DECEMBER 11 + +#define TM_YEAR_BASE 1900 + +#define EPOCH_YEAR 1970 +#define EPOCH_WDAY TM_THURSDAY + +/* +** Accurate only for the past couple of centuries; +** that will probably do. +*/ + +#define isleap(y) (((y) % 4) == 0 && (((y) % 100) != 0 || ((y) % 400) == 0)) + +#ifndef USG + +/* +** Use of the underscored variants may cause problems if you move your code to +** certain System-V-based systems; for maximum portability, use the +** underscore-free variants. The underscored variants are provided for +** backward compatibility only; they may disappear from future versions of +** this file. +*/ + +#define SECS_PER_MIN SECSPERMIN +#define MINS_PER_HOUR MINSPERHOUR +#define HOURS_PER_DAY HOURSPERDAY +#define DAYS_PER_WEEK DAYSPERWEEK +#define DAYS_PER_NYEAR DAYSPERNYEAR +#define DAYS_PER_LYEAR DAYSPERLYEAR +#define SECS_PER_HOUR SECSPERHOUR +#define SECS_PER_DAY SECSPERDAY +#define MONS_PER_YEAR MONSPERYEAR + +#endif /* !defined USG */ + +#endif /* !defined TZFILE_H */ diff --git a/src/timezone/zic.c b/src/timezone/zic.c new file mode 100644 index 0000000000..f4eaa0ca05 --- /dev/null +++ b/src/timezone/zic.c @@ -0,0 +1,2236 @@ +static char elsieid[] = "@(#)zic.c 7.115"; + +#include "private.h" +#include "locale.h" +#include "tzfile.h" + +#if HAVE_SYS_STAT_H +#include "sys/stat.h" +#endif +#ifdef S_IRUSR +#define MKDIR_UMASK (S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) +#else +#define MKDIR_UMASK 0755 +#endif + +/* +** On some ancient hosts, predicates like `isspace(C)' are defined +** only if isascii(C) || C == EOF. Modern hosts obey the C Standard, +** which says they are defined only if C == ((unsigned char) C) || C == EOF. +** Neither the C Standard nor Posix require that `isascii' exist. +** For portability, we check both ancient and modern requirements. +** If isascii is not defined, the isascii check succeeds trivially. +*/ +#include "ctype.h" +#ifndef isascii +#define isascii(x) 1 +#endif + +struct rule { + const char * r_filename; + int r_linenum; + const char * r_name; + + int r_loyear; /* for example, 1986 */ + int r_hiyear; /* for example, 1986 */ + const char * r_yrtype; + + int r_month; /* 0..11 */ + + int r_dycode; /* see below */ + int r_dayofmonth; + int r_wday; + + long r_tod; /* time from midnight */ + int r_todisstd; /* above is standard time if TRUE */ + /* or wall clock time if FALSE */ + int r_todisgmt; /* above is GMT if TRUE */ + /* or local time if FALSE */ + long r_stdoff; /* offset from standard time */ + const char * r_abbrvar; /* variable part of abbreviation */ + + int r_todo; /* a rule to do (used in outzone) */ + time_t r_temp; /* used in outzone */ +}; + +/* +** r_dycode r_dayofmonth r_wday +*/ + +#define DC_DOM 0 /* 1..31 */ /* unused */ +#define DC_DOWGEQ 1 /* 1..31 */ /* 0..6 (Sun..Sat) */ +#define DC_DOWLEQ 2 /* 1..31 */ /* 0..6 (Sun..Sat) */ + +struct zone { + const char * z_filename; + int z_linenum; + + const char * z_name; + long z_gmtoff; + const char * z_rule; + const char * z_format; + + long z_stdoff; + + struct rule * z_rules; + int z_nrules; + + struct rule z_untilrule; + time_t z_untiltime; +}; + +extern int getopt P((int argc, char * const argv[], + const char * options)); +extern int link P((const char * fromname, const char * toname)); +extern char * optarg; +extern int optind; + +static void addtt P((time_t starttime, int type)); +static int addtype P((long gmtoff, const char * abbr, int isdst, + int ttisstd, int ttisgmt)); +static void leapadd P((time_t t, int positive, int rolling, int count)); +static void adjleap P((void)); +static void associate P((void)); +static int ciequal P((const char * ap, const char * bp)); +static void convert P((long val, char * buf)); +static void dolink P((const char * fromfile, const char * tofile)); +static void doabbr P((char * abbr, const char * format, + const char * letters, int isdst)); +static void eat P((const char * name, int num)); +static void eats P((const char * name, int num, + const char * rname, int rnum)); +static long eitol P((int i)); +static void error P((const char * message)); +static char ** getfields P((char * buf)); +static long gethms P((const char * string, const char * errstrng, + int signable)); +static void infile P((const char * filename)); +static void inleap P((char ** fields, int nfields)); +static void inlink P((char ** fields, int nfields)); +static void inrule P((char ** fields, int nfields)); +static int inzcont P((char ** fields, int nfields)); +static int inzone P((char ** fields, int nfields)); +static int inzsub P((char ** fields, int nfields, int iscont)); +static int itsabbr P((const char * abbr, const char * word)); +static int itsdir P((const char * name)); +static int lowerit P((int c)); +static char * memcheck P((char * tocheck)); +static int mkdirs P((char * filename)); +static void newabbr P((const char * abbr)); +static long oadd P((long t1, long t2)); +static void outzone P((const struct zone * zp, int ntzones)); +static void puttzcode P((long code, FILE * fp)); +static int rcomp P((const void * leftp, const void * rightp)); +static time_t rpytime P((const struct rule * rp, int wantedy)); +static void rulesub P((struct rule * rp, + const char * loyearp, const char * hiyearp, + const char * typep, const char * monthp, + const char * dayp, const char * timep)); +static void setboundaries P((void)); +static time_t tadd P((time_t t1, long t2)); +static void usage P((void)); +static void writezone P((const char * name)); +static int yearistype P((int year, const char * type)); + +#if !(HAVE_STRERROR - 0) +static char * strerror P((int)); +#endif /* !(HAVE_STRERROR - 0) */ + +static int charcnt; +static int errors; +static const char * filename; +static int leapcnt; +static int linenum; +static time_t max_time; +static int max_year; +static int max_year_representable; +static time_t min_time; +static int min_year; +static int min_year_representable; +static int noise; +static const char * rfilename; +static int rlinenum; +static const char * progname; +static int timecnt; +static int typecnt; + +/* +** Line codes. +*/ + +#define LC_RULE 0 +#define LC_ZONE 1 +#define LC_LINK 2 +#define LC_LEAP 3 + +/* +** Which fields are which on a Zone line. +*/ + +#define ZF_NAME 1 +#define ZF_GMTOFF 2 +#define ZF_RULE 3 +#define ZF_FORMAT 4 +#define ZF_TILYEAR 5 +#define ZF_TILMONTH 6 +#define ZF_TILDAY 7 +#define ZF_TILTIME 8 +#define ZONE_MINFIELDS 5 +#define ZONE_MAXFIELDS 9 + +/* +** Which fields are which on a Zone continuation line. +*/ + +#define ZFC_GMTOFF 0 +#define ZFC_RULE 1 +#define ZFC_FORMAT 2 +#define ZFC_TILYEAR 3 +#define ZFC_TILMONTH 4 +#define ZFC_TILDAY 5 +#define ZFC_TILTIME 6 +#define ZONEC_MINFIELDS 3 +#define ZONEC_MAXFIELDS 7 + +/* +** Which files are which on a Rule line. +*/ + +#define RF_NAME 1 +#define RF_LOYEAR 2 +#define RF_HIYEAR 3 +#define RF_COMMAND 4 +#define RF_MONTH 5 +#define RF_DAY 6 +#define RF_TOD 7 +#define RF_STDOFF 8 +#define RF_ABBRVAR 9 +#define RULE_FIELDS 10 + +/* +** Which fields are which on a Link line. +*/ + +#define LF_FROM 1 +#define LF_TO 2 +#define LINK_FIELDS 3 + +/* +** Which fields are which on a Leap line. +*/ + +#define LP_YEAR 1 +#define LP_MONTH 2 +#define LP_DAY 3 +#define LP_TIME 4 +#define LP_CORR 5 +#define LP_ROLL 6 +#define LEAP_FIELDS 7 + +/* +** Year synonyms. +*/ + +#define YR_MINIMUM 0 +#define YR_MAXIMUM 1 +#define YR_ONLY 2 + +static struct rule * rules; +static int nrules; /* number of rules */ + +static struct zone * zones; +static int nzones; /* number of zones */ + +struct link { + const char * l_filename; + int l_linenum; + const char * l_from; + const char * l_to; +}; + +static struct link * links; +static int nlinks; + +struct lookup { + const char * l_word; + const int l_value; +}; + +static struct lookup const * byword P((const char * string, + const struct lookup * lp)); + +static struct lookup const line_codes[] = { + { "Rule", LC_RULE }, + { "Zone", LC_ZONE }, + { "Link", LC_LINK }, + { "Leap", LC_LEAP }, + { NULL, 0} +}; + +static struct lookup const mon_names[] = { + { "January", TM_JANUARY }, + { "February", TM_FEBRUARY }, + { "March", TM_MARCH }, + { "April", TM_APRIL }, + { "May", TM_MAY }, + { "June", TM_JUNE }, + { "July", TM_JULY }, + { "August", TM_AUGUST }, + { "September", TM_SEPTEMBER }, + { "October", TM_OCTOBER }, + { "November", TM_NOVEMBER }, + { "December", TM_DECEMBER }, + { NULL, 0 } +}; + +static struct lookup const wday_names[] = { + { "Sunday", TM_SUNDAY }, + { "Monday", TM_MONDAY }, + { "Tuesday", TM_TUESDAY }, + { "Wednesday", TM_WEDNESDAY }, + { "Thursday", TM_THURSDAY }, + { "Friday", TM_FRIDAY }, + { "Saturday", TM_SATURDAY }, + { NULL, 0 } +}; + +static struct lookup const lasts[] = { + { "last-Sunday", TM_SUNDAY }, + { "last-Monday", TM_MONDAY }, + { "last-Tuesday", TM_TUESDAY }, + { "last-Wednesday", TM_WEDNESDAY }, + { "last-Thursday", TM_THURSDAY }, + { "last-Friday", TM_FRIDAY }, + { "last-Saturday", TM_SATURDAY }, + { NULL, 0 } +}; + +static struct lookup const begin_years[] = { + { "minimum", YR_MINIMUM }, + { "maximum", YR_MAXIMUM }, + { NULL, 0 } +}; + +static struct lookup const end_years[] = { + { "minimum", YR_MINIMUM }, + { "maximum", YR_MAXIMUM }, + { "only", YR_ONLY }, + { NULL, 0 } +}; + +static struct lookup const leap_types[] = { + { "Rolling", TRUE }, + { "Stationary", FALSE }, + { NULL, 0 } +}; + +static const int len_months[2][MONSPERYEAR] = { + { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }, + { 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 } +}; + +static const int len_years[2] = { + DAYSPERNYEAR, DAYSPERLYEAR +}; + +static struct attype { + time_t at; + unsigned char type; +} attypes[TZ_MAX_TIMES]; +static long gmtoffs[TZ_MAX_TYPES]; +static char isdsts[TZ_MAX_TYPES]; +static unsigned char abbrinds[TZ_MAX_TYPES]; +static char ttisstds[TZ_MAX_TYPES]; +static char ttisgmts[TZ_MAX_TYPES]; +static char chars[TZ_MAX_CHARS]; +static time_t trans[TZ_MAX_LEAPS]; +static long corr[TZ_MAX_LEAPS]; +static char roll[TZ_MAX_LEAPS]; + +/* +** Memory allocation. +*/ + +static char * +memcheck(ptr) +char * const ptr; +{ + if (ptr == NULL) { + const char *e = strerror(errno); + + (void) fprintf(stderr, _("%s: Memory exhausted: %s\n"), + progname, e); + (void) exit(EXIT_FAILURE); + } + return ptr; +} + +#define emalloc(size) memcheck(imalloc(size)) +#define erealloc(ptr, size) memcheck(irealloc((ptr), (size))) +#define ecpyalloc(ptr) memcheck(icpyalloc(ptr)) +#define ecatalloc(oldp, newp) memcheck(icatalloc((oldp), (newp))) + +/* +** Error handling. +*/ + +#if !(HAVE_STRERROR - 0) +static char * +strerror(errnum) +int errnum; +{ + extern char * sys_errlist[]; + extern int sys_nerr; + + return (errnum > 0 && errnum <= sys_nerr) ? + sys_errlist[errnum] : _("Unknown system error"); +} +#endif /* !(HAVE_STRERROR - 0) */ + +static void +eats(name, num, rname, rnum) +const char * const name; +const int num; +const char * const rname; +const int rnum; +{ + filename = name; + linenum = num; + rfilename = rname; + rlinenum = rnum; +} + +static void +eat(name, num) +const char * const name; +const int num; +{ + eats(name, num, (char *) NULL, -1); +} + +static void +error(string) +const char * const string; +{ + /* + ** Match the format of "cc" to allow sh users to + ** zic ... 2>&1 | error -t "*" -v + ** on BSD systems. + */ + (void) fprintf(stderr, _("\"%s\", line %d: %s"), + filename, linenum, string); + if (rfilename != NULL) + (void) fprintf(stderr, _(" (rule from \"%s\", line %d)"), + rfilename, rlinenum); + (void) fprintf(stderr, "\n"); + ++errors; +} + +static void +warning(string) +const char * const string; +{ + char * cp; + + cp = ecpyalloc(_("warning: ")); + cp = ecatalloc(cp, string); + error(cp); + ifree(cp); + --errors; +} + +static void +usage P((void)) +{ + (void) fprintf(stderr, _("%s: usage is %s [ --version ] [ -s ] [ -v ] [ -l localtime ] [ -p posixrules ] \\\n\t[ -d directory ] [ -L leapseconds ] [ -y yearistype ] [ filename ... ]\n"), + progname, progname); + (void) exit(EXIT_FAILURE); +} + +static const char * psxrules; +static const char * lcltime; +static const char * directory; +static const char * leapsec; +static const char * yitcommand; +static int sflag = FALSE; + +int +main(argc, argv) +int argc; +char * argv[]; +{ + register int i; + register int j; + register int c; + +#ifdef unix + (void) umask(umask(S_IWGRP | S_IWOTH) | (S_IWGRP | S_IWOTH)); +#endif /* defined unix */ +#if HAVE_GETTEXT - 0 + (void) setlocale(LC_MESSAGES, ""); +#ifdef TZ_DOMAINDIR + (void) bindtextdomain(TZ_DOMAIN, TZ_DOMAINDIR); +#endif /* defined TEXTDOMAINDIR */ + (void) textdomain(TZ_DOMAIN); +#endif /* HAVE_GETTEXT - 0 */ + progname = argv[0]; + for (i = 1; i < argc; ++i) + if (strcmp(argv[i], "--version") == 0) { + (void) printf("%s\n", elsieid); + (void) exit(EXIT_SUCCESS); + } + while ((c = getopt(argc, argv, "d:l:p:L:vsy:")) != EOF && c != -1) + switch (c) { + default: + usage(); + case 'd': + if (directory == NULL) + directory = optarg; + else { + (void) fprintf(stderr, +_("%s: More than one -d option specified\n"), + progname); + (void) exit(EXIT_FAILURE); + } + break; + case 'l': + if (lcltime == NULL) + lcltime = optarg; + else { + (void) fprintf(stderr, +_("%s: More than one -l option specified\n"), + progname); + (void) exit(EXIT_FAILURE); + } + break; + case 'p': + if (psxrules == NULL) + psxrules = optarg; + else { + (void) fprintf(stderr, +_("%s: More than one -p option specified\n"), + progname); + (void) exit(EXIT_FAILURE); + } + break; + case 'y': + if (yitcommand == NULL) + yitcommand = optarg; + else { + (void) fprintf(stderr, +_("%s: More than one -y option specified\n"), + progname); + (void) exit(EXIT_FAILURE); + } + break; + case 'L': + if (leapsec == NULL) + leapsec = optarg; + else { + (void) fprintf(stderr, +_("%s: More than one -L option specified\n"), + progname); + (void) exit(EXIT_FAILURE); + } + break; + case 'v': + noise = TRUE; + break; + case 's': + sflag = TRUE; + break; + } + if (optind == argc - 1 && strcmp(argv[optind], "=") == 0) + usage(); /* usage message by request */ + if (directory == NULL) + directory = TZDIR; + if (yitcommand == NULL) + yitcommand = "yearistype"; + + setboundaries(); + + if (optind < argc && leapsec != NULL) { + infile(leapsec); + adjleap(); + } + + for (i = optind; i < argc; ++i) + infile(argv[i]); + if (errors) + (void) exit(EXIT_FAILURE); + associate(); + for (i = 0; i < nzones; i = j) { + /* + ** Find the next non-continuation zone entry. + */ + for (j = i + 1; j < nzones && zones[j].z_name == NULL; ++j) + continue; + outzone(&zones[i], j - i); + } + /* + ** Make links. + */ + for (i = 0; i < nlinks; ++i) { + eat(links[i].l_filename, links[i].l_linenum); + dolink(links[i].l_from, links[i].l_to); + } + if (lcltime != NULL) { + eat("command line", 1); + dolink(lcltime, TZDEFAULT); + } + if (psxrules != NULL) { + eat("command line", 1); + dolink(psxrules, TZDEFRULES); + } + return (errors == 0) ? EXIT_SUCCESS : EXIT_FAILURE; +} + +static void +dolink(fromfile, tofile) +const char * const fromfile; +const char * const tofile; +{ + register char * fromname; + register char * toname; + + if (fromfile[0] == '/') + fromname = ecpyalloc(fromfile); + else { + fromname = ecpyalloc(directory); + fromname = ecatalloc(fromname, "/"); + fromname = ecatalloc(fromname, fromfile); + } + if (tofile[0] == '/') + toname = ecpyalloc(tofile); + else { + toname = ecpyalloc(directory); + toname = ecatalloc(toname, "/"); + toname = ecatalloc(toname, tofile); + } + /* + ** We get to be careful here since + ** there's a fair chance of root running us. + */ + if (!itsdir(toname)) + (void) remove(toname); + if (link(fromname, toname) != 0) { + int result; + + if (mkdirs(toname) != 0) + (void) exit(EXIT_FAILURE); + + result = link(fromname, toname); +#if (HAVE_SYMLINK - 0) + if (result != 0 && + access(fromname, F_OK) == 0 && + !itsdir(fromname)) { + const char *s = tofile; + register char * symlinkcontents = NULL; + while ((s = strchr(s+1, '/')) != NULL) + symlinkcontents = ecatalloc(symlinkcontents, "../"); + symlinkcontents = ecatalloc(symlinkcontents, fromfile); + + result = symlink(symlinkcontents, toname); + if (result == 0) +warning(_("hard link failed, symbolic link used")); + ifree(symlinkcontents); + } +#endif + if (result != 0) { + const char *e = strerror(errno); + + (void) fprintf(stderr, + _("%s: Can't link from %s to %s: %s\n"), + progname, fromname, toname, e); + (void) exit(EXIT_FAILURE); + } + } + ifree(fromname); + ifree(toname); +} + +#ifndef INT_MAX +#define INT_MAX ((int) (((unsigned)~0)>>1)) +#endif /* !defined INT_MAX */ + +#ifndef INT_MIN +#define INT_MIN ((int) ~(((unsigned)~0)>>1)) +#endif /* !defined INT_MIN */ + +/* +** The tz file format currently allows at most 32-bit quantities. +** This restriction should be removed before signed 32-bit values +** wrap around in 2038, but unfortunately this will require a +** change to the tz file format. +*/ + +#define MAX_BITS_IN_FILE 32 +#define TIME_T_BITS_IN_FILE ((TYPE_BIT(time_t) < MAX_BITS_IN_FILE) ? TYPE_BIT(time_t) : MAX_BITS_IN_FILE) + +static void +setboundaries P((void)) +{ + if (TYPE_SIGNED(time_t)) { + min_time = ~ (time_t) 0; + min_time <<= TIME_T_BITS_IN_FILE - 1; + max_time = ~ (time_t) 0 - min_time; + if (sflag) + min_time = 0; + } else { + min_time = 0; + max_time = 2 - sflag; + max_time <<= TIME_T_BITS_IN_FILE - 1; + --max_time; + } + min_year = TM_YEAR_BASE + gmtime(&min_time)->tm_year; + max_year = TM_YEAR_BASE + gmtime(&max_time)->tm_year; + min_year_representable = min_year; + max_year_representable = max_year; +} + +static int +itsdir(name) +const char * const name; +{ + register char * myname; + register int accres; + + myname = ecpyalloc(name); + myname = ecatalloc(myname, "/."); + accres = access(myname, F_OK); + ifree(myname); + return accres == 0; +} + +/* +** Associate sets of rules with zones. +*/ + +/* +** Sort by rule name. +*/ + +static int +rcomp(cp1, cp2) +const void * cp1; +const void * cp2; +{ + return strcmp(((const struct rule *) cp1)->r_name, + ((const struct rule *) cp2)->r_name); +} + +static void +associate P((void)) +{ + register struct zone * zp; + register struct rule * rp; + register int base, out; + register int i, j; + + if (nrules != 0) { + (void) qsort((void *) rules, (size_t) nrules, + (size_t) sizeof *rules, rcomp); + for (i = 0; i < nrules - 1; ++i) { + if (strcmp(rules[i].r_name, + rules[i + 1].r_name) != 0) + continue; + if (strcmp(rules[i].r_filename, + rules[i + 1].r_filename) == 0) + continue; + eat(rules[i].r_filename, rules[i].r_linenum); + warning(_("same rule name in multiple files")); + eat(rules[i + 1].r_filename, rules[i + 1].r_linenum); + warning(_("same rule name in multiple files")); + for (j = i + 2; j < nrules; ++j) { + if (strcmp(rules[i].r_name, + rules[j].r_name) != 0) + break; + if (strcmp(rules[i].r_filename, + rules[j].r_filename) == 0) + continue; + if (strcmp(rules[i + 1].r_filename, + rules[j].r_filename) == 0) + continue; + break; + } + i = j - 1; + } + } + for (i = 0; i < nzones; ++i) { + zp = &zones[i]; + zp->z_rules = NULL; + zp->z_nrules = 0; + } + for (base = 0; base < nrules; base = out) { + rp = &rules[base]; + for (out = base + 1; out < nrules; ++out) + if (strcmp(rp->r_name, rules[out].r_name) != 0) + break; + for (i = 0; i < nzones; ++i) { + zp = &zones[i]; + if (strcmp(zp->z_rule, rp->r_name) != 0) + continue; + zp->z_rules = rp; + zp->z_nrules = out - base; + } + } + for (i = 0; i < nzones; ++i) { + zp = &zones[i]; + if (zp->z_nrules == 0) { + /* + ** Maybe we have a local standard time offset. + */ + eat(zp->z_filename, zp->z_linenum); + zp->z_stdoff = gethms(zp->z_rule, _("unruly zone"), + TRUE); + /* + ** Note, though, that if there's no rule, + ** a '%s' in the format is a bad thing. + */ + if (strchr(zp->z_format, '%') != 0) + error(_("%s in ruleless zone")); + } + } + if (errors) + (void) exit(EXIT_FAILURE); +} + +static void +infile(name) +const char * name; +{ + register FILE * fp; + register char ** fields; + register char * cp; + register const struct lookup * lp; + register int nfields; + register int wantcont; + register int num; + char buf[BUFSIZ]; + + if (strcmp(name, "-") == 0) { + name = _("standard input"); + fp = stdin; + } else if ((fp = fopen(name, "r")) == NULL) { + const char *e = strerror(errno); + + (void) fprintf(stderr, _("%s: Can't open %s: %s\n"), + progname, name, e); + (void) exit(EXIT_FAILURE); + } + wantcont = FALSE; + for (num = 1; ; ++num) { + eat(name, num); + if (fgets(buf, (int) sizeof buf, fp) != buf) + break; + cp = strchr(buf, '\n'); + if (cp == NULL) { + error(_("line too long")); + (void) exit(EXIT_FAILURE); + } + *cp = '\0'; + fields = getfields(buf); + nfields = 0; + while (fields[nfields] != NULL) { + static char nada; + + if (strcmp(fields[nfields], "-") == 0) + fields[nfields] = &nada; + ++nfields; + } + if (nfields == 0) { + /* nothing to do */ + } else if (wantcont) { + wantcont = inzcont(fields, nfields); + } else { + lp = byword(fields[0], line_codes); + if (lp == NULL) + error(_("input line of unknown type")); + else switch ((int) (lp->l_value)) { + case LC_RULE: + inrule(fields, nfields); + wantcont = FALSE; + break; + case LC_ZONE: + wantcont = inzone(fields, nfields); + break; + case LC_LINK: + inlink(fields, nfields); + wantcont = FALSE; + break; + case LC_LEAP: + if (name != leapsec) + (void) fprintf(stderr, +_("%s: Leap line in non leap seconds file %s\n"), + progname, name); + else inleap(fields, nfields); + wantcont = FALSE; + break; + default: /* "cannot happen" */ + (void) fprintf(stderr, +_("%s: panic: Invalid l_value %d\n"), + progname, lp->l_value); + (void) exit(EXIT_FAILURE); + } + } + ifree((char *) fields); + } + if (ferror(fp)) { + (void) fprintf(stderr, _("%s: Error reading %s\n"), + progname, filename); + (void) exit(EXIT_FAILURE); + } + if (fp != stdin && fclose(fp)) { + const char *e = strerror(errno); + + (void) fprintf(stderr, _("%s: Error closing %s: %s\n"), + progname, filename, e); + (void) exit(EXIT_FAILURE); + } + if (wantcont) + error(_("expected continuation line not found")); +} + +/* +** Convert a string of one of the forms +** h -h hh:mm -hh:mm hh:mm:ss -hh:mm:ss +** into a number of seconds. +** A null string maps to zero. +** Call error with errstring and return zero on errors. +*/ + +static long +gethms(string, errstring, signable) +const char * string; +const char * const errstring; +const int signable; +{ + int hh, mm, ss, sign; + + if (string == NULL || *string == '\0') + return 0; + if (!signable) + sign = 1; + else if (*string == '-') { + sign = -1; + ++string; + } else sign = 1; + if (sscanf(string, scheck(string, "%d"), &hh) == 1) + mm = ss = 0; + else if (sscanf(string, scheck(string, "%d:%d"), &hh, &mm) == 2) + ss = 0; + else if (sscanf(string, scheck(string, "%d:%d:%d"), + &hh, &mm, &ss) != 3) { + error(errstring); + return 0; + } + if ((hh < 0 || hh >= HOURSPERDAY || + mm < 0 || mm >= MINSPERHOUR || + ss < 0 || ss > SECSPERMIN) && + !(hh == HOURSPERDAY && mm == 0 && ss == 0)) { + error(errstring); + return 0; + } + if (noise && hh == HOURSPERDAY) + warning(_("24:00 not handled by pre-1998 versions of zic")); + return eitol(sign) * + (eitol(hh * MINSPERHOUR + mm) * + eitol(SECSPERMIN) + eitol(ss)); +} + +static void +inrule(fields, nfields) +register char ** const fields; +const int nfields; +{ + static struct rule r; + + if (nfields != RULE_FIELDS) { + error(_("wrong number of fields on Rule line")); + return; + } + if (*fields[RF_NAME] == '\0') { + error(_("nameless rule")); + return; + } + r.r_filename = filename; + r.r_linenum = linenum; + r.r_stdoff = gethms(fields[RF_STDOFF], _("invalid saved time"), TRUE); + rulesub(&r, fields[RF_LOYEAR], fields[RF_HIYEAR], fields[RF_COMMAND], + fields[RF_MONTH], fields[RF_DAY], fields[RF_TOD]); + r.r_name = ecpyalloc(fields[RF_NAME]); + r.r_abbrvar = ecpyalloc(fields[RF_ABBRVAR]); + rules = (struct rule *) (void *) erealloc((char *) rules, + (int) ((nrules + 1) * sizeof *rules)); + rules[nrules++] = r; +} + +static int +inzone(fields, nfields) +register char ** const fields; +const int nfields; +{ + register int i; + static char * buf; + + if (nfields < ZONE_MINFIELDS || nfields > ZONE_MAXFIELDS) { + error(_("wrong number of fields on Zone line")); + return FALSE; + } + if (strcmp(fields[ZF_NAME], TZDEFAULT) == 0 && lcltime != NULL) { + buf = erealloc(buf, (int) (132 + strlen(TZDEFAULT))); + (void) sprintf(buf, +_("\"Zone %s\" line and -l option are mutually exclusive"), + TZDEFAULT); + error(buf); + return FALSE; + } + if (strcmp(fields[ZF_NAME], TZDEFRULES) == 0 && psxrules != NULL) { + buf = erealloc(buf, (int) (132 + strlen(TZDEFRULES))); + (void) sprintf(buf, +_("\"Zone %s\" line and -p option are mutually exclusive"), + TZDEFRULES); + error(buf); + return FALSE; + } + for (i = 0; i < nzones; ++i) + if (zones[i].z_name != NULL && + strcmp(zones[i].z_name, fields[ZF_NAME]) == 0) { + buf = erealloc(buf, (int) (132 + + strlen(fields[ZF_NAME]) + + strlen(zones[i].z_filename))); + (void) sprintf(buf, +_("duplicate zone name %s (file \"%s\", line %d)"), + fields[ZF_NAME], + zones[i].z_filename, + zones[i].z_linenum); + error(buf); + return FALSE; + } + return inzsub(fields, nfields, FALSE); +} + +static int +inzcont(fields, nfields) +register char ** const fields; +const int nfields; +{ + if (nfields < ZONEC_MINFIELDS || nfields > ZONEC_MAXFIELDS) { + error(_("wrong number of fields on Zone continuation line")); + return FALSE; + } + return inzsub(fields, nfields, TRUE); +} + +static int +inzsub(fields, nfields, iscont) +register char ** const fields; +const int nfields; +const int iscont; +{ + register char * cp; + static struct zone z; + register int i_gmtoff, i_rule, i_format; + register int i_untilyear, i_untilmonth; + register int i_untilday, i_untiltime; + register int hasuntil; + + if (iscont) { + i_gmtoff = ZFC_GMTOFF; + i_rule = ZFC_RULE; + i_format = ZFC_FORMAT; + i_untilyear = ZFC_TILYEAR; + i_untilmonth = ZFC_TILMONTH; + i_untilday = ZFC_TILDAY; + i_untiltime = ZFC_TILTIME; + z.z_name = NULL; + } else { + i_gmtoff = ZF_GMTOFF; + i_rule = ZF_RULE; + i_format = ZF_FORMAT; + i_untilyear = ZF_TILYEAR; + i_untilmonth = ZF_TILMONTH; + i_untilday = ZF_TILDAY; + i_untiltime = ZF_TILTIME; + z.z_name = ecpyalloc(fields[ZF_NAME]); + } + z.z_filename = filename; + z.z_linenum = linenum; + z.z_gmtoff = gethms(fields[i_gmtoff], _("invalid UTC offset"), TRUE); + if ((cp = strchr(fields[i_format], '%')) != 0) { + if (*++cp != 's' || strchr(cp, '%') != 0) { + error(_("invalid abbreviation format")); + return FALSE; + } + } + z.z_rule = ecpyalloc(fields[i_rule]); + z.z_format = ecpyalloc(fields[i_format]); + hasuntil = nfields > i_untilyear; + if (hasuntil) { + z.z_untilrule.r_filename = filename; + z.z_untilrule.r_linenum = linenum; + rulesub(&z.z_untilrule, + fields[i_untilyear], + "only", + "", + (nfields > i_untilmonth) ? + fields[i_untilmonth] : "Jan", + (nfields > i_untilday) ? fields[i_untilday] : "1", + (nfields > i_untiltime) ? fields[i_untiltime] : "0"); + z.z_untiltime = rpytime(&z.z_untilrule, + z.z_untilrule.r_loyear); + if (iscont && nzones > 0 && + z.z_untiltime > min_time && + z.z_untiltime < max_time && + zones[nzones - 1].z_untiltime > min_time && + zones[nzones - 1].z_untiltime < max_time && + zones[nzones - 1].z_untiltime >= z.z_untiltime) { + error(_("Zone continuation line end time is not after end time of previous line")); + return FALSE; + } + } + zones = (struct zone *) (void *) erealloc((char *) zones, + (int) ((nzones + 1) * sizeof *zones)); + zones[nzones++] = z; + /* + ** If there was an UNTIL field on this line, + ** there's more information about the zone on the next line. + */ + return hasuntil; +} + +static void +inleap(fields, nfields) +register char ** const fields; +const int nfields; +{ + register const char * cp; + register const struct lookup * lp; + register int i, j; + int year, month, day; + long dayoff, tod; + time_t t; + + if (nfields != LEAP_FIELDS) { + error(_("wrong number of fields on Leap line")); + return; + } + dayoff = 0; + cp = fields[LP_YEAR]; + if (sscanf(cp, scheck(cp, "%d"), &year) != 1) { + /* + * Leapin' Lizards! + */ + error(_("invalid leaping year")); + return; + } + j = EPOCH_YEAR; + while (j != year) { + if (year > j) { + i = len_years[isleap(j)]; + ++j; + } else { + --j; + i = -len_years[isleap(j)]; + } + dayoff = oadd(dayoff, eitol(i)); + } + if ((lp = byword(fields[LP_MONTH], mon_names)) == NULL) { + error(_("invalid month name")); + return; + } + month = lp->l_value; + j = TM_JANUARY; + while (j != month) { + i = len_months[isleap(year)][j]; + dayoff = oadd(dayoff, eitol(i)); + ++j; + } + cp = fields[LP_DAY]; + if (sscanf(cp, scheck(cp, "%d"), &day) != 1 || + day <= 0 || day > len_months[isleap(year)][month]) { + error(_("invalid day of month")); + return; + } + dayoff = oadd(dayoff, eitol(day - 1)); + if (dayoff < 0 && !TYPE_SIGNED(time_t)) { + error(_("time before zero")); + return; + } + if (dayoff < min_time / SECSPERDAY) { + error(_("time too small")); + return; + } + if (dayoff > max_time / SECSPERDAY) { + error(_("time too large")); + return; + } + t = (time_t) dayoff * SECSPERDAY; + tod = gethms(fields[LP_TIME], _("invalid time of day"), FALSE); + cp = fields[LP_CORR]; + { + register int positive; + int count; + + if (strcmp(cp, "") == 0) { /* infile() turns "-" into "" */ + positive = FALSE; + count = 1; + } else if (strcmp(cp, "--") == 0) { + positive = FALSE; + count = 2; + } else if (strcmp(cp, "+") == 0) { + positive = TRUE; + count = 1; + } else if (strcmp(cp, "++") == 0) { + positive = TRUE; + count = 2; + } else { + error(_("illegal CORRECTION field on Leap line")); + return; + } + if ((lp = byword(fields[LP_ROLL], leap_types)) == NULL) { + error(_("illegal Rolling/Stationary field on Leap line")); + return; + } + leapadd(tadd(t, tod), positive, lp->l_value, count); + } +} + +static void +inlink(fields, nfields) +register char ** const fields; +const int nfields; +{ + struct link l; + + if (nfields != LINK_FIELDS) { + error(_("wrong number of fields on Link line")); + return; + } + if (*fields[LF_FROM] == '\0') { + error(_("blank FROM field on Link line")); + return; + } + if (*fields[LF_TO] == '\0') { + error(_("blank TO field on Link line")); + return; + } + l.l_filename = filename; + l.l_linenum = linenum; + l.l_from = ecpyalloc(fields[LF_FROM]); + l.l_to = ecpyalloc(fields[LF_TO]); + links = (struct link *) (void *) erealloc((char *) links, + (int) ((nlinks + 1) * sizeof *links)); + links[nlinks++] = l; +} + +static void +rulesub(rp, loyearp, hiyearp, typep, monthp, dayp, timep) +register struct rule * const rp; +const char * const loyearp; +const char * const hiyearp; +const char * const typep; +const char * const monthp; +const char * const dayp; +const char * const timep; +{ + register const struct lookup * lp; + register const char * cp; + register char * dp; + register char * ep; + + if ((lp = byword(monthp, mon_names)) == NULL) { + error(_("invalid month name")); + return; + } + rp->r_month = lp->l_value; + rp->r_todisstd = FALSE; + rp->r_todisgmt = FALSE; + dp = ecpyalloc(timep); + if (*dp != '\0') { + ep = dp + strlen(dp) - 1; + switch (lowerit(*ep)) { + case 's': /* Standard */ + rp->r_todisstd = TRUE; + rp->r_todisgmt = FALSE; + *ep = '\0'; + break; + case 'w': /* Wall */ + rp->r_todisstd = FALSE; + rp->r_todisgmt = FALSE; + *ep = '\0'; + break; + case 'g': /* Greenwich */ + case 'u': /* Universal */ + case 'z': /* Zulu */ + rp->r_todisstd = TRUE; + rp->r_todisgmt = TRUE; + *ep = '\0'; + break; + } + } + rp->r_tod = gethms(dp, _("invalid time of day"), FALSE); + ifree(dp); + /* + ** Year work. + */ + cp = loyearp; + lp = byword(cp, begin_years); + if (lp != NULL) switch ((int) lp->l_value) { + case YR_MINIMUM: + rp->r_loyear = INT_MIN; + break; + case YR_MAXIMUM: + rp->r_loyear = INT_MAX; + break; + default: /* "cannot happen" */ + (void) fprintf(stderr, + _("%s: panic: Invalid l_value %d\n"), + progname, lp->l_value); + (void) exit(EXIT_FAILURE); + } else if (sscanf(cp, scheck(cp, "%d"), &rp->r_loyear) != 1) { + error(_("invalid starting year")); + return; + } else if (noise) { + if (rp->r_loyear < min_year_representable) + warning(_("starting year too low to be represented")); + else if (rp->r_loyear > max_year_representable) + warning(_("starting year too high to be represented")); + } + cp = hiyearp; + if ((lp = byword(cp, end_years)) != NULL) switch ((int) lp->l_value) { + case YR_MINIMUM: + rp->r_hiyear = INT_MIN; + break; + case YR_MAXIMUM: + rp->r_hiyear = INT_MAX; + break; + case YR_ONLY: + rp->r_hiyear = rp->r_loyear; + break; + default: /* "cannot happen" */ + (void) fprintf(stderr, + _("%s: panic: Invalid l_value %d\n"), + progname, lp->l_value); + (void) exit(EXIT_FAILURE); + } else if (sscanf(cp, scheck(cp, "%d"), &rp->r_hiyear) != 1) { + error(_("invalid ending year")); + return; + } else if (noise) { + if (rp->r_loyear < min_year_representable) + warning(_("ending year too low to be represented")); + else if (rp->r_loyear > max_year_representable) + warning(_("ending year too high to be represented")); + } + if (rp->r_loyear > rp->r_hiyear) { + error(_("starting year greater than ending year")); + return; + } + if (*typep == '\0') + rp->r_yrtype = NULL; + else { + if (rp->r_loyear == rp->r_hiyear) { + error(_("typed single year")); + return; + } + rp->r_yrtype = ecpyalloc(typep); + } + if (rp->r_loyear < min_year && rp->r_loyear > 0) + min_year = rp->r_loyear; + /* + ** Day work. + ** Accept things such as: + ** 1 + ** last-Sunday + ** Sun<=20 + ** Sun>=7 + */ + dp = ecpyalloc(dayp); + if ((lp = byword(dp, lasts)) != NULL) { + rp->r_dycode = DC_DOWLEQ; + rp->r_wday = lp->l_value; + rp->r_dayofmonth = len_months[1][rp->r_month]; + } else { + if ((ep = strchr(dp, '<')) != 0) + rp->r_dycode = DC_DOWLEQ; + else if ((ep = strchr(dp, '>')) != 0) + rp->r_dycode = DC_DOWGEQ; + else { + ep = dp; + rp->r_dycode = DC_DOM; + } + if (rp->r_dycode != DC_DOM) { + *ep++ = 0; + if (*ep++ != '=') { + error(_("invalid day of month")); + ifree(dp); + return; + } + if ((lp = byword(dp, wday_names)) == NULL) { + error(_("invalid weekday name")); + ifree(dp); + return; + } + rp->r_wday = lp->l_value; + } + if (sscanf(ep, scheck(ep, "%d"), &rp->r_dayofmonth) != 1 || + rp->r_dayofmonth <= 0 || + (rp->r_dayofmonth > len_months[1][rp->r_month])) { + error(_("invalid day of month")); + ifree(dp); + return; + } + } + ifree(dp); +} + +static void +convert(val, buf) +const long val; +char * const buf; +{ + register int i; + register long shift; + + for (i = 0, shift = 24; i < 4; ++i, shift -= 8) + buf[i] = val >> shift; +} + +static void +puttzcode(val, fp) +const long val; +FILE * const fp; +{ + char buf[4]; + + convert(val, buf); + (void) fwrite((void *) buf, (size_t) sizeof buf, (size_t) 1, fp); +} + +static int +atcomp(avp, bvp) +void * avp; +void * bvp; +{ + if (((struct attype *) avp)->at < ((struct attype *) bvp)->at) + return -1; + else if (((struct attype *) avp)->at > ((struct attype *) bvp)->at) + return 1; + else return 0; +} + +static void +writezone(name) +const char * const name; +{ + register FILE * fp; + register int i, j; + static char * fullname; + static struct tzhead tzh; + time_t ats[TZ_MAX_TIMES]; + unsigned char types[TZ_MAX_TIMES]; + + /* + ** Sort. + */ + if (timecnt > 1) + (void) qsort((void *) attypes, (size_t) timecnt, + (size_t) sizeof *attypes, atcomp); + /* + ** Optimize. + */ + { + int fromi; + int toi; + + toi = 0; + fromi = 0; + while (fromi < timecnt && attypes[fromi].at < min_time) + ++fromi; + if (isdsts[0] == 0) + while (fromi < timecnt && attypes[fromi].type == 0) + ++fromi; /* handled by default rule */ + for ( ; fromi < timecnt; ++fromi) { + if (toi != 0 + && ((attypes[fromi].at + + gmtoffs[attypes[toi - 1].type]) + <= (attypes[toi - 1].at + + gmtoffs[toi == 1 ? 0 + : attypes[toi - 2].type]))) { + attypes[toi - 1].type = attypes[fromi].type; + continue; + } + if (toi == 0 || + attypes[toi - 1].type != attypes[fromi].type) + attypes[toi++] = attypes[fromi]; + } + timecnt = toi; + } + /* + ** Transfer. + */ + for (i = 0; i < timecnt; ++i) { + ats[i] = attypes[i].at; + types[i] = attypes[i].type; + } + fullname = erealloc(fullname, + (int) (strlen(directory) + 1 + strlen(name) + 1)); + (void) sprintf(fullname, "%s/%s", directory, name); + /* + ** Remove old file, if any, to snap links. + */ + if (!itsdir(fullname) && remove(fullname) != 0 && errno != ENOENT) { + const char *e = strerror(errno); + + (void) fprintf(stderr, _("%s: Can't remove %s: %s\n"), + progname, fullname, e); + (void) exit(EXIT_FAILURE); + } + if ((fp = fopen(fullname, "wb")) == NULL) { + if (mkdirs(fullname) != 0) + (void) exit(EXIT_FAILURE); + if ((fp = fopen(fullname, "wb")) == NULL) { + const char *e = strerror(errno); + + (void) fprintf(stderr, _("%s: Can't create %s: %s\n"), + progname, fullname, e); + (void) exit(EXIT_FAILURE); + } + } + convert(eitol(typecnt), tzh.tzh_ttisgmtcnt); + convert(eitol(typecnt), tzh.tzh_ttisstdcnt); + convert(eitol(leapcnt), tzh.tzh_leapcnt); + convert(eitol(timecnt), tzh.tzh_timecnt); + convert(eitol(typecnt), tzh.tzh_typecnt); + convert(eitol(charcnt), tzh.tzh_charcnt); + (void) strncpy(tzh.tzh_magic, TZ_MAGIC, sizeof tzh.tzh_magic); +#define DO(field) (void) fwrite((void *) tzh.field, (size_t) sizeof tzh.field, (size_t) 1, fp) + DO(tzh_magic); + DO(tzh_reserved); + DO(tzh_ttisgmtcnt); + DO(tzh_ttisstdcnt); + DO(tzh_leapcnt); + DO(tzh_timecnt); + DO(tzh_typecnt); + DO(tzh_charcnt); +#undef DO + for (i = 0; i < timecnt; ++i) { + j = leapcnt; + while (--j >= 0) + if (ats[i] >= trans[j]) { + ats[i] = tadd(ats[i], corr[j]); + break; + } + puttzcode((long) ats[i], fp); + } + if (timecnt > 0) + (void) fwrite((void *) types, (size_t) sizeof types[0], + (size_t) timecnt, fp); + for (i = 0; i < typecnt; ++i) { + puttzcode((long) gmtoffs[i], fp); + (void) putc(isdsts[i], fp); + (void) putc(abbrinds[i], fp); + } + if (charcnt != 0) + (void) fwrite((void *) chars, (size_t) sizeof chars[0], + (size_t) charcnt, fp); + for (i = 0; i < leapcnt; ++i) { + if (roll[i]) { + if (timecnt == 0 || trans[i] < ats[0]) { + j = 0; + while (isdsts[j]) + if (++j >= typecnt) { + j = 0; + break; + } + } else { + j = 1; + while (j < timecnt && trans[i] >= ats[j]) + ++j; + j = types[j - 1]; + } + puttzcode((long) tadd(trans[i], -gmtoffs[j]), fp); + } else puttzcode((long) trans[i], fp); + puttzcode((long) corr[i], fp); + } + for (i = 0; i < typecnt; ++i) + (void) putc(ttisstds[i], fp); + for (i = 0; i < typecnt; ++i) + (void) putc(ttisgmts[i], fp); + if (ferror(fp) || fclose(fp)) { + (void) fprintf(stderr, _("%s: Error writing %s\n"), + progname, fullname); + (void) exit(EXIT_FAILURE); + } +} + +static void +doabbr(abbr, format, letters, isdst) +char * const abbr; +const char * const format; +const char * const letters; +const int isdst; +{ + if (strchr(format, '/') == NULL) { + if (letters == NULL) + (void) strcpy(abbr, format); + else (void) sprintf(abbr, format, letters); + } else if (isdst) + (void) strcpy(abbr, strchr(format, '/') + 1); + else { + (void) strcpy(abbr, format); + *strchr(abbr, '/') = '\0'; + } +} + +static void +outzone(zpfirst, zonecount) +const struct zone * const zpfirst; +const int zonecount; +{ + register const struct zone * zp; + register struct rule * rp; + register int i, j; + register int usestart, useuntil; + register time_t starttime, untiltime; + register long gmtoff; + register long stdoff; + register int year; + register long startoff; + register int startttisstd; + register int startttisgmt; + register int type; + char startbuf[BUFSIZ]; + + INITIALIZE(untiltime); + INITIALIZE(starttime); + /* + ** Now. . .finally. . .generate some useful data! + */ + timecnt = 0; + typecnt = 0; + charcnt = 0; + /* + ** Thanks to Earl Chew (earl@dnd.icp.nec.com.au) + ** for noting the need to unconditionally initialize startttisstd. + */ + startttisstd = FALSE; + startttisgmt = FALSE; + for (i = 0; i < zonecount; ++i) { + /* + ** A guess that may well be corrected later. + */ + stdoff = 0; + zp = &zpfirst[i]; + usestart = i > 0 && (zp - 1)->z_untiltime > min_time; + useuntil = i < (zonecount - 1); + if (useuntil && zp->z_untiltime <= min_time) + continue; + gmtoff = zp->z_gmtoff; + eat(zp->z_filename, zp->z_linenum); + *startbuf = '\0'; + startoff = zp->z_gmtoff; + if (zp->z_nrules == 0) { + stdoff = zp->z_stdoff; + doabbr(startbuf, zp->z_format, + (char *) NULL, stdoff != 0); + type = addtype(oadd(zp->z_gmtoff, stdoff), + startbuf, stdoff != 0, startttisstd, + startttisgmt); + if (usestart) { + addtt(starttime, type); + usestart = FALSE; + } else if (stdoff != 0) + addtt(min_time, type); + } else for (year = min_year; year <= max_year; ++year) { + if (useuntil && year > zp->z_untilrule.r_hiyear) + break; + /* + ** Mark which rules to do in the current year. + ** For those to do, calculate rpytime(rp, year); + */ + for (j = 0; j < zp->z_nrules; ++j) { + rp = &zp->z_rules[j]; + eats(zp->z_filename, zp->z_linenum, + rp->r_filename, rp->r_linenum); + rp->r_todo = year >= rp->r_loyear && + year <= rp->r_hiyear && + yearistype(year, rp->r_yrtype); + if (rp->r_todo) + rp->r_temp = rpytime(rp, year); + } + for ( ; ; ) { + register int k; + register time_t jtime, ktime; + register long offset; + char buf[BUFSIZ]; + + INITIALIZE(ktime); + if (useuntil) { + /* + ** Turn untiltime into UTC + ** assuming the current gmtoff and + ** stdoff values. + */ + untiltime = zp->z_untiltime; + if (!zp->z_untilrule.r_todisgmt) + untiltime = tadd(untiltime, + -gmtoff); + if (!zp->z_untilrule.r_todisstd) + untiltime = tadd(untiltime, + -stdoff); + } + /* + ** Find the rule (of those to do, if any) + ** that takes effect earliest in the year. + */ + k = -1; + for (j = 0; j < zp->z_nrules; ++j) { + rp = &zp->z_rules[j]; + if (!rp->r_todo) + continue; + eats(zp->z_filename, zp->z_linenum, + rp->r_filename, rp->r_linenum); + offset = rp->r_todisgmt ? 0 : gmtoff; + if (!rp->r_todisstd) + offset = oadd(offset, stdoff); + jtime = rp->r_temp; + if (jtime == min_time || + jtime == max_time) + continue; + jtime = tadd(jtime, -offset); + if (k < 0 || jtime < ktime) { + k = j; + ktime = jtime; + } + } + if (k < 0) + break; /* go on to next year */ + rp = &zp->z_rules[k]; + rp->r_todo = FALSE; + if (useuntil && ktime >= untiltime) + break; + stdoff = rp->r_stdoff; + if (usestart && ktime == starttime) + usestart = FALSE; + if (usestart) { + if (ktime < starttime) { + startoff = oadd(zp->z_gmtoff, + stdoff); + doabbr(startbuf, zp->z_format, + rp->r_abbrvar, + rp->r_stdoff != 0); + continue; + } + if (*startbuf == '\0' && + startoff == oadd(zp->z_gmtoff, + stdoff)) { + doabbr(startbuf, zp->z_format, + rp->r_abbrvar, + rp->r_stdoff != 0); + } + } + eats(zp->z_filename, zp->z_linenum, + rp->r_filename, rp->r_linenum); + doabbr(buf, zp->z_format, rp->r_abbrvar, + rp->r_stdoff != 0); + offset = oadd(zp->z_gmtoff, rp->r_stdoff); + type = addtype(offset, buf, rp->r_stdoff != 0, + rp->r_todisstd, rp->r_todisgmt); + addtt(ktime, type); + } + } + if (usestart) { + if (*startbuf == '\0' && + zp->z_format != NULL && + strchr(zp->z_format, '%') == NULL && + strchr(zp->z_format, '/') == NULL) + (void) strcpy(startbuf, zp->z_format); + eat(zp->z_filename, zp->z_linenum); + if (*startbuf == '\0') +error(_("can't determine time zone abbreviation to use just after until time")); + else addtt(starttime, + addtype(startoff, startbuf, + startoff != zp->z_gmtoff, + startttisstd, + startttisgmt)); + } + /* + ** Now we may get to set starttime for the next zone line. + */ + if (useuntil) { + startttisstd = zp->z_untilrule.r_todisstd; + startttisgmt = zp->z_untilrule.r_todisgmt; + starttime = zp->z_untiltime; + if (!startttisstd) + starttime = tadd(starttime, -stdoff); + if (!startttisgmt) + starttime = tadd(starttime, -gmtoff); + } + } + writezone(zpfirst->z_name); +} + +static void +addtt(starttime, type) +const time_t starttime; +int type; +{ + if (starttime <= min_time || + (timecnt == 1 && attypes[0].at < min_time)) { + gmtoffs[0] = gmtoffs[type]; + isdsts[0] = isdsts[type]; + ttisstds[0] = ttisstds[type]; + ttisgmts[0] = ttisgmts[type]; + if (abbrinds[type] != 0) + (void) strcpy(chars, &chars[abbrinds[type]]); + abbrinds[0] = 0; + charcnt = strlen(chars) + 1; + typecnt = 1; + timecnt = 0; + type = 0; + } + if (timecnt >= TZ_MAX_TIMES) { + error(_("too many transitions?!")); + (void) exit(EXIT_FAILURE); + } + attypes[timecnt].at = starttime; + attypes[timecnt].type = type; + ++timecnt; +} + +static int +addtype(gmtoff, abbr, isdst, ttisstd, ttisgmt) +const long gmtoff; +const char * const abbr; +const int isdst; +const int ttisstd; +const int ttisgmt; +{ + register int i, j; + + if (isdst != TRUE && isdst != FALSE) { + error(_("internal error - addtype called with bad isdst")); + (void) exit(EXIT_FAILURE); + } + if (ttisstd != TRUE && ttisstd != FALSE) { + error(_("internal error - addtype called with bad ttisstd")); + (void) exit(EXIT_FAILURE); + } + if (ttisgmt != TRUE && ttisgmt != FALSE) { + error(_("internal error - addtype called with bad ttisgmt")); + (void) exit(EXIT_FAILURE); + } + /* + ** See if there's already an entry for this zone type. + ** If so, just return its index. + */ + for (i = 0; i < typecnt; ++i) { + if (gmtoff == gmtoffs[i] && isdst == isdsts[i] && + strcmp(abbr, &chars[abbrinds[i]]) == 0 && + ttisstd == ttisstds[i] && + ttisgmt == ttisgmts[i]) + return i; + } + /* + ** There isn't one; add a new one, unless there are already too + ** many. + */ + if (typecnt >= TZ_MAX_TYPES) { + error(_("too many local time types")); + (void) exit(EXIT_FAILURE); + } + gmtoffs[i] = gmtoff; + isdsts[i] = isdst; + ttisstds[i] = ttisstd; + ttisgmts[i] = ttisgmt; + + for (j = 0; j < charcnt; ++j) + if (strcmp(&chars[j], abbr) == 0) + break; + if (j == charcnt) + newabbr(abbr); + abbrinds[i] = j; + ++typecnt; + return i; +} + +static void +leapadd(t, positive, rolling, count) +const time_t t; +const int positive; +const int rolling; +int count; +{ + register int i, j; + + if (leapcnt + (positive ? count : 1) > TZ_MAX_LEAPS) { + error(_("too many leap seconds")); + (void) exit(EXIT_FAILURE); + } + for (i = 0; i < leapcnt; ++i) + if (t <= trans[i]) { + if (t == trans[i]) { + error(_("repeated leap second moment")); + (void) exit(EXIT_FAILURE); + } + break; + } + do { + for (j = leapcnt; j > i; --j) { + trans[j] = trans[j - 1]; + corr[j] = corr[j - 1]; + roll[j] = roll[j - 1]; + } + trans[i] = t; + corr[i] = positive ? 1L : eitol(-count); + roll[i] = rolling; + ++leapcnt; + } while (positive && --count != 0); +} + +static void +adjleap P((void)) +{ + register int i; + register long last = 0; + + /* + ** propagate leap seconds forward + */ + for (i = 0; i < leapcnt; ++i) { + trans[i] = tadd(trans[i], last); + last = corr[i] += last; + } +} + +static int +yearistype(year, type) +const int year; +const char * const type; +{ + static char * buf; + int result; + + if (type == NULL || *type == '\0') + return TRUE; + buf = erealloc(buf, (int) (132 + strlen(yitcommand) + strlen(type))); + (void) sprintf(buf, "%s %d %s", yitcommand, year, type); + result = system(buf); + if (WIFEXITED(result)) switch (WEXITSTATUS(result)) { + case 0: + return TRUE; + case 1: + return FALSE; + } + error(_("Wild result from command execution")); + (void) fprintf(stderr, _("%s: command was '%s', result was %d\n"), + progname, buf, result); + for ( ; ; ) + (void) exit(EXIT_FAILURE); +} + +static int +lowerit(a) +int a; +{ + a = (unsigned char) a; + return (isascii(a) && isupper(a)) ? tolower(a) : a; +} + +static int +ciequal(ap, bp) /* case-insensitive equality */ +register const char * ap; +register const char * bp; +{ + while (lowerit(*ap) == lowerit(*bp++)) + if (*ap++ == '\0') + return TRUE; + return FALSE; +} + +static int +itsabbr(abbr, word) +register const char * abbr; +register const char * word; +{ + if (lowerit(*abbr) != lowerit(*word)) + return FALSE; + ++word; + while (*++abbr != '\0') + do { + if (*word == '\0') + return FALSE; + } while (lowerit(*word++) != lowerit(*abbr)); + return TRUE; +} + +static const struct lookup * +byword(word, table) +register const char * const word; +register const struct lookup * const table; +{ + register const struct lookup * foundlp; + register const struct lookup * lp; + + if (word == NULL || table == NULL) + return NULL; + /* + ** Look for exact match. + */ + for (lp = table; lp->l_word != NULL; ++lp) + if (ciequal(word, lp->l_word)) + return lp; + /* + ** Look for inexact match. + */ + foundlp = NULL; + for (lp = table; lp->l_word != NULL; ++lp) + if (itsabbr(word, lp->l_word)) { + if (foundlp == NULL) + foundlp = lp; + else return NULL; /* multiple inexact matches */ + } + return foundlp; +} + +static char ** +getfields(cp) +register char * cp; +{ + register char * dp; + register char ** array; + register int nsubs; + + if (cp == NULL) + return NULL; + array = (char **) (void *) + emalloc((int) ((strlen(cp) + 1) * sizeof *array)); + nsubs = 0; + for ( ; ; ) { + while (isascii(*cp) && isspace((unsigned char) *cp)) + ++cp; + if (*cp == '\0' || *cp == '#') + break; + array[nsubs++] = dp = cp; + do { + if ((*dp = *cp++) != '"') + ++dp; + else while ((*dp = *cp++) != '"') + if (*dp != '\0') + ++dp; + else error(_("Odd number of quotation marks")); + } while (*cp != '\0' && *cp != '#' && + (!isascii(*cp) || !isspace((unsigned char) *cp))); + if (isascii(*cp) && isspace((unsigned char) *cp)) + ++cp; + *dp = '\0'; + } + array[nsubs] = NULL; + return array; +} + +static long +oadd(t1, t2) +const long t1; +const long t2; +{ + register long t; + + t = t1 + t2; + if ((t2 > 0 && t <= t1) || (t2 < 0 && t >= t1)) { + error(_("time overflow")); + (void) exit(EXIT_FAILURE); + } + return t; +} + +static time_t +tadd(t1, t2) +const time_t t1; +const long t2; +{ + register time_t t; + + if (t1 == max_time && t2 > 0) + return max_time; + if (t1 == min_time && t2 < 0) + return min_time; + t = t1 + t2; + if ((t2 > 0 && t <= t1) || (t2 < 0 && t >= t1)) { + error(_("time overflow")); + (void) exit(EXIT_FAILURE); + } + return t; +} + +/* +** Given a rule, and a year, compute the date - in seconds since January 1, +** 1970, 00:00 LOCAL time - in that year that the rule refers to. +*/ + +static time_t +rpytime(rp, wantedy) +register const struct rule * const rp; +register const int wantedy; +{ + register int y, m, i; + register long dayoff; /* with a nod to Margaret O. */ + register time_t t; + + if (wantedy == INT_MIN) + return min_time; + if (wantedy == INT_MAX) + return max_time; + dayoff = 0; + m = TM_JANUARY; + y = EPOCH_YEAR; + while (wantedy != y) { + if (wantedy > y) { + i = len_years[isleap(y)]; + ++y; + } else { + --y; + i = -len_years[isleap(y)]; + } + dayoff = oadd(dayoff, eitol(i)); + } + while (m != rp->r_month) { + i = len_months[isleap(y)][m]; + dayoff = oadd(dayoff, eitol(i)); + ++m; + } + i = rp->r_dayofmonth; + if (m == TM_FEBRUARY && i == 29 && !isleap(y)) { + if (rp->r_dycode == DC_DOWLEQ) + --i; + else { + error(_("use of 2/29 in non leap-year")); + (void) exit(EXIT_FAILURE); + } + } + --i; + dayoff = oadd(dayoff, eitol(i)); + if (rp->r_dycode == DC_DOWGEQ || rp->r_dycode == DC_DOWLEQ) { + register long wday; + +#define LDAYSPERWEEK ((long) DAYSPERWEEK) + wday = eitol(EPOCH_WDAY); + /* + ** Don't trust mod of negative numbers. + */ + if (dayoff >= 0) + wday = (wday + dayoff) % LDAYSPERWEEK; + else { + wday -= ((-dayoff) % LDAYSPERWEEK); + if (wday < 0) + wday += LDAYSPERWEEK; + } + while (wday != eitol(rp->r_wday)) + if (rp->r_dycode == DC_DOWGEQ) { + dayoff = oadd(dayoff, (long) 1); + if (++wday >= LDAYSPERWEEK) + wday = 0; + ++i; + } else { + dayoff = oadd(dayoff, (long) -1); + if (--wday < 0) + wday = LDAYSPERWEEK - 1; + --i; + } + if (i < 0 || i >= len_months[isleap(y)][m]) { + error(_("no day in month matches rule")); + (void) exit(EXIT_FAILURE); + } + } + if (dayoff < 0 && !TYPE_SIGNED(time_t)) + return min_time; + if (dayoff < min_time / SECSPERDAY) + return min_time; + if (dayoff > max_time / SECSPERDAY) + return max_time; + t = (time_t) dayoff * SECSPERDAY; + return tadd(t, rp->r_tod); +} + +static void +newabbr(string) +const char * const string; +{ + register int i; + + i = strlen(string) + 1; + if (charcnt + i > TZ_MAX_CHARS) { + error(_("too many, or too long, time zone abbreviations")); + (void) exit(EXIT_FAILURE); + } + (void) strcpy(&chars[charcnt], string); + charcnt += eitol(i); +} + +static int +mkdirs(argname) +char * const argname; +{ + register char * name; + register char * cp; + + if (argname == NULL || *argname == '\0') + return 0; + cp = name = ecpyalloc(argname); + while ((cp = strchr(cp + 1, '/')) != 0) { + *cp = '\0'; +#ifndef unix + /* + ** DOS drive specifier? + */ + if (isalpha((unsigned char) name[0]) && + name[1] == ':' && name[2] == '\0') { + *cp = '/'; + continue; + } +#endif /* !defined unix */ + if (!itsdir(name)) { + /* + ** It doesn't seem to exist, so we try to create it. + ** Creation may fail because of the directory being + ** created by some other multiprocessor, so we get + ** to do extra checking. + */ + if (mkdir(name, MKDIR_UMASK) != 0) { + const char *e = strerror(errno); + + if (errno != EEXIST || !itsdir(name)) { + (void) fprintf(stderr, +_("%s: Can't create directory %s: %s\n"), + progname, name, e); + ifree(name); + return -1; + } + } + } + *cp = '/'; + } + ifree(name); + return 0; +} + +static long +eitol(i) +const int i; +{ + long l; + + l = i; + if ((i < 0 && l >= 0) || (i == 0 && l != 0) || (i > 0 && l <= 0)) { + (void) fprintf(stderr, + _("%s: %d did not sign extend correctly\n"), + progname, i); + (void) exit(EXIT_FAILURE); + } + return l; +} + +/* +** UNIX was a registered trademark of The Open Group in 2003. +*/