Fix last change of grow_mini_window.
[bpt/emacs.git] / doc / emacs / Makefile.in
CommitLineData
bbece175 1### @configure_input@
8cf51b2c 2
ab422c4d 3# Copyright (C) 1994, 1996-2013 Free Software Foundation, Inc.
8cf51b2c
GM
4
5# This file is part of GNU Emacs.
6
352c8b4a 7# GNU Emacs is free software: you can redistribute it and/or modify
8cf51b2c 8# it under the terms of the GNU General Public License as published by
352c8b4a
GM
9# the Free Software Foundation, either version 3 of the License, or
10# (at your option) any later version.
8cf51b2c
GM
11
12# GNU Emacs is distributed in the hope that it will be useful,
13# but WITHOUT ANY WARRANTY; without even the implied warranty of
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15# GNU General Public License for more details.
16
17# You should have received a copy of the GNU General Public License
352c8b4a
GM
18# along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
19
50b13cde 20SHELL = @SHELL@
8cf51b2c 21
789cf833
GM
22# NB If you add any more configure variables,
23# update the sed rules in the dist target below.
24
4c83f6e1
GM
25# Where to find the source code. $(srcdir) will be the doc/emacs subdirectory
26# of the source tree. This is set by configure's `--srcdir' option.
8cf51b2c 27srcdir=@srcdir@
8cf51b2c 28
17ca7950
GM
29# Only for make dist.
30version=@version@
31
df42eec6
GM
32## Where the output files go.
33## Note that the setfilename command in the .texi files assumes this.
ea274122
GM
34## This is a bit funny. Because the info files are in the
35## distribution tarfiles, they are always made in $scrdir/../../info,
c1dc72b3 36## even for out-of-tree builds.
2fecccba 37buildinfodir = $(srcdir)/../../info
2358ae54
GM
38# Directory with the (customized) texinfo.tex file.
39texinfodir = $(srcdir)/../misc
8cf51b2c 40
8496d8d7
GM
41prefix = @prefix@
42datarootdir = @datarootdir@
43datadir = @datadir@
44PACKAGE_TARNAME = @PACKAGE_TARNAME@
45docdir = @docdir@
46dvidir = @dvidir@
47htmldir = @htmldir@
48pdfdir = @pdfdir@
49psdir = @psdir@
50
3fe7cdc8
GM
51MKDIR_P = @MKDIR_P@
52
8496d8d7
GM
53GZIP_PROG = @GZIP_PROG@
54
55HTML_OPTS = --no-split --html
56
8045b906
GM
57INFO_EXT=@INFO_EXT@
58# Options used only when making info output.
59# --no-split is only needed because of MS-DOS.
60# For a possible alternative, see
61# http://lists.gnu.org/archive/html/emacs-devel/2011-01/msg01182.html
62INFO_OPTS=@INFO_OPTS@
63
8496d8d7
GM
64INSTALL = @INSTALL@
65INSTALL_DATA = @INSTALL_DATA@
66
8cf51b2c
GM
67# The makeinfo program is part of the Texinfo distribution.
68# Use --force so that it generates output even if there are errors.
45eb2a5d 69MAKEINFO = @MAKEINFO@
6446548e 70MAKEINFO_OPTS = --force --enable-encoding -I $(srcdir)
df42eec6 71
df42eec6 72TEXI2DVI = texi2dvi
703d26ba 73TEXI2PDF = texi2pdf
c12e4a81 74DVIPS = dvips
8cf51b2c 75
8cf51b2c 76
45eb2a5d
WL
77ENVADD = TEXINPUTS="$(srcdir):$(texinfodir):$(TEXINPUTS)" \
78 MAKEINFO="$(MAKEINFO) $(MAKEINFO_OPTS)"
8cf51b2c 79
8496d8d7
GM
80DVI_TARGETS = emacs.dvi emacs-xtra.dvi
81HTML_TARGETS = emacs.html
82PDF_TARGETS = emacs.pdf emacs-xtra.pdf
83PS_TARGETS = emacs.ps emacs-xtra.ps
df42eec6 84
4c83f6e1
GM
85EMACS_XTRA= \
86 ${srcdir}/emacs-xtra.texi \
8cf51b2c
GM
87 $(srcdir)/arevert-xtra.texi \
88 $(srcdir)/cal-xtra.texi \
89 $(srcdir)/dired-xtra.texi \
90 $(srcdir)/picture-xtra.texi \
91 $(srcdir)/emerge-xtra.texi \
92 $(srcdir)/vc-xtra.texi \
93 $(srcdir)/vc1-xtra.texi \
8cf51b2c
GM
94 $(srcdir)/fortran-xtra.texi \
95 $(srcdir)/msdog-xtra.texi
96
97EMACSSOURCES= \
98 ${srcdir}/emacs.texi \
eef3ab94 99 ${srcdir}/emacsver.texi \
8cf51b2c
GM
100 ${srcdir}/doclicense.texi \
101 ${srcdir}/gpl.texi \
102 ${srcdir}/screen.texi \
103 ${srcdir}/commands.texi \
104 ${srcdir}/entering.texi \
105 ${srcdir}/basic.texi \
106 ${srcdir}/mini.texi \
107 ${srcdir}/m-x.texi \
108 ${srcdir}/help.texi \
109 ${srcdir}/mark.texi \
110 ${srcdir}/killing.texi \
111 ${srcdir}/regs.texi \
112 ${srcdir}/display.texi \
113 ${srcdir}/search.texi \
114 ${srcdir}/fixit.texi \
115 ${srcdir}/files.texi \
116 ${srcdir}/buffers.texi \
117 ${srcdir}/windows.texi \
118 ${srcdir}/frames.texi \
119 ${srcdir}/mule.texi \
8875da1e 120 ${srcdir}/modes.texi \
8cf51b2c
GM
121 ${srcdir}/indent.texi \
122 ${srcdir}/text.texi \
123 ${srcdir}/programs.texi \
124 ${srcdir}/building.texi \
125 ${srcdir}/maintaining.texi \
126 ${srcdir}/abbrevs.texi \
127 ${srcdir}/sending.texi \
128 ${srcdir}/rmail.texi \
129 ${srcdir}/dired.texi \
130 ${srcdir}/calendar.texi \
131 ${srcdir}/misc.texi \
d43f5a42 132 ${srcdir}/package.texi \
8cf51b2c
GM
133 ${srcdir}/custom.texi \
134 ${srcdir}/trouble.texi \
135 ${srcdir}/cmdargs.texi \
136 ${srcdir}/xresources.texi \
137 ${srcdir}/anti.texi \
138 ${srcdir}/macos.texi \
139 ${srcdir}/msdog.texi \
140 ${srcdir}/gnu.texi \
141 ${srcdir}/glossary.texi \
142 ${srcdir}/ack.texi \
143 ${srcdir}/kmacro.texi \
144 $(EMACS_XTRA)
145
62bd73fa 146## The info/ directory exists in release tarfiles but not the repository.
ac1a0ce1 147mkinfodir = @${MKDIR_P} ${buildinfodir}
abd40fb4 148
234db610 149.PHONY: info dvi html pdf ps
ea274122 150
8496d8d7
GM
151.SUFFIXES: .ps .dvi
152
153.dvi.ps:
154 $(DVIPS) -o $@ $<
155
ac1a0ce1 156info: $(buildinfodir)/emacs$(INFO_EXT)
8496d8d7
GM
157dvi: $(DVI_TARGETS)
158html: $(HTML_TARGETS)
159pdf: $(PDF_TARGETS)
160ps: $(PS_TARGETS)
8cf51b2c 161
0264072d
GM
162# Note that all the Info targets build the Info files in srcdir.
163# There is no provision for Info files to exist in the build directory.
8cf51b2c 164# In a distribution of Emacs, the Info files should be up to date.
f48a9cb4 165# Note: "<" is not portable in ordinary make rules.
ac1a0ce1 166$(buildinfodir)/emacs$(INFO_EXT): ${EMACSSOURCES}
abd40fb4 167 $(mkinfodir)
8045b906 168 $(MAKEINFO) $(MAKEINFO_OPTS) $(INFO_OPTS) -o $@ ${srcdir}/emacs.texi
8cf51b2c
GM
169
170emacs.dvi: ${EMACSSOURCES}
f48a9cb4 171 $(ENVADD) $(TEXI2DVI) ${srcdir}/emacs.texi
8cf51b2c 172
703d26ba 173emacs.pdf: ${EMACSSOURCES}
f48a9cb4 174 $(ENVADD) $(TEXI2PDF) ${srcdir}/emacs.texi
703d26ba 175
234db610 176emacs.html: ${EMACSSOURCES}
8496d8d7 177 $(MAKEINFO) $(MAKEINFO_OPTS) $(HTML_OPTS) -o $@ ${srcdir}/emacs.texi
8cf51b2c 178
4c83f6e1 179emacs-xtra.dvi: $(EMACS_XTRA)
f48a9cb4 180 $(ENVADD) $(TEXI2DVI) ${srcdir}/emacs-xtra.texi
8cf51b2c 181
4c83f6e1 182emacs-xtra.pdf: $(EMACS_XTRA)
f48a9cb4 183 $(ENVADD) $(TEXI2PDF) ${srcdir}/emacs-xtra.texi
703d26ba 184
4c83f6e1 185.PHONY: mostlyclean clean distclean maintainer-clean infoclean
8cf51b2c 186
4c83f6e1 187## Temp files.
8cf51b2c 188mostlyclean:
4c83f6e1
GM
189 rm -f *.aux *.log *.toc *.cp *.cps *.fn *.fns *.ky *.kys \
190 *.op *.ops *.pg *.pgs *.tp *.tps *.vr *.vrs
8cf51b2c 191
4c83f6e1 192## Products not in the release tarfiles.
8cf51b2c 193clean: mostlyclean
8496d8d7 194 rm -f $(DVI_TARGETS) $(HTML_TARGETS) $(PDF_TARGETS) $(PS_TARGETS)
17ca7950 195 rm -f emacs-manual-${version}.tar*
8cf51b2c
GM
196
197distclean: clean
26e4aa7d 198 rm -f Makefile
8cf51b2c 199
4c83f6e1
GM
200## In the standalone tarfile, the clean rule runs this.
201infoclean:
ac1a0ce1 202 -cd $(buildinfodir) && rm -f emacs$(INFO_EXT) emacs$(INFO_EXT)-[1-9] emacs$(INFO_EXT)-[1-9][0-9]
df42eec6 203
4c83f6e1
GM
204maintainer-clean: distclean infoclean
205
ea274122
GM
206.PHONY: dist
207
4c83f6e1
GM
208## Make a standalone tarfile of the Emacs manual sources.
209## The [c] is a dumb way to prevent configure expanding it.
4c83f6e1 210dist:
17ca7950
GM
211 rm -rf emacs-manual-${version}
212 mkdir emacs-manual-${version}
4c83f6e1 213 cp ${srcdir}/*.texi ${texinfodir}/texinfo.tex \
17ca7950 214 ${srcdir}/ChangeLog* emacs-manual-${version}/
4393405b 215 sed -e 's/@sr[c]dir@/./' -e 's/^\(texinfodir *=\).*/\1 ./' \
2fecccba
GM
216 -e 's/^\(buildinfodir *=\).*/\1 ./' \
217 -e 's/^\(clean:.*\)/\1 infoclean/' \
17ca7950 218 -e "s/@ver[s]ion@/${version}/" \
789cf833
GM
219 -e 's/@MAKE[I]NFO@/makeinfo/' -e 's/@MK[D]IR_P@/mkdir -p/' \
220 -e 's/@IN[F]O_EXT@/.info/' -e 's/@IN[F]O_OPTS@//' \
17ca7950 221 ${srcdir}/Makefile.in > emacs-manual-${version}/Makefile
fc4893eb
GM
222 @if grep '@[a-zA-Z_]*@' emacs-manual-${version}/Makefile; then \
223 echo "Unexpanded configure variables in Makefile?" 1>&2; exit 1; \
224 fi
17ca7950
GM
225 tar -cf emacs-manual-${version}.tar emacs-manual-${version}
226 rm -rf emacs-manual-${version}
4c83f6e1 227
8496d8d7
GM
228
229.PHONY: install-dvi install-html install-pdf install-ps install-doc
230
231install-dvi: dvi
48f73cfb
GM
232 umask 022; $(MKDIR_P) "$(DESTDIR)$(dvidir)"
233 $(INSTALL_DATA) $(DVI_TARGETS) "$(DESTDIR)$(dvidir)"
8496d8d7 234install-html: html
48f73cfb
GM
235 umask 022; $(MKDIR_P) "$(DESTDIR)$(htmldir)"
236 $(INSTALL_DATA) $(HTML_TARGETS) "$(DESTDIR)$(htmldir)"
8496d8d7 237install-pdf: pdf
48f73cfb
GM
238 umask 022;$(MKDIR_P) "$(DESTDIR)$(pdfdir)"
239 $(INSTALL_DATA) $(PDF_TARGETS) "$(DESTDIR)$(pdfdir)"
8496d8d7 240install-ps: ps
48f73cfb 241 umask 022; $(MKDIR_P) "$(DESTDIR)$(psdir)"
8496d8d7 242 for file in $(PS_TARGETS); do \
48f73cfb 243 $(INSTALL_DATA) $${file} "$(DESTDIR)$(psdir)"; \
8496d8d7 244 [ -n "${GZIP_PROG}" ] || continue; \
48f73cfb
GM
245 rm -f "$(DESTDIR)$(psdir)/$${file}.gz"; \
246 ${GZIP_PROG} -9n "$(DESTDIR)$(psdir)/$${file}"; \
8496d8d7
GM
247 done
248
249## Top-level Makefile installs the info pages.
250install-doc: install-dvi install-html install-pdf install-ps
251
252
253.PHONY: uninstall-dvi uninstall-html uninstall-pdf uninstall-ps uninstall-doc
254
255uninstall-dvi:
256 for file in $(DVI_TARGETS); do \
48f73cfb 257 rm -f "$(DESTDIR)$(dvidir)/$${file}"; \
8496d8d7
GM
258 done
259uninstall-html:
260 for file in $(HTML_TARGETS); do \
48f73cfb 261 rm -f "$(DESTDIR)$(htmldir)/$${file}"; \
8496d8d7
GM
262 done
263uninstall-ps:
264 ext= ; [ -n "${GZIP_PROG}" ] && ext=.gz; \
265 for file in $(PS_TARGETS); do \
48f73cfb 266 rm -f "$(DESTDIR)$(psdir)/$${file}$${ext}"; \
8496d8d7
GM
267 done
268uninstall-pdf:
269 for file in $(PDF_TARGETS); do \
48f73cfb 270 rm -f "$(DESTDIR)$(pdfdir)/$${file}"; \
8496d8d7
GM
271 done
272
273uninstall-doc: uninstall-dvi uninstall-html uninstall-pdf uninstall-ps
274
275
df42eec6 276### Makefile ends here