[comp.os.minix] Posix compliant TZ implementation

baron@wiesje.hobby.nl (Wim `Blue Baron' van Dorst) (04/13/91)

hello *,

By now nearly the whole civilized world will have found it necessary to
complicate people's lives by changing the time. This summertime, often
called daylight saving time (DST) will last for a couple of months and
then _again_ the time is changed. Are you fed up with changing the time
of your computer too? Here is the way to do it better :-).

Posix defines in its 1003.1 a TZ environment variable which indicates
when you DST starts and ends and a (char *)tzname[2]. I implemented 
these in the 1.5.10 Minix lib/ansi/ctime.c for the functions involved, 
i.e. ctime(), localtime(), mktime() and tzset(). In the source I 
include a complete desciption of what the TZ looks like according to 
Posix (and me :-).  

The idea is that every computer on the world internally runs on Greenwich
Mean Time (GMT), or better called Universal Coordinated Time (UCT). The
TZ indicates how far the particular computer is off GMT. Extra the TZ
indicates whether there is DST, and the start and end date. When the local
time should be known for display or reference ('date', news/mail Date: 
field, 'cron') the internal GMT combined with TZ gives the local time.

Here is a piece about TZ from the source:

* Time zones (TZ) are given as strings of the form (spaces only for clarity)
*
*    Std Offset [Dst [Offset] [,Startdate[/Time], Enddate[/Time]]]
*
* where:
* Std and Dst three or more bytes that are the designation for the standard
*             (std) or summer (dst) time zone. Only std is required; if dst
*             is missing, then summer time doen not apply in this locale.
*
* Offset and  Indicates the value one must add to the local time to arrive
* Time        at Coordinated Universal Time. The offset has the form
*                hh[:mm[:ss]]
*             The hours shall be required and may be a single digit. If no
*             offset follows dst, summer time is assumed to be one hour ahead
*             of standard time. If preceded by a "-", the time zone shall be
*             east of the Prime meridian; otherwise it shall be west. Default
*             DST offset will be 1 hour, default switch Time will be 02:00:00
*
* date        The format of the date shall be one of the following:
*             Jn      Julian day (1 <= n <= 365)
*                     leapdays are NOT counted, so March 1 is always day 60
*             n       Zero-based Julian day (0 <= n <= 365)
*                     leapdays are counted, so March 1 is day 61 in leapyears
*             Mm.n.d  The d-th day (0<=d<=6) of week n (1 <=n<=5) of month
*                     m (1<=m<=12), where week 5 means 'the last d day in
*                     month m' which may occur in either the fourth or
*                     fifth week. Week 1 is the first week in which d'th
*                     day occurs. Day zero is sunday.
*
* See for more explanations on the TZ definition the IEEE Std 1003.1-1988
* Posix Standard, paragraphs 8.1.1 "Extensions to Time Functions" on 142-143.

For reasons of simplicity I twice took the liberty of deviating from the
straight Posix, namely time specification will be ignored, and is hardcoded 
to 02:00:00 and this TZ-stuff only works properly on the Nothern Hemisphere.
The time specification would mean much ado about little as nearly all time
changes take place at 02:00 (or thereabouts). The TZ-stuff will easily work 
on the Southern Hemisphere by swopping two hunk of source (It is indicated 
in the file). Those who will not accept this: Sorry for them.

Now the ten steps of the installation:
 1. unpack the thing below               uud mail
                                         decompress ctime.shar.Z
                                         sh < ctime.shar
 2. Read the Readme                      more Readme (this text)
 3. put ctime.c in /usr/src/lib/ansi     mv ctime.c /usr/src/lib/ansi
 4. compile it to ctime.s                make ctime.s
 5. replace the ctime.s now in libc.a    ar rv /usr/lib/libc.a ctime.s
 6. as you don't believe me....          mv Date.c /usr/src/commands
    compile the demo programme and...    make f=Date
    give it a try                        TZ=Foo2Bar,1,300;Date
 6. Then, convinced, you recompile all programmes that use the time 
    functions, such as date, cron, mail, inews
 7. Edit /etc/rc and put a TZ definition up at the beginning, especially
    before date is run and before cron is started
 8. Edit /etc/profile and put the same TZ definition in there
 9. login anew as root, and set the battery-backup'ed clock to GMT, or
    if you can use 'date' for that (volatile clock== b-b'ed clock) or if
    you have no b-b'ed clock (then why bother about TZ) to local time, as
    the mktime() in 'date' will do the TZ translation for you.
10. Done. (you may want to reboot to be sure, but it is not needed).

Several examples how to define your TZ:
Middle-Europe (=Central Europe), e.g. The Netherlands, Belgium, Germany,
France, Italy, Austria, Switzerland, Spain, Portugal
               MET-01:00:00METDST+01:00:00,M3.5.0/02:00:00,M9.5.0/02:00:00
           or  MET-1METDST,M3.5.0,M9.5.0 (using the defaults :-)
UK             GMT0BST,M3.5.0,M9.5.0 
Western SU     WSU-3WSUDST,M3.5.0,M9.5.0 (knowledgeable guess)
Eastern USA    EST5EDT (US rule is default) 
Central USA    CST6CDT 
Newfoundland   NFLD3:30NFLD
Central Oz     OZCST-9:30 (doesn't have DST).

Those of who are still reading here, 
Would you, in case you think this so rewarding that you put it into action,
be so kind to drop me a line stating so? Thanks.

Met vriendelijke groeten, Wim `Blue Baron' van Dorst.
---------------------------------------------------------------------
Blue Baron = Wim van Dorst, Voice (+31) 074-443937, (+31) 02152-42319
(-:       baron@wiesje.hobby.nl           tgcpwd@urc.tue.nl       :-)
---------------------------------------------------------------------


table
 !"#$%&'()*+,-./0123456789:;<=>?
@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_
begin 644 ctime.shar.Z
M'YV-(T* >"$FC9L7<] H& &"#IHT<T! !!$&1,(R;-A0E#/FH9TR+$"T*1/&z
MC<$S.A:"B.$"A)0R;=Y\!%'FHYP\#D]2%".S3$,T/@,.+'@P(0@V!LNHE-%Ry
M2IB9#GW**3.G#ALZ.NF4P4-'HAN*(,RD85/&A<H9+8O@*3.FCM:?/L62!7$Gx
MC<.A!A&B:?@&Q)BI8=Y&#3N6:LH1"5Z&(3,R00(01 *7'>/8+]:1+L8L5$GEw
M8<0P'#WZ_$M2*QD=(*Z4(1,R!@P00>#(69DC1PP0,F3HH#%C=PX038I0(3*%v
M"@@Q>8Z#?N,&2%VJ:I2.4+ 5SALY7:$$H8)D!PCMW'L0-*B#!'@DFQ6D,=.0u
M:M<6[!4S5AK5#?6.?1."1ETW(P@W;W35DQPMW"&'73YM!1%6;IQ!V%SRC40=t
M&W,HQ18:^:&Q'TU<R1'&& PZ>$*$99P0$@@HUH"#BBAV!-J'6LDQAP(5D@'"s
M"7.\X 46+[QP @@^N$32?"#PP,,)4R 1A!1?%/&$$2<H@ 50&?6E @M22BE$r
M<@#>\1])<K"1W&!W8#C7&&G8,58:>JQ&UW5LV-B?1AK.9,8;=;AAHUU?CD'5q
M'*"-^8:48[S1!AQ(C2$9"'"4\0:B)4:$U$<1(>>7A@UF!51#:6 &0F<35=7&p
M2-AU"A((;YBAE7U8*)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5C)(&E.$;;J*0CJ,q
M.C <YT@0P7SNC@Y0&S22$AM"6I<!")ER<\"Q/AQCJEK_;W2 ;7',$[;87%?2p
M$&FTRW8EHC&0TG;756MI2_RNY;6\)M/@@GWH:LL+IPWVO(O8?1KSN%Y#S484o
?->AI3O":7A-?2ZT0-34;\=1L EF3:D"!JBF(KJ!G  WVn
 m
end
---------------------------------------------------------------------
Blue Baron = Wim van Dorst, Voice (+31) 074-443937, (+31) 02152-42319
(-:       baron@wiesje.hobby.nl           tgcpwd@urc.tue.nl       :-)
---------------------------------------------------------------------

steveq@syd.dms.CSIRO.AU (Stephen Quigg) (04/16/91)

In article <91041010973@wiesje.hobby.nl> baron@wiesje.hobby.nl (Wim `Blue Baron' van Dorst) writes:
> stuff deleted 
>* date        The format of the date shall be one of the following:
>*             Jn      Julian day (1 <= n <= 365)
>*                     leapdays are NOT counted, so March 1 is always day 60
>*             n       Zero-based Julian day (0 <= n <= 365)
>*                     leapdays are counted, so March 1 is day 61 in leapyears
>---------------------------------------------------------------------
>Blue Baron = Wim van Dorst, Voice (+31) 074-443937, (+31) 02152-42319 >(-:       baron@wiesje.hobby.nl           tgcpwd@urc.tue.nl       :-)
>---------------------------------------------------------------------

The "Julian" day mentioned above is really "day number" The Julian date
is a unique number for any date, JD 1 being reckoned from Jan 1, 4713 B.C.,
so that today's date is Jd 248363. There is also a modified Julian Date,
MJD which is JD - 240,000.5, the .5 because the MJD starts on the previous
midnight. (This calculation assumes that the JD has a fractional part to
signify time-of-day. The fraction is usually dropped.) Hence, today's
MJD is 8362. Sometimes a 5-digit figure is given, ie  MJD 48362 .  
 If I've confused you, or you want more info, mail me.
Regards,
Steve Quigg.