#
# $Id: Makefile,v 1.2 1992/06/16 18:14:02 stevea Exp stevea $
#
ENSCRIPT=enscript
EOPTS=
NROFF=nroff
PRINTER=ps1w
SED=sed
SPELL=spell
STOP=./Stoplist
DRAFTLIST=auth.txt auth.spx.txt auth.kerbIV.txt auth.kerbV.txt encrypt.txt environ.txt authenc.txt k5.exp.txt
DIFFLIST=auth.diff auth.spx.diff auth.kerbIV.diff auth.kerbV.diff encrypt.diff environ.diff authenc.diff k5.exp.diff
REV=

.SUFFIXES:	.txt .diff .diffmk .nr

.nr.txt:
	${NROFF} $*.nr | ${SED} 's/^ *@//' >$*.txt

.nr.diffmk:
	/home/stevea/bin/rcsdiffmk ${REV} $*.nr
	mv $*.nr.diffmk $*.diffmk

.diffmk.diff:
	${NROFF} $*.diffmk | ${SED} 's/^ *@//' >$*.diff

all: ${DRAFTLIST}

diffs: ${DIFFLIST}

spell:
	${SPELL} +${STOP} ${DRAFTLIST}

more: ${DRAFTLIST}
	more ${DRAFTLIST}

clean:
	rm -f ${DRAFTLIST}

auth.txt: auth.nr
authenc.txt: authenc.nr
auth.spx.txt: auth.spx.nr
auth.kerbIV.txt: auth.kerbIV.nr
auth.kerbV.txt: auth.kerbV.nr
k5.exp.txt: k5.exp.nr
encrypt.txt: encrypt.nr
environ.txt: environ.nr

auth.diff: auth.diffmk
authenc.diff: authenc.diffmk
auth.spx.diff: auth.spx.diffmk
auth.kerbIV.diff: auth.kerbIV.diffmk
auth.kerbV.diff: auth.kerbV.diffmk
k5.exp.diff: k5.exp.diffmk
encrypt.diff: encrypt.diffmk
environ.diff: environ.diffmk

${DRAFTLIST} ${DIFFLIST}: rfc.macro

#
# This line should have a <CTRL>L in the substitution part
# of the "sed" command...
#
${DRAFTLIST}:
#	${NROFF} $@.nr | ${SED} 's/^ *@//' >$@

print: ${DRAFTLIST}
	lpr -h -P${PRINTER} ${DRAFTLIST}

2col: ${DRAFTLIST}
	${ENSCRIPT} -P${PRINTER} -2r ${EOPTS} ${DRAFTLIST}
