# /usr/src/etc/tzone/Makefile for MacMach

include /usr/src/COPYRIGHTS

# If you want something other than Eastern United States time used on your
# system, change the line below (after finding the zone you want in the
# time zone files, or adding it to a time zone file).
# Alternately, if you discover you've got the wrong time zone, you can just
#	zic -l rightzone
LOCALTIME=	US/Eastern

# If you want code inspired by certain emerging standards, add
#	-DSTD_INSPIRED
# to the end of the "CFLAGS=" line.

CFLAGS=	-O
LIBC=	/lib/libc.a
TZCSRCS=zic.c scheck.c ialloc.c
TZCOBJS=zic.o scheck.o ialloc.o
TZDSRCS=zdump.c ialloc.c
TZDOBJS=zdump.o ialloc.o
DOCS=	Theory README Makefile newctime.3 tzfile.5 zic.8 zdump.8
SRCS=	zic.c zdump.c scheck.c ialloc.c

# If you want to handle solar-time-based time zones, remove the
# "#define NOSOLAR" from the include file usr/include/tzfile.h.
# (and add solar87 to the DATA= line below).
DATA=	asia australasia europe etcetera northamerica \
	pacificnew systemv

all:	.depend zdump zic

zdump:	${TZDOBJS} ${LIBC}
	${CC} ${CFLAGS} ${TZDOBJS} -o $@

zic:	${TZCOBJS} ${LIBC}
	${CC} ${CFLAGS} ${TZCOBJS} -o $@

install: FRC
	./zic ${DATA}
	./zic -d ${DESTDIR}/etc/zoneinfo -l ${LOCALTIME} ${DATA}

clean:	FRC
	rm -f .depend ${TZDOBJS} ${TZCOBJS} core zdump zic

compress: clean
	find . -type f ! -name Makefile ! -name '*.Z' -exec compress {} \;

uncompress: FRC
	find . -type f ! -name Makefile -name '*.Z' -exec uncompress {} \;

.depend: ${SRCS}
	@echo "#`date`" >.depend
	mkdep -f .depend ${CFLAGS} ${SRCS}

-include .depend

FRC:
