(read_process_output): Deactivate the mark.
[bpt/emacs.git] / src / Makefile.in
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.
4
5 MAKE = make
6 # BSD doesn't have it as a default.
7
8 # ==================== Things `configure' might edit ====================
9
10 CC=cc
11 CFLAGS=-g
12 srcdir=@srcdir@/src
13 VPATH=@srcdir@/src
14 LN_S=ln -s
15
16 # ============================= Targets ==============================
17
18 CPP = $(CC) -E -Is -Im
19 #Note: an alternative is CPP = /lib/cpp
20
21 # Just to avoid uncertainty.
22 SHELL = /bin/sh
23
24 SUBMAKEFLAGS = CC='${CC}' LN_S='${LN_S}' CFLAGS='${CFLAGS}' MAKE='${MAKE}'
25
26 all: doall
27
28 doall: xmakefile
29 $(MAKE) ${SUBMAKEFLAGS} -f xmakefile ${MFLAGS} all
30
31 #This is used in making a distribution.
32 #Do not use it on development directories!
33 distclean:
34 -rm -f paths.h config.h emacs-* temacs emacs xmakefile core *.o
35
36 clean:
37 -rm -f temacs emacs prefix-args xmakefile* core \#* *.o libXMenu11.a
38
39 versionclean:
40 -rm -f emacs emacs-* ../etc/DOC*
41
42 extraclean: distclean
43 -rm -f *~ \#* m/*~ s/*~
44
45 emacs: doemacs
46 @true
47
48 doemacs: xmakefile
49 $(MAKE) ${SUBMAKEFLAGS} -f xmakefile ${MFLAGS} emacs
50
51 temacs: dotemacs
52 @true
53
54 dotemacs: xmakefile
55 $(MAKE) ${SUBMAKEFLAGS} -f xmakefile ${MFLAGS} temacs
56
57 SOURCES = *.[ch] [sm]/* COPYING Makefile.in ymakefile \
58 config.h.in README COPYING ChangeLog vms.pp-trans
59 unlock:
60 chmod u+w $(SOURCES)
61
62 relock:
63 chmod -w $(SOURCES)
64 chmod +w paths.h
65
66 ### Some makes, like Ultrix's make, complain if you put a comment in
67 ### the middle of a rule's command list! Dummies.
68
69 ### The flags for optimization and debugging depend on the
70 ### system, so take an ordinary CFLAGS value and choose the
71 ### appropriate CPP symbols to use in ymakefile.
72 ### If you have a problem with cc -E here, changing
73 ### the definition of CPP above may fix it.
74
75 # Remake xmakefile whenever we reconfigure even if config.h didn't change.
76 xmakefile: ymakefile config.h ../config.status
77 -rm -f xmakefile xmakefile.new junk.c junk.cpp
78 cp ${srcdir}/ymakefile junk.c
79 ${CPP} -I${srcdir} ${CFLAGS} junk.c > junk.cpp \
80 -DC_SWITCH_SITE="`echo ${CFLAGS}' ' \
81 | sed -e 's/-g /C_DEBUG_SWITCH /' \
82 -e 's/-O[0-9]* /C_OPTIMIZE_SWITCH /'`"
83 < junk.cpp \
84 sed -e 's/^#.*//' \
85 -e 's/^[ \f\t][ \f\t]*$$//' \
86 -e 's/^ / /' \
87 -e 's|^\(srcdir *=\).*$$|\1'"${srcdir}"'|' \
88 -e 's|^\(VPATH *=\).*$$|\1'"${srcdir}"'|' \
89 | sed -n -e '/^..*$$/p' \
90 > xmakefile.new
91 mv -f xmakefile.new xmakefile
92 chmod 444 xmakefile
93 rm -f junk.c junk.cpp
94
95 tagsfiles = [a-z]*.h [a-z]*.c ../lisp/[a-z]*.el ../lisp/term/[a-z]*.el
96 TAGS: $(tagsfiles)
97 etags $(tagsfiles)
98 tags: TAGS
99 .PHONY: tags