2 # $Id: makefile.dst,v 1.2 2000/01/22 16:40:27 lhecking Exp $
5 # Makefile for GNUPLOT documentation
7 # Note that the top-level file for documentation is gnuplot.doc.
11 # make gnuplot.dvi (for latex)
12 # (print or view gnuplot.dvi)
14 # make gnuplot.nroff (for nroff)
15 # (print or view gnuplot.nroff)
17 # make "TROFF=itroff" troff (for troff; use your troff here)
19 # usually overridden by ../Makefile
20 HELPDEST = /usr/local/lib
22 # substitute your troff command (and any flags) for this one
25 # substitute cp if you do not have the install program
28 # substitute your DVI to PostScript conversion program here
34 # -traditional -g -O if gcc (set 'CC = gcc')
35 # no extra flags for BSD
36 # HBB: this gets called from the toplevel Makefile, and gets passed some CFLAGS,
37 # so I changed this to something completely different:
38 DOC_CFLAGS = $(CFLAGS) -s -I../ -I../term/
43 @echo "Please do a 'make <TARGET>' where <TARGET> is one of" \
46 @echo "check check the gnuplot.doc file"
47 @echo "clean remove all derived files"
48 @echo "dvi DVI files (gnuplot.dvi gpcard.dvi)"
49 @echo "gih Unix and MSDOS help file (gnuplot.gih)"
50 @echo "help make help"
51 @echo "hlp VMS help file (gnuplot.hlp)"
52 @echo "html HyperText Markup language (gnuplot.html)"
53 @echo "info Info documentation (gnuplot.info)"
54 @echo "install-unix Unix and MSDOS install"
55 @echo "install-vms VMS install"
56 @echo "nroff nroff documentation (gnuplot.nroff)"
57 @echo "ps PostScript files (gnuplot.ps gpcard.ps)"
58 @echo "tex LaTeX documentation (gnuplot.tex)"
59 @echo "troff troff documentation"
60 @echo "tutorial LaTeX tutorial (latextut/tutorial.dvi)"
62 @echo "If you are not familiar with makefiles or just want" \
64 @echo "'make <TARGET>' would do without actually doing" \
66 @echo " 'make -n <TARGET>'"
69 # default is what is needed for interactive gnuplot
70 default: gnuplot.hlp gnuplot.gih
75 doc2html : doc2html.c termdoc.c xref.c allterm.h
76 $(CC) $(DOC_CFLAGS) -o doc2html doc2html.c termdoc.c xref.c
78 doc2ms: doc2ms.c termdoc.c allterm.h
79 $(CC) $(DOC_CFLAGS) -DALL_TERM_DOC -o doc2ms doc2ms.c termdoc.c
81 doc2tex: doc2tex.c termdoc.c allterm.h
82 $(CC) $(DOC_CFLAGS) -DALL_TERM_DOC -o doc2tex doc2tex.c termdoc.c
84 doc2hlp: doc2hlp.c termdoc.c
85 $(CC) $(DOC_CFLAGS) -o doc2hlp doc2hlp.c termdoc.c
87 doc2gih: doc2gih.c termdoc.c
88 $(CC) $(DOC_CFLAGS) -o doc2gih doc2gih.c termdoc.c
90 checkdoc: checkdoc.c termdoc.c allterm.h
91 $(CC) $(DOC_CFLAGS) -DALL_TERM_DOC -o checkdoc checkdoc.c termdoc.c
95 @echo Hmm - need to concatenate all .trm files into allterm.h
96 @echo should have been done by main makefile
98 ### [tn]roff documentation
99 troff: gnuplot.ms titlepag.ms
100 tbl gnuplot.ms | eqn | $(TROFF) -ms
104 gnuplot.nroff: gnuplot.ms titlepag.ms
105 tbl gnuplot.ms | neqn | nroff -ms | col > gnuplot.nroff
111 gnuplot.ms: doc2ms gnuplot.doc
112 ./doc2ms gnuplot.doc gnuplot.ms
118 gnuplot.html : doc2html gnuplot.doc allterm.h
119 ./doc2html gnuplot.doc gnuplot.html
122 ### LaTeX documentation
126 gnuplot.tex: doc2tex gnuplot.doc
127 ./doc2tex gnuplot.doc gnuplot.tex
130 # this is how to make DVI files
131 dvi: gnuplot.dvi gpcard.dvi
133 gnuplot.dvi: gnuplot.tex titlepag.tex toc_entr.sty
137 gpcard.dvi: gpcard.tex
140 # this is how to make PostScript files
141 # if pslatex has been installed, add "times" to titlepage.tex
142 ps: gnuplot.ps gpcard.ps
144 gnuplot.ps: gnuplot.dvi
147 gpcard.ps: gpcard.dvi
151 # this is how to make gnuplot.hlp
155 gnuplot.hlp: doc2hlp gnuplot.doc
156 ./doc2hlp gnuplot.doc gnuplot.hlp
159 # this is how to make gnuplot.gih
162 gnuplot.gih: doc2gih gnuplot.doc
163 ./doc2gih gnuplot.doc gnuplot.gih
166 # this is how to make Info documentation
169 gnuplot.info: gnuplot.doc
170 perl doc2texi.pl gnuplot.doc > gpltinfo.tex
171 makeinfo +fill-column 80 gpltinfo.tex
174 tutorial: latextut/tutorial.tex
175 ( cd latextut; $(MAKE) )
177 # this is how to check the gnuplot.doc file
178 check: checkdoc gnuplot.doc
179 ./checkdoc < gnuplot.doc
182 # For Unix and MSDOS only
183 install-unix: gnuplot.gih
184 $(INSTALL) gnuplot.gih $(HELPDEST)
187 install-vms: gnuplot.hlp
188 $(INSTALL) gnuplot.hlp $(HELPDEST)
190 # remove all derived files
192 rm -f doc2ms gnuplot.nroff gnuplot.ms \
194 doc2html gnuplot.html \
195 doc2tex gnuplot.tex gnuplot.dvi \
196 gnuplot.aux gnuplot.log gnuplot.toc \
197 gnuplot.ps gpcard.dvi gpcard.log gpcard.ps \
198 doc2hlp gnuplot.hlp \
199 doc2gih gnuplot.gih \
200 checkdoc *~ *.o core a.out \
201 gnuplot.info* gpltinfo.tex
202 ( cd latextut; $(MAKE) clean )