]> git.ipfire.org Git - thirdparty/bash.git/blame - doc/Makefile.in
Imported from ../bash-2.04.tar.gz.
[thirdparty/bash.git] / doc / Makefile.in
CommitLineData
ccc6cda3 1# This Makefile is for the Bash/documentation directory -*- text -*-.
bb70624e
JA
2#
3# Copyright (C) 1996 Free Software Foundation, Inc.
4
5# This program is free software; you can redistribute it and/or modify
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation; either version 2, or (at your option)
8# any later version.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU General Public License for more details.
14
15# You should have received a copy of the GNU General Public License
16# along with this program; if not, write to the Free Software
17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 USA.
18
ccc6cda3 19#
b72432fd 20SHELL = @MAKE_SHELL@
ccc6cda3
JA
21RM = rm -f
22
23topdir = @top_srcdir@
24srcdir = @srcdir@
25VPATH = .:@srcdir@
26
bb70624e
JA
27prefix = @prefix@
28exec_prefix = @exec_prefix@
29
ccc6cda3
JA
30infodir = @infodir@
31
bb70624e
JA
32# set this to a directory name to have the HTML files installed
33htmldir = @htmldir@
34
ccc6cda3
JA
35mandir = @mandir@
36manpfx = man
37
38man1ext = 1
39man1dir = $(mandir)/$(manpfx)$(man1ext)
40man3ext = 3
41man3dir = $(mandir)/$(manpfx)$(man3ext)
42
43INSTALL = @INSTALL@
44INSTALL_DATA = @INSTALL_DATA@
45BUILD_DIR = @BUILD_DIR@
46
47# bad style
48RL_LIBDIR = $(topdir)/lib/readline
49
50# unused
51TEXINDEX = texindex
52TEX = tex
53
54MAKEINFO = makeinfo
55TEXI2DVI = ${topdir}/support/texi2dvi
56TEXI2HTML = ${topdir}/support/texi2html
cce855bc
JA
57MAN2HTML = ${BUILD_DIR}/support/man2html
58HTMLPOST = ${srcdir}/htmlpost.sh
ccc6cda3 59QUIETPS = #set this to -q to shut up dvips
bb70624e
JA
60PAPERSIZE = letter # change to a4 for A4-size paper
61PSDPI = 300 # could be 600 if you like
62DVIPS = dvips -D ${PSDPI} $(QUIETPS) -t ${PAPERSIZE} -o $@ # tricky
ccc6cda3
JA
63TEXINPUTDIR = $(RL_LIBDIR)/doc
64
65MKDIRS = ${topdir}/support/mkdirs
66
67# This should be a program that converts troff to an ascii-readable format
68NROFF = groff -Tascii
69
70# This should be a program that converts troff to postscript
71GROFF = groff
72
73HSUSER = $(RL_LIBDIR)/doc/hsuser.texinfo
74RLUSER = $(RL_LIBDIR)/doc/rluser.texinfo
75
cce855bc 76.SUFFIXES: .0 .1 .3 .ms .ps .txt .dvi .html
ccc6cda3
JA
77
78.1.ps:
79 $(RM) $@
80 -${GROFF} -man $< > $@
81
82.1.0:
83 $(RM) $@
84 -${NROFF} -man $< > $@
85
cce855bc
JA
86.1.html:
87 $(RM) $@
88 -${MAN2HTML} $< | ${HTMLPOST} > $@
89
ccc6cda3
JA
90.ms.ps:
91 $(RM) $@
92 -${GROFF} -ms $< > $@
93
94.ms.txt:
95 $(RM) $@
96 -${NROFF} -ms $< > $@
97
98.3.ps:
99 $(RM) $@
100 -${GROFF} -man $< > $@
101
102.3.0:
103 $(RM) $@
104 -${NROFF} -man $< > $@
105
cce855bc
JA
106.3.html:
107 $(RM) $@
108 -${MAN2HTML} $< > $@
109
ccc6cda3
JA
110all: ps info dvi text html
111nodvi: ps info text html
112
bb70624e 113PSFILES = bash.ps bashbug.ps readline.ps article.ps builtins.ps rbash.ps
b72432fd
JA
114DVIFILES = bashref.dvi bashref.ps
115INFOFILES = bashref.info
bb70624e 116MAN0FILES = bash.0 bashbug.0 builtins.0 rbash.0 readline.0
b72432fd
JA
117HTMLFILES = bashref.html bash.html
118
119ps: ${PSFILES}
120dvi: ${DVIFILES}
121info: ${INFOFILES}
122text: ${MAN0FILES}
123html: ${HTMLFILES}
ccc6cda3
JA
124
125bashref.dvi: $(srcdir)/bashref.texi $(HSUSER) $(RLUSER)
126 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/bashref.texi
127
128bashref.ps: bashref.dvi
129 $(RM) $@
130 $(DVIPS) bashref.dvi
131
132bashref.info: $(srcdir)/bashref.texi $(HSUSER) $(RLUSER)
133 $(MAKEINFO) --no-split -I$(TEXINPUTDIR) $(srcdir)/bashref.texi
134
135bashref.html: bashref.texi $(HSUSER) $(RLUSER)
b72432fd 136 $(TEXI2HTML) -menu -monolithic -I $(TEXINPUTDIR) $(srcdir)/bashref.texi
ccc6cda3 137
bb70624e
JA
138new-bashref.dvi: $(srcdir)/new-bashref.texi $(HSUSER) $(RLUSER)
139 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/new-bashref.texi
140
141new-bashref.ps: new-bashref.dvi
142 $(RM) $@
143 $(DVIPS) new-bashref.dvi
144
145new-bashref.info: $(srcdir)/new-bashref.texi $(HSUSER) $(RLUSER)
146 $(MAKEINFO) --no-split -I$(TEXINPUTDIR) $(srcdir)/new-bashref.texi
147
ccc6cda3
JA
148bash.dvi: bash.texinfo $(HSUSER) $(RLUSER)
149 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) bash.texinfo
150
151bashman.ps: bash.dvi
152 $(RM) $@
153 $(DVIPS) bash.dvi
154
155bash.txt: bash.1
156bash.ps: bash.1
cce855bc 157bash.html: bash.1 $(MAN2HTML)
ccc6cda3
JA
158bashbug.ps: bashbug.1
159builtins.ps: builtins.1 bash.1
bb70624e 160rbash.ps: rbash.1 bash.1
ccc6cda3
JA
161bash.0: bash.1
162bashbug.0: bashbug.1
163builtins.0: builtins.1 bash.1
bb70624e 164rbash.0: rbash.1 bash.1
ccc6cda3
JA
165readline.0: readline.3
166readline.ps: readline.3
167article.ps: article.ms
168
cce855bc
JA
169$(MAN2HTML): ${topdir}/support/man2html.c
170 -( cd ${BUILD_DIR}/support ; ${MAKE} ${MFLAGS} man2html)
171
b72432fd
JA
172CREATED_FAQ = faq.news faq.news2 faq.mail faq.version
173
174faq: ${CREATED_FAQ}
ccc6cda3
JA
175
176faq.version: FAQ.version FAQ
177 sh mkfaqvers FAQ.version > $@
178
bb70624e
JA
179faq.headers.mail: FAQ.headers.mail FAQ
180 sh mkfaqvers FAQ.headers.mail > $@
181
182faq.headers.news: FAQ.headers.news FAQ
183 sh mkfaqvers FAQ.headers.news > $@
184
185faq.headers.news2: FAQ.headers.news2 FAQ
186 sh mkfaqvers FAQ.headers.news2 > $@
187
188faq.news: FAQ faq.headers.news faq.version
ccc6cda3 189 $(RM) $@
bb70624e 190 cat faq.headers.news faq.version FAQ > $@
ccc6cda3 191
bb70624e 192faq.news2: FAQ faq.headers.news2 faq.version
ccc6cda3 193 $(RM) $@
bb70624e 194 cat faq.headers.news2 faq.version FAQ > $@
ccc6cda3 195
bb70624e 196faq.mail: FAQ faq.headers.mail faq.version
ccc6cda3 197 $(RM) $@
bb70624e 198 cat faq.headers.mail faq.version FAQ > $@
ccc6cda3
JA
199
200clean:
b72432fd
JA
201 $(RM) *.aux *.bak *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps \
202 *.pgs *.bt *.bts *.rw *.rws *.fns *.kys *.tps *.vrs *.o
203 ${RM} core *.core
ccc6cda3
JA
204
205distclean mostlyclean: clean
206 $(RM) Makefile
207
208maintainer-clean: clean
b72432fd
JA
209 ${RM} ${PSFILES} ${DVIFILES} ${INFOFILES} ${MAN0FILES} ${HTMLFILES}
210 ${RM} ${CREATED_FAQ}
ccc6cda3
JA
211 $(RM) Makefile
212
213installdirs:
214 -test -d $(man1dir) || $(SHELL) ${MKDIRS} $(man1dir)
e8ce775d
JA
215# uncomment the next line to create the directory for the readline man page
216# -test -d $(man3dir) || $(SHELL) ${MKDIRS} $(man3dir)
ccc6cda3 217 -test -d $(infodir) || $(SHELL) ${MKDIRS} $(infodir)
bb70624e
JA
218 -if [ -n "$(htmldir)" ]; then \
219 test -d $(htmldir) || $(SHELL) ${MKDIRS} $(htmldir) ; \
220 fi
ccc6cda3
JA
221
222install: info installdirs
223 -$(INSTALL_DATA) $(srcdir)/bash.1 $(man1dir)/bash.${man1ext}
224 -$(INSTALL_DATA) $(srcdir)/bashbug.1 $(man1dir)/bashbug.${man1ext}
d166f048
JA
225# uncomment the next line to install the readline man page
226# -$(INSTALL_DATA) $(srcdir)/readline.3 $(man3dir)/readline.${man3ext}
ccc6cda3 227# uncomment the next line to install the builtins man page
b72432fd 228# $(INSTALL_DATA) $(srcdir)/builtins.1 $(man1dir)/bash_builtins.${man1ext}
d166f048
JA
229 -$(INSTALL_DATA) $(srcdir)/bashref.info $(infodir)/bash.info
230# run install-info if it is present to update the info directory
231 if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
232 install-info --dir-file=$(infodir)/dir $(infodir)/bash.info; \
233 else true; fi
bb70624e
JA
234# if htmldir is set, install the html files into that directory
235 -if [ -n "${htmldir}" ]; then \
236 $(INSTALL_DATA) $(srcdir)/bash.html $(htmldir) ; \
237 $(INSTALL_DATA) $(srcdir)/bashref.html $(htmldir) ; \
238 fi
ccc6cda3
JA
239
240uninstall:
d166f048
JA
241 -$(RM) $(man1dir)/bash.${man1ext} $(man1dir)/bashbug.${man1ext}
242 -$(RM) $(man3dir)/readline.${man3ext}
243 $(RM) $(infodir)/bash.info
bb70624e
JA
244 -if [ -n "$(htmldir)" ]; then \
245 $(RM) $(htmldir)/bash.html ; \
246 $(RM) $(htmldir)/bashref.html ; \
247 fi
ccc6cda3
JA
248
249# for use by chet
250inst: bashref.texi
251 $(SHELL) ./mkinstall
252 cmp -s INSTALL ../INSTALL || mv INSTALL ../INSTALL
253 $(RM) INSTALL
254
255posix: bashref.texi
256 $(SHELL) ./mkposix
257 cmp -s POSIX.NOTES ../CWRU/POSIX.NOTES || mv POSIX.NOTES ../CWRU/POSIX.NOTES
258 $(RM) POSIX.NOTES