#
#  The makefile builds a postcript version of the snacc manual
#  and stores it in file "snacc.ps"
#
#  MS 92
#  use nroff -man snacc.1  to see what the man page, snacc.1, looks like
#
#  if latex bombs unexplainably, try 'make clean' followed by 'make'
#


LATEX = latex
BIBTEX = bibtex
DVIPS = dvips
DETEX = detex2
TEX_SRC = snacc

doc: $(TEX_SRC).tex
	$(LATEX)  $(TEX_SRC)
	$(BIBTEX) $(TEX_SRC)
	$(LATEX)  $(TEX_SRC)
	$(LATEX)  $(TEX_SRC)
	$(DVIPS) $(TEX_SRC).dvi > $(TEX_SRC).ps
	ghostview $(TEX_SRC).ps 

sp:  $(TEX_SRC).tex
	$(DETEX)  $(TEX_SRC).tex | spell > sp_errs 

# keep the .ps version for simplicity
clean:
	rm -f *~ *.dvi *.log *.aux *.toc *.lof *.lot *.bbl *.blg sp_errs
