2011-03-04 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
[deliverable/binutils-gdb.git] / readline / doc / Makefile.in
CommitLineData
d60d9f65
SS
1# This makefile for Readline library documentation is in -*- text -*- mode.
2# Emacs likes it that way.
1b17e766 3
5bdf8622 4# Copyright (C) 1996-2004 Free Software Foundation, Inc.
1b17e766
EZ
5
6# This program is free software; you can redistribute it and/or modify
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation; either version 2, or (at your option)
9# any later version.
10
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15
16# You should have received a copy of the GNU General Public License
17# along with this program; if not, write to the Free Software
18# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 USA.
19
20topdir = @top_srcdir@
d60d9f65
SS
21srcdir = @srcdir@
22VPATH = .:@srcdir@
23
24prefix = @prefix@
96e946ca
RW
25
26datarootdir = @datarootdir@
27
d60d9f65
SS
28infodir = @infodir@
29
30mandir = @mandir@
1b17e766
EZ
31manpfx = man
32
9255ee31
EZ
33man1ext = .1
34man1dir = $(mandir)/$(manpfx)1
35man3ext = .3
36man3dir = $(mandir)/$(manpfx)3
37
38# set this to a value to have the HTML documentation installed
39htmldir =
40
41# Support an alternate destination root directory for package building
42DESTDIR =
d60d9f65 43
c862e87b 44SHELL = @MAKE_SHELL@
d60d9f65
SS
45RM = rm -f
46
1b17e766
EZ
47INSTALL = @INSTALL@
48INSTALL_DATA = @INSTALL_DATA@
49
50BUILD_DIR = @BUILD_DIR@
d60d9f65
SS
51TEXINPUTDIR = $(srcdir)
52
1b17e766 53MAKEINFO = LANGUAGE= makeinfo
d60d9f65
SS
54TEXI2DVI = $(srcdir)/texi2dvi
55TEXI2HTML = $(srcdir)/texi2html
56QUIETPS = #set this to -q to shut up dvips
1b17e766 57PAPERSIZE = letter
5bdf8622 58PSDPI = 600
1b17e766 59DVIPS = dvips -D ${PSDPI} $(QUIETPS) -t ${PAPERSIZE} -o $@ # tricky
d60d9f65 60
5bdf8622
DJ
61# These tools might not be available; they're not required
62DVIPDF = dvipdfm -o $@ -p ${PAPERSIZE}
63PSPDF = gs -sPAPERSIZE=${PAPERSIZE} -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -sOutputFile=$@
64
65RLSRC = $(srcdir)/rlman.texi $(srcdir)/rluser.texi \
66 $(srcdir)/rltech.texi $(srcdir)/version.texi \
67 $(srcdir)/rluserman.texi
68HISTSRC = $(srcdir)/history.texi $(srcdir)/hsuser.texi \
69 $(srcdir)/hstech.texi $(srcdir)/version.texi
d60d9f65
SS
70
71# This should be a program that converts troff to an ascii-readable format
72NROFF = groff -Tascii
73
74# This should be a program that converts troff to postscript
75GROFF = groff
76
1b17e766
EZ
77DVIOBJ = readline.dvi history.dvi rluserman.dvi
78INFOOBJ = readline.info history.info rluserman.info
9255ee31 79PSOBJ = readline.ps history.ps rluserman.ps readline_3.ps history_3.ps
1b17e766 80HTMLOBJ = readline.html history.html rluserman.html
9255ee31 81TEXTOBJ = readline.0 history.0
5bdf8622 82PDFOBJ = readline.pdf history.pdf rluserman.pdf
d60d9f65 83
5bdf8622 84INTERMEDIATE_OBJ = rlman.dvi
c862e87b 85
9255ee31 86DIST_DOCS = $(DVIOBJ) $(PSOBJ) $(HTMLOBJ) $(INFOOBJ) $(TEXTOBJ)
d60d9f65 87
5bdf8622 88.SUFFIXES: .0 .3 .ps .txt .dvi .html .pdf
d60d9f65
SS
89
90.3.0:
91 $(RM) $@
92 -${NROFF} -man $< > $@
93
5bdf8622
DJ
94.ps.pdf:
95 $(RM) $@
96 -${PSPDF} $<
97
98.dvi.pdf:
99 $(RM) $@
100 -${DVIPDF} $<
101
d60d9f65
SS
102all: info dvi html ps text
103nodvi: info html text
104
5bdf8622
DJ
105info: $(INFOOBJ)
106dvi: $(DVIOBJ)
107ps: $(PSOBJ)
108html: $(HTMLOBJ)
109text: $(TEXTOBJ)
110pdf: $(PDFOBJ)
111
d60d9f65 112readline.dvi: $(RLSRC)
5bdf8622 113 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/rlman.texi
d60d9f65
SS
114 mv rlman.dvi readline.dvi
115
116readline.info: $(RLSRC)
5bdf8622 117 $(MAKEINFO) --no-split -I $(TEXINPUTDIR) -o $@ $(srcdir)/rlman.texi
d60d9f65 118
1b17e766 119rluserman.dvi: $(RLSRC)
5bdf8622 120 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/rluserman.texi
1b17e766
EZ
121
122rluserman.info: $(RLSRC)
5bdf8622 123 $(MAKEINFO) --no-split -I $(TEXINPUTDIR) -o $@ $(srcdir)/rluserman.texi
1b17e766 124
d60d9f65 125history.dvi: ${HISTSRC}
5bdf8622 126 TEXINPUTS=.:$(TEXINPUTDIR):$$TEXINPUTS $(TEXI2DVI) $(srcdir)/history.texi
d60d9f65
SS
127
128history.info: ${HISTSRC}
5bdf8622 129 $(MAKEINFO) --no-split -I $(TEXINPUTDIR) -o $@ $(srcdir)/history.texi
d60d9f65
SS
130
131readline.ps: readline.dvi
132 $(RM) $@
133 $(DVIPS) readline.dvi
134
1b17e766
EZ
135rluserman.ps: rluserman.dvi
136 $(RM) $@
137 $(DVIPS) rluserman.dvi
138
d60d9f65
SS
139history.ps: history.dvi
140 $(RM) $@
141 $(DVIPS) history.dvi
142
9255ee31
EZ
143#
144# This leaves readline.html and rlman.html -- rlman.html is for www.gnu.org
145#
d60d9f65 146readline.html: ${RLSRC}
5bdf8622 147 $(TEXI2HTML) -menu -monolithic -I $(TEXINPUTDIR) $(srcdir)/rlman.texi
1b17e766 148 sed -e 's:rlman.html:readline.html:g' rlman.html > readline.html
5bdf8622 149 $(RM) rlman.html
d60d9f65 150
1b17e766 151rluserman.html: ${RLSRC}
5bdf8622 152 $(TEXI2HTML) -menu -monolithic -I $(TEXINPUTDIR) $(srcdir)/rluserman.texi
1b17e766 153
d60d9f65 154history.html: ${HISTSRC}
5bdf8622 155 $(TEXI2HTML) -menu -monolithic -I $(TEXINPUTDIR) $(srcdir)/history.texi
d60d9f65
SS
156
157readline.0: readline.3
158
9255ee31
EZ
159readline_3.ps: readline.3
160 ${RM} $@
161 ${GROFF} -man < $(srcdir)/readline.3 > $@
162
163history.0: history.3
164
165history_3.ps: history.3
166 ${RM} $@
167 ${GROFF} -man < $(srcdir)/history.3 > $@
168
5bdf8622
DJ
169readline.pdf: readline.dvi
170history.pdf: history.dvi
171rluserman.pdf: rluserman.dvi
172
d60d9f65 173clean:
5bdf8622
DJ
174 $(RM) *.aux *.bak *.cp *.fn *.ky *.log *.pg *.toc *.tp *.vr *.cps \
175 *.pgs *.bt *.bts *.rw *.rws *.fns *.kys *.tps *.vrs *.o \
176 core *.core
9255ee31
EZ
177
178mostlyclean: clean
d60d9f65 179
9255ee31 180distclean: clean maybe-clean
c862e87b 181 $(RM) $(INTERMEDIATE_OBJ)
d60d9f65
SS
182 $(RM) Makefile
183
9255ee31
EZ
184maybe-clean:
185 -if test "X$(topdir)" != "X$(BUILD_DIR)"; then \
186 $(RM) $(DIST_DOCS); \
187 fi
d60d9f65
SS
188
189maintainer-clean: clean
9255ee31 190 $(RM) $(DIST_DOCS)
c862e87b 191 $(RM) $(INTERMEDIATE_OBJ)
5bdf8622 192 $(RM) $(PDFOBJ)
d60d9f65
SS
193 $(RM) Makefile
194
1b17e766 195installdirs: $(topdir)/support/mkdirs
9255ee31
EZ
196 -$(SHELL) $(topdir)/support/mkdirs $(DESTDIR)$(infodir) $(DESTDIR)$(man3dir)
197 -if test -n "${htmldir}" ; then \
198 $(SHELL) $(topdir)/support/mkdirs $(DESTDIR)$(htmldir) ; \
199 fi
d60d9f65 200
c862e87b 201install: installdirs
d60d9f65 202 if test -f readline.info; then \
9255ee31 203 ${INSTALL_DATA} readline.info $(DESTDIR)$(infodir)/readline.info; \
d60d9f65 204 else \
9255ee31 205 ${INSTALL_DATA} $(srcdir)/readline.info $(DESTDIR)$(infodir)/readline.info; \
d60d9f65 206 fi
1b17e766 207 if test -f rluserman.info; then \
9255ee31 208 ${INSTALL_DATA} rluserman.info $(DESTDIR)$(infodir)/rluserman.info; \
1b17e766 209 else \
9255ee31 210 ${INSTALL_DATA} $(srcdir)/rluserman.info $(DESTDIR)$(infodir)/rluserman.info; \
1b17e766 211 fi
d60d9f65 212 if test -f history.info; then \
9255ee31 213 ${INSTALL_DATA} history.info $(DESTDIR)$(infodir)/history.info; \
d60d9f65 214 else \
9255ee31 215 ${INSTALL_DATA} $(srcdir)/history.info $(DESTDIR)$(infodir)/history.info; \
d60d9f65 216 fi
1b17e766 217 -if $(SHELL) -c 'install-info --version' >/dev/null 2>&1; then \
9255ee31
EZ
218 install-info --dir-file=$(DESTDIR)$(infodir)/dir \
219 $(DESTDIR)$(infodir)/readline.info ; \
220 install-info --dir-file=$(DESTDIR)$(infodir)/dir \
221 $(DESTDIR)$(infodir)/history.info ; \
222 install-info --dir-file=$(DESTDIR)$(infodir)/dir \
223 $(DESTDIR)$(infodir)/rluserman.info ; \
d60d9f65 224 else true; fi
9255ee31
EZ
225 -${INSTALL_DATA} $(srcdir)/readline.3 $(DESTDIR)$(man3dir)/readline$(man3ext)
226 -${INSTALL_DATA} $(srcdir)/history.3 $(DESTDIR)$(man3dir)/history$(man3ext)
227 -if test -n "${htmldir}" ; then \
228 if test -f readline.html; then \
229 ${INSTALL_DATA} readline.html $(DESTDIR)$(htmldir)/readline.html; \
230 else \
231 ${INSTALL_DATA} $(srcdir)/readline.html $(DESTDIR)$(htmldir)/readline.html; \
232 fi ; \
233 if test -f history.html; then \
234 ${INSTALL_DATA} history.html $(DESTDIR)$(htmldir)/history.html; \
235 else \
236 ${INSTALL_DATA} $(srcdir)/history.html $(DESTDIR)$(htmldir)/history.html; \
237 fi ; \
238 if test -f rluserman.html; then \
239 ${INSTALL_DATA} rluserman.html $(DESTDIR)$(htmldir)/rluserman.html; \
240 else \
241 ${INSTALL_DATA} $(srcdir)/rluserman.html $(DESTDIR)$(htmldir)/rluserman.html; \
242 fi ; \
243 fi
d60d9f65
SS
244
245uninstall:
9255ee31
EZ
246 $(RM) $(DESTDIR)$(infodir)/readline.info
247 $(RM) $(DESTDIR)$(infodir)/rluserman.info
248 $(RM) $(DESTDIR)$(infodir)/history.info
249 $(RM) $(DESTDIR)$(man3dir)/readline$(man3ext)
250 $(RM) $(DESTDIR)$(man3dir)/history$(man3ext)
251 -if test -n "${htmldir}" ; then \
252 $(RM) $(DESTDIR)$(htmldir)/readline.html ; \
253 $(RM) $(DESTDIR)$(htmldir)/rluserman.html ; \
254 $(RM) $(DESTDIR)$(htmldir)/history.html ; \
255 fi
This page took 0.471621 seconds and 4 git commands to generate.