(Ffont_info): Make vector of correct size.
[bpt/emacs.git] / Makefile.in
CommitLineData
46947372
JB
1# DIST: This is the distribution Makefile for Emacs. configure can
2# DIST: make most of the changes to this file you might want, so try
3# DIST: that first.
86a5659e 4
46947372
JB
5# make all to compile and build Emacs.
6# make install to install it.
78008d14 7# make TAGS to update tags tables.
86a5659e 8#
78008d14
JB
9# make clean or make mostlyclean
10# Delete all files from the current directory that are normally
868e080d 11# created by building the program. Don't delete the files that
78008d14
JB
12# record the configuration. Also preserve files that could be made
13# by building, but normally aren't because the distribution comes
14# with them.
15#
16# Delete `.dvi' files here if they are not part of the distribution.
17#
18# make distclean
19# Delete all files from the current directory that are created by
20# configuring or building the program. If you have unpacked the
21# source and built the program without creating any other files,
22# `make distclean' should leave only the files that were in the
23# distribution.
24#
26873b72 25# make maintainer-clean
78008d14
JB
26# Delete everything from the current directory that can be
27# reconstructed with this Makefile. This typically includes
28# everything deleted by distclean, plus more: C source files
29# produced by Bison, tags tables, info files, and so on.
30#
31# make extraclean
32# Still more severe - delete backup and autosave files, too.
86a5659e
JB
33
34SHELL = /bin/sh
2dc44cb5
RS
35
36# If Make doesn't predefine MAKE, set it here.
37@SET_MAKE@
86a5659e 38
78008d14 39# ==================== Things `configure' Might Edit ====================
86a5659e 40
c75ff9db 41CC=@CC@
d4acf74f 42CPP=@CPP@
c75ff9db 43C_SWITCH_SYSTEM=@c_switch_system@
d3245f70 44ALLOCA=@ALLOCA@
b6472fc1
JB
45LN_S=@LN_S@
46CFLAGS=@CFLAGS@
46af2ed8 47C_SWITCH_X_SITE=@C_SWITCH_X_SITE@
09b89128 48LD_SWITCH_X_SITE=@LD_SWITCH_X_SITE@
4b5a51c1 49YACC=@YACC@
78008d14
JB
50
51### These help us choose version- and architecture-specific directories
52### to install files in.
53
54### This should be the number of the Emacs version we're building,
55### like `18.59' or `19.0'.
c75ff9db 56version=@version@
78008d14
JB
57
58### This should be the name of the configuration we're building Emacs
59### for, like `mips-dec-ultrix' or `sparc-sun-sunos'.
c75ff9db
JB
60configuration=@configuration@
61
78008d14
JB
62# ==================== Where To Install Things ====================
63
46947372 64# The default location for installation. Everything is placed in
78008d14
JB
65# subdirectories of this directory. The default values for many of
66# the variables below are expressed in terms of this one, so you may
8d467c70
JB
67# not need to change them. This defaults to /usr/local.
68prefix=@prefix@
86a5659e 69
78008d14 70# Like `prefix', but used for architecture-specific files.
86ddcc58 71exec_prefix=@exec_prefix@
78008d14 72
46947372
JB
73# Where to install Emacs and other binaries that people will want to
74# run directly (like etags).
0e265b72 75bindir=@bindir@
86a5659e 76
868e080d 77# Where to install architecture-independent data files. ${lispdir}
78008d14 78# and ${etcdir} are subdirectories of this.
0e265b72 79datadir=@datadir@
0c22fbca
JB
80
81# Where to install and expect the files that Emacs modifies as it
868e080d 82# runs. These files are all architecture-independent. Right now, the
78008d14
JB
83# only such data is the locking directory; ${lockdir} is a
84# subdirectory of this.
3e74e344 85sharedstatedir=@sharedstatedir@
0c22fbca
JB
86
87# Where to install and expect executable files to be run by Emacs
88# rather than directly by users, and other architecture-dependent
868e080d 89# data. ${archlibdir} is a subdirectory of this.
2fd54e64 90libexecdir=@libexecdir@
0c22fbca
JB
91
92# Where to install Emacs's man pages, and what extension they should have.
0e265b72 93mandir=@mandir@
0c22fbca 94manext=.1
88e7bbf1 95man1dir=$(mandir)/man1
0c22fbca
JB
96
97# Where to install and expect the info files describing Emacs. In the
98# past, this defaulted to a subdirectory of ${prefix}/lib/emacs, but
99# since there are now many packages documented with the texinfo
100# system, it is inappropriate to imply that it is part of Emacs.
0e265b72 101infodir=@infodir@
86a5659e 102
b2f3c6b2
RS
103# Where to look for bitmap files.
104bitmapdir=@bitmapdir@
105
00c29909 106# Where to find the source code. The source code for Emacs's C kernel is
78008d14
JB
107# expected to be in ${srcdir}/src, and the source code for Emacs's
108# utility programs is expected to be in ${srcdir}/lib-src. This is
109# set by the configure script's `--srcdir' option.
d3245f70 110srcdir=@srcdir@
86a5659e 111
f854bb66
RM
112# Tell make where to find source files; this is needed for the makefiles.
113VPATH=@srcdir@
114
0c22fbca
JB
115# ==================== Emacs-specific directories ====================
116
78008d14
JB
117# These variables hold the values Emacs will actually use. They are
118# based on the values of the standard Make variables above.
119
0e265b72
BF
120# Where to install the lisp files distributed with
121# Emacs. This includes the Emacs version, so that the
122# lisp files for different versions of Emacs will install
123# themselves in separate directories.
124lispdir=@lispdir@
d3245f70 125
0e265b72
BF
126# Directories Emacs should search for lisp files specific
127# to this site (i.e. customizations), before consulting
128# ${lispdir}. This should be a colon-separated list of
129# directories.
130locallisppath=@locallisppath@
d3245f70
JB
131
132# Where Emacs will search to find its lisp files. Before
133# changing this, check to see if your purpose wouldn't
134# better be served by changing locallisppath. This
46947372 135# should be a colon-separated list of directories.
0e265b72 136lisppath=@lisppath@
86a5659e 137
d3245f70
JB
138# Where Emacs will search for its lisp files while
139# building. This is only used during the process of
140# compiling Emacs, to help Emacs find its lisp files
141# before they've been installed in their final location.
90ac71dc
RS
142# It's usually identical to lisppath, except that
143# it does not include locallisppath, and the
d3245f70
JB
144# entry for the directory containing the installed lisp
145# files has been replaced with ../lisp. This should be a
146# colon-separated list of directories.
3dbc7e32 147buildlisppath=${srcdir}/lisp
86a5659e 148
0e265b72
BF
149# Where to install the other architecture-independent
150# data files distributed with Emacs (like the tutorial,
151# the cookie recipes and the Zippy database). This path
152# usually contains the Emacs version number, so the data
153# files for multiple versions of Emacs may be installed
154# at once.
155etcdir=@etcdir@
156
157# Where to create and expect the locking directory, where
158# the Emacs locking code keeps track of which files are
159# currently being edited.
160lockdir=@lockdir@
161
162# Where to put executables to be run by Emacs rather than
163# the user. This path usually includes the Emacs version
164# and configuration name, so that multiple configurations
165# for multiple versions of Emacs may be installed at
166# once.
167archlibdir=@archlibdir@
a34902ab 168
e408046f
KH
169# Where to put the docstring file.
170docdir=@docdir@
171
46947372
JB
172# ==================== Utility Programs for the Build ====================
173
174# Allow the user to specify the install program.
19697295 175INSTALL = @INSTALL@
86ddcc58
JB
176INSTALL_PROGRAM = @INSTALL_PROGRAM@
177INSTALL_DATA = @INSTALL_DATA@
c1b8c545
RS
178# By default, we uphold the dignity of our programs.
179INSTALL_STRIP =
46947372 180
46947372 181# ============================= Targets ==============================
86a5659e 182
9ef7f9f0
KH
183# What emacs should be called when installed.
184EMACS = emacs
185
86a5659e
JB
186# Subdirectories to make recursively. `lisp' is not included
187# because the compiled lisp files are part of the distribution
188# and you cannot remake them without installing Emacs first.
c55db078 189SUBDIR = lib-src src leim
86a5659e 190
78008d14 191# The makefiles of the directories in $SUBDIR.
c55db078 192SUBDIR_MAKEFILES = lib-src/Makefile man/Makefile src/Makefile oldXMenu/Makefile lwlib/Makefile leim/Makefile
78008d14 193
83f6a565
JB
194# Subdirectories to install, and where they'll go.
195# lib-src's makefile knows how to install it, so we don't do that here.
c55db078 196# leim's makefile also knows how to install it, so we don't do that here.
83f6a565
JB
197# When installing the info files, we need to do special things to
198# avoid nuking an existing dir file, so we don't do that here;
199# instead, we have written out explicit code in the `install' targets.
78c7997f
RS
200COPYDIR = ${srcdir}/etc ${srcdir}/lisp
201COPYDESTS = ${etcdir} ${lispdir}
86a5659e 202
0a0dca73 203all: ${SUBDIR}
86a5659e 204
309848ba 205removenullpaths=sed -e 's/^://g' -e 's/:$$//g' -e 's/::/:/g'
46947372 206
0a0dca73
RS
207# Generate paths.h from paths.in. This target is invoked by `configure'.
208paths-force: FRC
8672a560
RS
209 @(lisppath=`echo ${lisppath} | ${removenullpaths}` ; \
210 buildlisppath=`echo ${buildlisppath} | ${removenullpaths}` ; \
8d61b1e0 211 sed < ${srcdir}/src/paths.in > paths.h.$$$$ \
8672a560
RS
212 -e 's;\(#.*PATH_LOADSEARCH\).*$$;\1 "'$${lisppath}'";' \
213 -e 's;\(#.*PATH_DUMPLOADSEARCH\).*$$;\1 "'$${buildlisppath}'";' \
214 -e 's;\(#.*PATH_EXEC\).*$$;\1 "${archlibdir}";' \
215 -e 's;\(#.*PATH_INFO\).*$$;\1 "${infodir}";' \
216 -e 's;\(#.*PATH_DATA\).*$$;\1 "${etcdir}";' \
b2f3c6b2 217 -e 's;\(#.*PATH_BITMAPS\).*$$;\1 "${bitmapdir}";' \
8672a560 218 -e 's;\(#.*PATH_DOC\).*$$;\1 "${docdir}";' \
270cc80e 219 -e 's;\(#.*PATH_LOCK\).*$$;\1 "${lockdir}/";') && \
8d61b1e0 220 ${srcdir}/move-if-change paths.h.$$$$ src/paths.h
8672a560 221
0a0dca73 222src: lib-src FRC
a874c104 223
f2f4aae9 224lib-src: FRC src/config.stamp
86a5659e
JB
225
226.RECURSIVE: ${SUBDIR}
227
78008d14 228${SUBDIR}: ${SUBDIR_MAKEFILES} FRC
0e265b72 229 cd $@; $(MAKE) all $(MFLAGS) \
7c811eec
RS
230 CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \
231 LDFLAGS='${LDFLAGS}' MAKE='${MAKE}'
0e265b72 232
8672a560 233blessmail: ${SUBDIR_MAKEFILES} src FRC
df8bde8b
RS
234 cd lib-src; $(MAKE) maybe-blessmail $(MFLAGS) \
235 MAKE='${MAKE}' archlibdir='$(archlibdir)'
d541babe 236
0e265b72
BF
237Makefile: Makefile.in config.status
238 ./config.status
239
d58c5947 240src/Makefile: src/Makefile.in config.status
0e265b72
BF
241 ./config.status
242
f2f4aae9 243src/config.stamp: src/config.in config.status
a5f32ce4 244 ./config.status
f2f4aae9 245 touch src/config.stamp
a5f32ce4 246
0e265b72
BF
247lib-src/Makefile: lib-src/Makefile.in config.status
248 ./config.status
249
250oldXMenu/Makefile: oldXMenu/Makefile.in config.status
78008d14
JB
251 ./config.status
252
98dfba1b
RS
253lwlib/Makefile: lwlib/Makefile.in config.status
254 ./config.status
255
c55db078
KH
256leim/Makefile: leim/Makefile.in config.status
257 ./config.status
258
78008d14
JB
259# ==================== Installation ====================
260
dbc4e1c1
JB
261## If we let lib-src do its own installation, that means we
262## don't have to duplicate the list of utilities to install in
263## this Makefile as well.
d3245f70 264
3dbc7e32
JB
265## On AIX, use tar xBf.
266## On Xenix, use tar xpf.
267
9ef7f9f0 268.PHONY: install mkdir
98dfba1b 269
d3245f70
JB
270## We delete each directory in ${COPYDESTS} before we copy into it;
271## that way, we can reinstall over directories that have been put in
272## place with their files read-only (perhaps because they are checked
273## into RCS). In order to make this safe, we make sure that the
274## source exists and is distinct from the destination.
d7ce568f
RS
275### We do install-arch-indep first because
276### the executable needs the Lisp files and DOC file to work properly.
24127cf7 277install: all install-arch-indep install-arch-dep blessmail install-leim
a5038ae5 278 @true
8b14d296 279
d7e2eff6 280### Install the executables that were compiled specifically for this machine.
d7ce568f
RS
281### It would be nice to do something for a parallel make
282### to ensure that install-arch-indep finishes before this starts.
283install-arch-dep: mkdir
8b14d296 284 (cd lib-src; \
0e265b72 285 $(MAKE) install $(MFLAGS) prefix=${prefix} \
2fd54e64 286 exec_prefix=${exec_prefix} bindir=${bindir} \
c1b8c545
RS
287 libexecdir=${libexecdir} archlibdir=${archlibdir} \
288 INSTALL_STRIP=${INSTALL_STRIP})
289 ${INSTALL_PROGRAM} $(INSTALL_STRIP) src/emacs ${bindir}/emacs-${version}
08068cb6 290 -chmod 1755 ${bindir}/emacs-${version}
9ef7f9f0
KH
291 rm -f ${bindir}/$(EMACS)
292 -ln ${bindir}/emacs-${version} ${bindir}/$(EMACS)
08068cb6 293
d7e2eff6
RS
294### Install the files that are machine-independent.
295### Most of them come straight from the distribution;
296### the exception is the DOC-* files, which are copied
24127cf7 297## from the build directory.
d7e2eff6 298
24127cf7
KH
299## Note that we copy DOC* and then delete DOC
300## as a workaround for a bug in tar on Ultrix 4.2.
d7d265f4 301install-arch-indep: mkdir
46947372 302 -set ${COPYDESTS} ; \
d7e2eff6
RS
303 for dir in ${COPYDIR} ; do \
304 if [ `(cd $$1 && /bin/pwd)` != `(cd $${dir} && /bin/pwd)` ] ; then \
305 rm -rf $$1 ; \
306 fi ; \
307 shift ; \
308 done
005775ce 309 -set ${COPYDESTS} ; \
d7e2eff6
RS
310 mkdir ${COPYDESTS} ; \
311 chmod ugo+rx ${COPYDESTS} ; \
312 for dir in ${COPYDIR} ; do \
313 dest=$$1 ; shift ; \
314 [ -d $${dir} ] \
315 && [ `(cd $${dir} && /bin/pwd)` != `(cd $${dest} && /bin/pwd)` ] \
316 && (echo "Copying $${dir} to $${dest}..." ; \
317 (cd $${dir}; tar -cf - . )|(cd $${dest};umask 022; tar -xvf - ); \
318 for subdir in `find $${dest} -type d ! -name RCS -print` ; do \
319 rm -rf $${subdir}/RCS ; \
320 rm -rf $${subdir}/CVS ; \
321 rm -f $${subdir}/\#* ; \
322 rm -f $${subdir}/.\#* ; \
323 rm -f $${subdir}/*~ ; \
324 rm -f $${subdir}/*.orig ; \
325 rm -f $${subdir}/[mM]akefile* ; \
326 rm -f $${subdir}/ChangeLog* ; \
327 rm -f $${subdir}/dired.todo ; \
328 done) ; \
329 done
b2f3c6b2 330 -rm -f ${lispdir}/subdirs.el
b4594994 331 $(srcdir)/update-subdirs ${lispdir}
3577cff0 332 -chmod -R a+r ${COPYDESTS}
3be1f08e
RS
333 if [ `(cd ./etc; /bin/pwd)` != `(cd ${docdir}; /bin/pwd)` ]; \
334 then \
99d7a69d 335 echo "Copying etc/DOC-* to ${docdir} ..." ; \
7d2cdc3c 336 (cd ./etc; tar -cf - DOC*)|(cd ${docdir}; umask 0; tar -xvf - ); \
d7e2eff6 337 (cd $(docdir); chmod a+r DOC*; rm DOC) \
3be1f08e 338 else true; fi
7d2cdc3c
RS
339 if [ -r ./lisp ] \
340 && [ x`(cd ./lisp; /bin/pwd)` != x`(cd ${lispdir}; /bin/pwd)` ] \
9ca335ed
RS
341 && [ x`(cd ${srcdir}/lisp; /bin/pwd)` != x`(cd ./lisp; /bin/pwd)` ]; \
342 then \
343 echo "Copying lisp/*.el and lisp/*.elc to ${lispdir} ..." ; \
344 (cd lisp; tar -cf - *.el *.elc)|(cd ${lispdir}; umask 0; tar -xvf - ); \
345 else true; fi
8672a560 346 thisdir=`/bin/pwd`; \
21e8e1db 347 if [ `(cd ${srcdir}/info && /bin/pwd)` != `(cd ${infodir} && /bin/pwd)` ]; \
5e9e88fd 348 then \
469dd2ef 349 (cd ${infodir}; \
6e2f2e92 350 if [ -f dir ]; then \
efe7425c
RS
351 if [ ! -f dir.old ]; then mv -f dir dir.old; \
352 else mv -f dir dir.bak; fi; \
353 fi; \
469dd2ef
RS
354 cd ${srcdir}/info ; \
355 (cd $${thisdir}; ${INSTALL_DATA} ${srcdir}/info/dir ${infodir}/dir); \
d7e2eff6 356 (cd $${thisdir}; chmod a+r ${infodir}/dir); \
44f4198d 357 for f in ccmode* cl* dired-x* ediff* emacs* forms* gnus* info* message* mh-e* sc* vip*; do \
d7e2eff6
RS
358 (cd $${thisdir}; \
359 ${INSTALL_DATA} ${srcdir}/info/$$f ${infodir}/$$f; \
360 chmod a+r ${infodir}/$$f); \
ce0b6622 361 done); \
21e8e1db 362 else true; fi
d7e2eff6
RS
363 thisdir=`/bin/pwd`; \
364 cd ${srcdir}/etc; \
365 for page in emacs etags ctags ; do \
366 (cd $${thisdir}; \
367 ${INSTALL_DATA} ${srcdir}/etc/$${page}.1 ${man1dir}/$${page}${manext}; \
368 chmod a+r ${man1dir}/$${page}${manext}); \
868e080d 369 done
badb0a97 370
24127cf7
KH
371### Install LEIM files. Although they are machine-independent, we
372### have separate target here instead of including it in
373### `install-arch-indep'. People who extracted LEIM files after they
374### insalled Emacs itself can install only LEIM files by this target.
375install-leim: leim/Makefile
c10f84fb 376 cd leim; $(MAKE) install
24127cf7 377
8df9abae
RS
378### Build Emacs and install it, stripping binaries while installing them.
379install-strip:
c1b8c545 380 $(MAKE) INSTALL_STRIP=-s
8df9abae 381
868e080d 382### Build all the directories we're going to install Emacs in. Since
78008d14 383### we may be creating several layers of directories (for example,
614b45a7 384### /usr/local/lib/emacs/19.0/mips-dec-ultrix4.2), we use mkinstalldirs
6784fb67 385### instead of mkdir. Not all systems' mkdir programs have the `-p' flag.
05ed817f 386mkdir: FRC
88e7bbf1 387 $(srcdir)/mkinstalldirs ${COPYDESTS} ${lockdir} ${infodir} ${man1dir} \
2fd54e64 388 ${bindir} ${datadir} ${docdir} ${libexecdir} \
309848ba 389 `echo ${locallisppath} | sed 's/:/ /g'`
dffd6dac 390 -chmod a+rwx ${lockdir}
86a5659e 391
d4acf74f
JB
392### Delete all the installed files that the `install' target would
393### create (but not the noninstalled files such as `make all' would
394### create).
44257b1a
JB
395###
396### Don't delete the lisp and etc directories if they're in the source tree.
d4acf74f 397uninstall:
44257b1a 398 (cd lib-src; \
0e265b72 399 $(MAKE) $(MFLAGS) uninstall \
44257b1a 400 prefix=${prefix} exec_prefix=${exec_prefix} \
2fd54e64 401 bindir=${bindir} libexecdir=${libexecdir} archlibdir=${archlibdir})
44257b1a 402 for dir in ${lispdir} ${etcdir} ; do \
726d0798 403 if [ -d $${dir} ]; then \
8672a560
RS
404 case `(cd $${dir} ; /bin/pwd)` in \
405 `(cd ${srcdir} ; /bin/pwd)`* ) ;; \
726d0798
RS
406 * ) rm -rf $${dir} ;; \
407 esac ; \
408 case $${dir} in \
409 ${datadir}/emacs/${version}/* ) \
410 rm -rf ${datadir}/emacs/${version} \
411 ;; \
412 esac ; \
413 fi ; \
44257b1a 414 done
1eb9aca7 415 (cd ${infodir} && rm -f cl* dired-x* ediff* emacs* forms* gnus* info* mh-e* sc* vip*)
88e7bbf1 416 (cd ${man1dir} && rm -f emacs.1 etags.1 ctags.1)
6b356ee8 417 (cd ${bindir} && rm -f emacs-${version} $(EMACS))
d4acf74f
JB
418
419
05ed817f 420FRC:
78008d14
JB
421
422# ==================== Cleaning up and miscellanea ====================
423
26873b72 424.PHONY: mostlyclean clean distclean maintainer-clean extraclean
98dfba1b 425
78008d14 426### `mostlyclean'
d4acf74f
JB
427### Like `clean', but may refrain from deleting a few files that people
428### normally don't want to recompile. For example, the `mostlyclean'
429### target for GCC does not delete `libgcc.a', because recompiling it
430### is rarely necessary and takes a lot of time.
05ed817f 431mostlyclean: FRC
0e265b72
BF
432 (cd src; $(MAKE) $(MFLAGS) mostlyclean)
433 (cd oldXMenu; $(MAKE) $(MFLAGS) mostlyclean)
98dfba1b 434 (cd lwlib; $(MAKE) $(MFLAGS) mostlyclean)
0e265b72 435 (cd lib-src; $(MAKE) $(MFLAGS) mostlyclean)
e6124e9d 436 -(cd man && $(MAKE) $(MFLAGS) mostlyclean)
d4acf74f
JB
437
438### `clean'
439### Delete all files from the current directory that are normally
440### created by building the program. Don't delete the files that
441### record the configuration. Also preserve files that could be made
442### by building, but normally aren't because the distribution comes
443### with them.
78008d14 444###
d4acf74f 445### Delete `.dvi' files here if they are not part of the distribution.
05ed817f 446clean: FRC
0e265b72
BF
447 (cd src; $(MAKE) $(MFLAGS) clean)
448 (cd oldXMenu; $(MAKE) $(MFLAGS) clean)
98dfba1b 449 (cd lwlib; $(MAKE) $(MFLAGS) clean)
0e265b72 450 (cd lib-src; $(MAKE) $(MFLAGS) clean)
e6124e9d 451 -(cd man && $(MAKE) $(MFLAGS) clean)
46947372 452
78008d14 453### `distclean'
d4acf74f
JB
454### Delete all files from the current directory that are created by
455### configuring or building the program. If you have unpacked the
456### source and built the program without creating any other files,
457### `make distclean' should leave only the files that were in the
458### distribution.
459top_distclean=\
dffd6dac 460 rm -f config.status config.cache config.log ; \
d4acf74f 461 rm -f Makefile ${SUBDIR_MAKEFILES} ; \
8df9abae 462 (cd lock && (rm * || true))
05ed817f 463distclean: FRC
0e265b72
BF
464 (cd src; $(MAKE) $(MFLAGS) distclean)
465 (cd oldXMenu; $(MAKE) $(MFLAGS) distclean)
98dfba1b 466 (cd lwlib; $(MAKE) $(MFLAGS) distclean)
0e265b72 467 (cd lib-src; $(MAKE) $(MFLAGS) distclean)
e6124e9d 468 (cd man && $(MAKE) $(MFLAGS) distclean)
d4acf74f 469 ${top_distclean}
46947372 470
26873b72 471### `maintainer-clean'
d4acf74f
JB
472### Delete everything from the current directory that can be
473### reconstructed with this Makefile. This typically includes
474### everything deleted by distclean, plus more: C source files
475### produced by Bison, tags tables, info files, and so on.
476###
26873b72 477### One exception, however: `make maintainer-clean' should not delete
d4acf74f 478### `configure' even if `configure' can be remade using a rule in the
26873b72 479### Makefile. More generally, `make maintainer-clean' should not delete
d4acf74f
JB
480### anything that needs to exist in order to run `configure' and then
481### begin to build the program.
26873b72
RS
482maintainer-clean: FRC
483 (cd src; $(MAKE) $(MFLAGS) maintainer-clean)
484 (cd oldXMenu; $(MAKE) $(MFLAGS) maintainer-clean)
485 (cd lwlib; $(MAKE) $(MFLAGS) maintainer-clean)
486 (cd lib-src; $(MAKE) $(MFLAGS) maintainer-clean)
487 -(cd man && $(MAKE) $(MFLAGS) maintainer-clean)
d4acf74f 488 ${top_distclean}
46947372 489
78008d14
JB
490### This doesn't actually appear in the coding standards, but Karl
491### says GCC supports it, and that's where the configuration part of
492### the coding standards seem to come from. It's like distclean, but
493### it deletes backup and autosave files too.
494extraclean:
0e265b72 495 for i in ${SUBDIR}; do (cd $$i; $(MAKE) $(MFLAGS) extraclean); done
9e8886a8
RS
496 ${top_distclean}
497 -rm config-tmp-*
78008d14
JB
498 -rm -f *~ \#*
499
29c0047b
ER
500### Unlocking and relocking. The idea of these productions is to reduce
501### hassles when installing an incremental tar of Emacs. Do `make unlock'
502### before unlocking the file to take the write locks off all sources so
503### that tar xvof will overwrite them without fuss. Then do `make relock'
504### afterward so that VC mode will know which files should be checked in
505### if you want to mung them.
506###
507### Note: it's no disaster if these productions miss a file or two; tar
508### and VC will swiftly let you know if this happens, and it is easily
509### corrected.
510SOURCES = ChangeLog GETTING.GNU.SOFTWARE INSTALL Makefile.in PROBLEMS \
24470d72 511 README configure make-dist move-if-change
29c0047b 512
98dfba1b
RS
513.PHONY: unlock relock
514
29c0047b
ER
515unlock:
516 chmod u+w $(SOURCES) cpp/*
517 -(cd elisp; chmod u+w Makefile README *.texi)
0e265b72
BF
518 (cd etc; $(MAKE) $(MFLAGS) unlock)
519 (cd lib-src; $(MAKE) $(MFLAGS) unlock)
520 (cd lisp; $(MAKE) $(MFLAGS) unlock)
29c0047b
ER
521 (cd lisp/term; chmod u+w README *.el)
522 (cd man; chmod u+w *texi* ChangeLog split-man)
523 (cd oldXMenu; chmod u+w *.[ch] Makefile README)
98dfba1b 524 (cd lwlib; chmod u+w *.[ch] Makefile README)
0e265b72 525 (cd src; $(MAKE) $(MFLAGS) unlock)
29c0047b
ER
526
527relock:
528 chmod u-w $(SOURCES) cpp/*
529 -(cd elisp; chmod u-w Makefile README *.texi)
0e265b72
BF
530 (cd etc; $(MAKE) $(MFLAGS) relock)
531 (cd lib-src; $(MAKE) $(MFLAGS) relock)
532 (cd lisp; $(MAKE) $(MFLAGS) relock)
29c0047b
ER
533 (cd lisp/term; chmod u+w README *.el)
534 (cd man; chmod u+w *texi* ChangeLog split-man)
535 (cd oldXMenu; chmod u+w *.[ch] Makefile README)
98dfba1b 536 (cd lwlib; chmod u+w *.[ch] Makefile README)
0e265b72 537 (cd src; $(MAKE) $(MFLAGS) relock)
78008d14 538
46947372 539TAGS tags: lib-src
928cf895 540 cd ${srcdir}/src; $(MAKE) tags
46947372
JB
541
542check:
543 @echo "We don't have any tests for GNU Emacs yet."
4746118a
JB
544
545dist:
78008d14 546 cd ${srcdir}; make-dist
d4acf74f 547
653ddcc3
RS
548.PHONY: info dvi dist check
549force-info:
550info: force-info
0e265b72 551 (cd ${srcdir}/man; $(MAKE) $(MFLAGS) info)
d4acf74f 552dvi:
6784fb67 553 (cd man; $(MAKE) $(MFLAGS) dvi)