#
# This is the top level makefile for making GNO documentation. It can't
# be run under GNO itself yet, and probably never will be due to the
# dependancy on LaTeX.
#
# Devin Reade, 1997.
#
# $Id: Makefile,v 1.6 1997/12/06 07:02:52 gdr Exp $
#
# Set this to 'true' (without the quotes) for local links (used
# during editing).
DRAFT =
# This is the name and address that will be given as contact info
# at the bottom of each of the HTML pages. Do NOT use '<' or '>' in the
# address.
NAME = Devin Reade
ADDRESS = gdr@eddore.myrias.com
# Pathnames for various programs.
DVIPS = dvips
LATEX = latex
TEX2HTML = latex2html
MAKEINDEX = makeindex
# The names of the subdirs where we will collect html generated by
# latex(1), latex2html(1), and dvips(1).
DVID = dvid
HTMLD = htmld
PSD = psd
# The name of the manually-maintained index page in this directory
MINDEX = index.html
.IF $(DRAFT) == true
# This is the root of the html tree used in the generated sources.
HTML_ROOT = file:/home/gdr/src/gno/doc/refs/$(HTMLD)
# This is the directory where the remaining gifs may be found
GIFDIR = file:/home/gdr/graphics/
.ELSE
HTML_ROOT = http://trenco.myrias.com/~gno
GIFDIR = http://trenco.myrias.com/icons
.END
FTP_ROOT = ftp://trenco.myrias.com/pub/apple2/gs.specific/gno
# Where can the FAQ be located?
#FAQ = http://web.cs.ualberta.ca/~glyn/FAQ.csa2g
FAQ = http://trenco.myrias.com/~gno/FAQ.html
FAQLOG = http://trenco.myrias.com/~gno/FAQ-log.html
FAQ_TEXT = $(FTP_ROOT)/doc/faq/CURRENT
FAQLOG_TEXT = $(FTP_ROOT)/doc/faq/LOG
FTP_INTRO = $(FTP_ROOT)/doc/refs/intro
FTP_KERN = $(FTP_ROOT)/doc/refs/kern
FTP_GSH = $(FTP_ROOT)/doc/refs/gsh
# Where can the old v2.0.4 docs be found?
#OLD_HTML = http://web.cs.ualberta.ca/~glyn/GNOv2.0.4Docs
OLD_HTML = http://trenco.myrias.com/~gno/docs.Aug96
#########################################################
# You should not have to modify anything below this line.
#########################################################
# Format of the comment block for each html page.
CONTACT1 = '$(NAME)\
\
<$(ADDRESS)>
Last Updated: '
CONTACT2 = '
Document Version: '
# Some more programs and flags
GETDATE = ./getdate -date
GETVERS = ./getdate -version
DVIPS_FLAGS =
LATEX_FLAGS =
TEX2HTML_FLAGS = -info "" -local_icons -dir $(HTMLD) -up_url $(MINDEX)
TEXINPUTS = ':/usr/local/lib/latex2html'
DVI = intro.dvi kern.dvi
PS_LTR = intro.ltr.ps kern.ltr.ps
PS_A4 = intro.a4.ps kern.a4.ps
HTML = $(HTMLD)/intro.html $(HTMLD)/kern.html
.PRECIOUS: $(DVI)
MANORG = ../../usr.man
MANHTML = $(HTMLD)/man
MKSO = $(MANORG)/mkso.data
# Scratch files to clean up
MANUAL_GARBAGE = top.html
TEX_GARBAGE = *.err *.aux *.log *.dvi *.toc *.idx *.ilg *.ind
DVIPS_GARBAGE = *.ps *.djc
BIB_GARBAGE = *.blg *.bbl
UPLOADS = \
intro.dvi.Z intro.ltr.ps.Z intro.a4.ps.Z \
kern.dvi.Z kern.ltr.ps.Z kern.a4.ps.Z \
htmld.tar.gz
#
# targets
#
all: dvi ps h man
dvi: $(DVI)
ps: ps_ltr ps_a4
ps_ltr: $(PS_LTR)
ps_a4: $(PS_A4)
h: $(HTML) $(HTMLD)/index.html $(HTMLD)/unaval.html top.html cleanhtml
bib: intro.bbl
intro.bbl: gno.bib
bibtex intro
upload: all $(UPLOADS)
htmld.tar.gz: h
tar -cf - $(HTMLD) | gzip --best > $@
intro.dvi.Z: intro.dvi; compress -c $< > $@
intro.ltr.ps.Z: intro.ltr.ps; compress -c $< > $@
intro.a4.ps.Z: intro.a4.ps; compress -c $< > $@
kern.dvi.Z: kern.dvi; compress -c $< > $@
kern.ltr.ps.Z: kern.ltr.ps; compress -c $< > $@
kern.a4.ps.Z: kern.a4.ps; compress -c $< > $@
gsh.dvi.Z: gsh.dvi; compress -c $< > $@
gsh.ltr.ps.Z: gsh.ltr.ps; compress -c $< > $@
gsh.a4.ps.Z: gsh.a4.ps; compress -c $< > $@
$(HTMLD)/index.html: $(MINDEX)
@echo "making $@"; \
[ -d $(HTMLD) ] || mkdir -p $(HTMLD); \
perl -p -e 's,%%HTML_ROOT%%,$(HTML_ROOT),g;' \
-e 's,%%FTP_ROOT%%,$(FTP_ROOT),g;' \
-e 's,%%FTP_INTRO%%,$(FTP_INTRO),g;' \
-e 's,%%FTP_KERN%%,$(FTP_KERN),g;' \
-e 's,%%FTP_GSH%%,$(FTP_GSH),g;' \
-e 's,%%FAQ%%,$(FAQ),g;' \
-e 's,%%FAQLOG%%,$(FAQLOG),g;' \
-e 's,%%FAQ_TEXT%%,$(FAQ_TEXT),g;' \
-e 's,%%FAQLOG_TEXT%%,$(FAQLOG_TEXT),g;' \
-e 's,%%OLD_HTML%%,$(OLD_HTML),g;' \
-e 's,%%GIFDIR%%,$(GIFDIR),g;' \
< $< > $@
$(HTMLD)/unaval.html: unaval.html
cp $< $@
cleanhtml:
@echo "cleaning guano from html files"; \
perl -pi \
-e 's/NOWRAP//g;' \
-e '(//) && ($$cts=1);' \
-e '(//) && ($$cts=0);' \
-e '($$cts == 1) && (s/(
|