[net.unix-wizards] Daylight/Standard Time Changes

espo@bpa.UUCP (Bob Esposito) (07/09/86)

	Here's some food for thought.  Now that the Pres. signed into
	law the Daylight Savings Time eff. 1st Sun. April 1987, what
	are we gonna do ???


	Well I devised a new approach to the problem.  Just like
	the old days on UNIX, you had to re-compile the accounting
	software for holiday changes.  Now there's a holiday table
	that can be edited for the necessary changes.  Well I took
	a similar approach to ctime.c(3c).

	The only problem (which is a MAJOR one), is that all current
	programs that utilize ctime() must be re-compiled !!!!
	Boy what a job that could be.  I wonder if anyone else has
	a better idea ??

	Just for completeness, here's the table I designed for ctime();
	I call it `dsttab'.  I cannot distribute the ctime.c source
	for obvious reasons.


	Bob Esposito   bpa!espo

 -------------------------------------------------------------------------
* @ dsttab 1.2
* Daylight/Standard Time table for UNIX localtime().
*
* This table is used to get the beginning/ending days
* for Daylight Savings Time, on a yearly basis.
* Since Congress is so willing to changes these so called
* standard times, the UNIX administrator must have a way
* to cope with it.
*
* Table format is really pretty simple.  If there is an
* entry for the year, it must have the beginning and
* ending sundays month-days, separated by some white-space;
* e.g. 1974 <space/tab> 5 <space/tab> 335
* e.g. 1975 <space/tab> 58 <space/tab> 303
*
* These examples show the particulars for 1974 and 1975,
* where in 1974 Daylight Savings started on Jan. 6 and
* ended on the last sunday in Nov.  And in 1975, began
* on the last sunday in Feb. and ended on the last sunday
* in Oct.
*
* If there is no year entry, localtime() assumes the standard(?)
* time settings; last sunday of April to the last sunday in Oct.
*
*
* year		begin		end
*
1974		5		333
1975		58		303
1986		190		303

chris@umcp-cs.UUCP (Chris Torek) (07/10/86)

In article <163@bpa.UUCP> espo@bpa.UUCP (Bob Esposito) writes:
>Here's some food for thought.  Now that the Pres. signed into
>law the Daylight Savings Time eff. 1st Sun. April 1987, what
>are we gonna do ???

If you are using Arthur Olson's timezone compiler (avaialble
from your nearest mod.sources archive), just apply a few changes
to your timezones source files, and run the timezone compiler.

The problem is already solved!  ---at least until the next election
year. . . .
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 1516)
UUCP:	seismo!umcp-cs!chris
CSNet:	chris@umcp-cs		ARPA:	chris@mimsy.umd.edu

jsq@im4u.UUCP (John Quarterman) (07/18/86)

This subject was discussed to death in mod.std.unix earlier this year.
The new U.S. DST law provides a convenient opportunity to post a
summary of that discussion and the proposal to IEEE 1003 that came out of it.
These can now be found in mod.std.unix.  They are not intended to start
the subject up again there, just to document what went before.

There is an implementation by Arthur Olsen in mod.sources.
-- 
John Quarterman, UUCP:  {gatech,harvard,ihnp4,pyramid,seismo}!ut-sally!im4u!jsq
ARPA Internet and CSNET:  jsq@im4u.UTEXAS.EDU, jsq@sally.UTEXAS.EDU