aboutsummaryrefslogtreecommitdiffstats
path: root/src/Makefile.in
diff options
context:
space:
mode:
authorKen Raeburn2015-11-01 01:42:21 -0400
committerKen Raeburn2015-11-01 01:42:21 -0400
commit39372e1a1032521be74575bb06f95a3898fbae30 (patch)
tree754bd242a23d2358ea116126fcb0a629947bd9ec /src/Makefile.in
parent6a3121904d76e3b2f63007341d48c5c1af55de80 (diff)
parente11aaee266da52937a3a031cb108fe13f68958c3 (diff)
downloademacs-39372e1a1032521be74575bb06f95a3898fbae30.tar.gz
emacs-39372e1a1032521be74575bb06f95a3898fbae30.zip
merge from trunk
Diffstat (limited to 'src/Makefile.in')
-rw-r--r--src/Makefile.in452
1 files changed, 246 insertions, 206 deletions
diff --git a/src/Makefile.in b/src/Makefile.in
index 5b1a7b525d0..0f30ae2c6b1 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -1,6 +1,6 @@
1### @configure_input@ 1### @configure_input@
2 2
3# Copyright (C) 1985, 1987-1988, 1993-1995, 1999-2013 Free Software 3# Copyright (C) 1985, 1987-1988, 1993-1995, 1999-2015 Free Software
4# Foundation, Inc. 4# Foundation, Inc.
5 5
6# This file is part of GNU Emacs. 6# This file is part of GNU Emacs.
@@ -23,16 +23,16 @@
23# script may need modifying in sync with changes made here. Try to 23# script may need modifying in sync with changes made here. Try to
24# avoid shell-ism because the DOS build has to use the DOS shell. 24# avoid shell-ism because the DOS build has to use the DOS shell.
25 25
26SHELL = /bin/sh 26SHELL = @SHELL@
27 27
28# Here are the things that we expect ../configure to edit. 28# Here are the things that we expect ../configure to edit.
29# We use $(srcdir) explicitly in dependencies so as not to depend on VPATH. 29# We use $(srcdir) explicitly in dependencies so as not to depend on VPATH.
30srcdir = @srcdir@ 30srcdir = @srcdir@
31ntsource = $(srcdir)/../nt 31top_srcdir = @top_srcdir@
32abs_builddir = @abs_builddir@ 32# MinGW CPPFLAGS may use this.
33abs_top_srcdir=@abs_top_srcdir@
33VPATH = $(srcdir) 34VPATH = $(srcdir)
34CC = @CC@ 35CC = @CC@
35WINDRES = @WINDRES@
36CFLAGS = @CFLAGS@ 36CFLAGS = @CFLAGS@
37CPPFLAGS = @CPPFLAGS@ 37CPPFLAGS = @CPPFLAGS@
38LDFLAGS = @LDFLAGS@ 38LDFLAGS = @LDFLAGS@
@@ -47,19 +47,18 @@ MKDIR_P = @MKDIR_P@
47# LIBS = @LIBS@ 47# LIBS = @LIBS@
48LIBOBJS = @LIBOBJS@ 48LIBOBJS = @LIBOBJS@
49 49
50lispsource = $(srcdir)/../lisp 50lispsource = $(top_srcdir)/lisp
51lib = ../lib 51lib = ../lib
52libsrc = ../lib-src 52libsrc = ../lib-src
53etc = ../etc 53etc = ../etc
54leimdir = ../leim 54leimdir = ${lispsource}/leim
55oldXMenudir = ../oldXMenu 55oldXMenudir = ../oldXMenu
56lwlibdir = ../lwlib 56lwlibdir = ../lwlib
57lispdir = ../lisp
58 57
59# Configuration files for .o files to depend on. 58# Configuration files for .o files to depend on.
60config_h = config.h $(srcdir)/conf_post.h 59config_h = config.h $(srcdir)/conf_post.h
61 60
62bootstrap_exe = $(abs_builddir)/bootstrap-emacs$(EXEEXT) 61bootstrap_exe = ../src/bootstrap-emacs$(EXEEXT)
63 62
64## ns-app if HAVE_NS, else empty. 63## ns-app if HAVE_NS, else empty.
65OTHER_FILES = @OTHER_FILES@ 64OTHER_FILES = @OTHER_FILES@
@@ -77,6 +76,7 @@ C_SWITCH_MACHINE=@C_SWITCH_MACHINE@
77C_SWITCH_SYSTEM=@C_SWITCH_SYSTEM@ 76C_SWITCH_SYSTEM=@C_SWITCH_SYSTEM@
78 77
79GNUSTEP_CFLAGS=@GNUSTEP_CFLAGS@ 78GNUSTEP_CFLAGS=@GNUSTEP_CFLAGS@
79PNG_CFLAGS=@PNG_CFLAGS@
80 80
81## Define C_SWITCH_X_SITE to contain any special flags your compiler 81## Define C_SWITCH_X_SITE to contain any special flags your compiler
82## may need to deal with X Windows. For instance, if you've defined 82## may need to deal with X Windows. For instance, if you've defined
@@ -108,11 +108,14 @@ LD_SWITCH_SYSTEM_TEMACS=@LD_SWITCH_SYSTEM_TEMACS@
108## Flags to pass to ld only for temacs. 108## Flags to pass to ld only for temacs.
109TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS) 109TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS)
110 110
111## If available, the full path to the paxctl program. 111## If available, the names of the paxctl and setfattr programs.
112## On grsecurity/PaX systems, unexec will fail due to a gap between 112## On grsecurity/PaX systems, unexec will fail due to a gap between
113## the bss section and the heap. This can be prevented by disabling 113## the bss section and the heap. Older versions need paxctl to work
114## memory randomization in temacs with "paxctl -r". See bug#11398. 114## around this, newer ones setfattr. See Bug#11398 and Bug#16343.
115PAXCTL = @PAXCTL@ 115PAXCTL = @PAXCTL@
116SETFATTR = @SETFATTR@
117PAXCTL_if_present = $(or $(PAXCTL),: paxctl)
118SETFATTR_if_present = $(or $(SETFATTR),: setfattr)
116 119
117## Some systems define this to request special libraries. 120## Some systems define this to request special libraries.
118LIBS_SYSTEM=@LIBS_SYSTEM@ 121LIBS_SYSTEM=@LIBS_SYSTEM@
@@ -120,7 +123,7 @@ LIBS_SYSTEM=@LIBS_SYSTEM@
120## -lm, or empty. 123## -lm, or empty.
121LIB_MATH=@LIB_MATH@ 124LIB_MATH=@LIB_MATH@
122 125
123## -lpthreads, or empty. 126## -lpthread, or empty.
124LIB_PTHREAD=@LIB_PTHREAD@ 127LIB_PTHREAD=@LIB_PTHREAD@
125 128
126LIBIMAGE=@LIBTIFF@ @LIBJPEG@ @LIBPNG@ @LIBGIF@ @LIBXPM@ 129LIBIMAGE=@LIBTIFF@ @LIBJPEG@ @LIBPNG@ @LIBGIF@ @LIBXPM@
@@ -179,30 +182,8 @@ LIBXTR6=@LIBXTR6@
179LIBXT_OTHER=@LIBXT_OTHER@ 182LIBXT_OTHER=@LIBXT_OTHER@
180 183
181## If !HAVE_X11 || USE_GTK, empty. 184## If !HAVE_X11 || USE_GTK, empty.
182## Else if USE_X_TOOLKIT really-lwlib, else really-oldxmenu.
183OLDXMENU_TARGET=@OLDXMENU_TARGET@
184
185## If !HAVE_X11 || USE_GTK, empty.
186## Else if USE_X_TOOLKIT, $(lwlibdir)/liblw.a. 185## Else if USE_X_TOOLKIT, $(lwlibdir)/liblw.a.
187## Else $(oldXMenudir)/libXMenu11.a. 186## Else $(oldXMenudir)/libXMenu11.a.
188## (Actually, rather than being empty, it is set to "nothing".
189## It is never actually used for anything in this case.
190## This is done because there is a rule with target $(OLDXMENU) below,
191## and I think it might be a syntax error with some makes to have
192## an empty target, even if the associated rule is never run.
193## http://lists.gnu.org/archive/html/help-make/2010-05/msg00058.html
194## The alternative would be to put that rule in a makefile fragment.)
195OLDXMENU=@OLDXMENU@
196
197## If HAVE_X11 && !USE_GTK, $(OLDXMENU) ../src/$(OLDXMENU); else empty.
198## We use stamp-xmenu with these two deps to both ensure that lwlib
199## gets remade based on its dependencies in its own makefile,
200## and remake temacs if lwlib gets changed by this.
201OLDXMENU_DEPS=@OLDXMENU_DEPS@
202
203## If !HAVE_X11 && HAVE_X_WINDOWS, -lXMenu (this case no longer possible).
204## Else if !HAVE_X11 || USE_GTK, empty.
205## Else $(OLDXMENU).
206LIBXMENU=@LIBXMENU@ 187LIBXMENU=@LIBXMENU@
207 188
208## xmenu.o if HAVE_X_WINDOWS, else empty. 189## xmenu.o if HAVE_X_WINDOWS, else empty.
@@ -222,7 +203,7 @@ LIBXT=$(TOOLKIT_LIBW) $(LIBXT_OTHER)
222## If HAVE_X11, $(LIBXT) $(LIBX_EXTRA), else empty. 203## If HAVE_X11, $(LIBXT) $(LIBX_EXTRA), else empty.
223LIBX_OTHER=@LIBX_OTHER@ 204LIBX_OTHER=@LIBX_OTHER@
224 205
225## LIBXMENU is nil if !HAVE_X_WINDOWS. 206## LIBXMENU is empty if !HAVE_X_WINDOWS.
226## LD_SWITCH_X_SITE should not be used if not using X, but nothing 207## LD_SWITCH_X_SITE should not be used if not using X, but nothing
227## sets it at present, and if something ever does, it should be 208## sets it at present, and if something ever does, it should be
228## configure, which should set it to nil in non-X builds. 209## configure, which should set it to nil in non-X builds.
@@ -237,6 +218,9 @@ CFLAGS_SOUND= @CFLAGS_SOUND@
237RSVG_LIBS= @RSVG_LIBS@ 218RSVG_LIBS= @RSVG_LIBS@
238RSVG_CFLAGS= @RSVG_CFLAGS@ 219RSVG_CFLAGS= @RSVG_CFLAGS@
239 220
221CAIRO_LIBS= @CAIRO_LIBS@
222CAIRO_CFLAGS= @CAIRO_CFLAGS@
223
240IMAGEMAGICK_LIBS= @IMAGEMAGICK_LIBS@ 224IMAGEMAGICK_LIBS= @IMAGEMAGICK_LIBS@
241IMAGEMAGICK_CFLAGS= @IMAGEMAGICK_CFLAGS@ 225IMAGEMAGICK_CFLAGS= @IMAGEMAGICK_CFLAGS@
242 226
@@ -251,6 +235,9 @@ XRANDR_CFLAGS = @XRANDR_CFLAGS@
251XINERAMA_LIBS = @XINERAMA_LIBS@ 235XINERAMA_LIBS = @XINERAMA_LIBS@
252XINERAMA_CFLAGS = @XINERAMA_CFLAGS@ 236XINERAMA_CFLAGS = @XINERAMA_CFLAGS@
253 237
238XFIXES_LIBS = @XFIXES_LIBS@
239XFIXES_CFLAGS = @XFIXES_CFLAGS@
240
254## widget.o if USE_X_TOOLKIT, otherwise empty. 241## widget.o if USE_X_TOOLKIT, otherwise empty.
255WIDGET_OBJ=@WIDGET_OBJ@ 242WIDGET_OBJ=@WIDGET_OBJ@
256 243
@@ -266,7 +253,7 @@ MSDOS_OBJ =
266MSDOS_X_OBJ = 253MSDOS_X_OBJ =
267 254
268NS_OBJ=@NS_OBJ@ 255NS_OBJ=@NS_OBJ@
269## nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o if HAVE_NS. 256## nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o ns_fontfile if HAVE_NS.
270NS_OBJC_OBJ=@NS_OBJC_OBJ@ 257NS_OBJC_OBJ=@NS_OBJC_OBJ@
271## Only set if NS_IMPL_GNUSTEP. 258## Only set if NS_IMPL_GNUSTEP.
272GNU_OBJC_CFLAGS=@GNU_OBJC_CFLAGS@ 259GNU_OBJC_CFLAGS=@GNU_OBJC_CFLAGS@
@@ -280,8 +267,6 @@ W32_LIBS=@W32_LIBS@
280 267
281## emacs.res if HAVE_W32 268## emacs.res if HAVE_W32
282EMACSRES = @EMACSRES@ 269EMACSRES = @EMACSRES@
283## emacs-*.manifest if HAVE_W32
284EMACS_MANIFEST = @EMACS_MANIFEST@
285## If HAVE_W32, compiler arguments for including 270## If HAVE_W32, compiler arguments for including
286## the resource file in the binary. 271## the resource file in the binary.
287## Cygwin: -Wl,emacs.res 272## Cygwin: -Wl,emacs.res
@@ -291,6 +276,7 @@ W32_RES_LINK=@W32_RES_LINK@
291## Empty if !HAVE_X_WINDOWS 276## Empty if !HAVE_X_WINDOWS
292## xfont.o ftfont.o xftfont.o ftxfont.o if HAVE_XFT 277## xfont.o ftfont.o xftfont.o ftxfont.o if HAVE_XFT
293## xfont.o ftfont.o ftxfont.o if HAVE_FREETYPE 278## xfont.o ftfont.o ftxfont.o if HAVE_FREETYPE
279## ftfont.o ftcrfont.o if USE_CAIRO
294## else xfont.o 280## else xfont.o
295FONT_OBJ=@FONT_OBJ@ 281FONT_OBJ=@FONT_OBJ@
296 282
@@ -307,31 +293,49 @@ LIBSELINUX_LIBS = @LIBSELINUX_LIBS@
307LIBGNUTLS_LIBS = @LIBGNUTLS_LIBS@ 293LIBGNUTLS_LIBS = @LIBGNUTLS_LIBS@
308LIBGNUTLS_CFLAGS = @LIBGNUTLS_CFLAGS@ 294LIBGNUTLS_CFLAGS = @LIBGNUTLS_CFLAGS@
309 295
310LIB_PTHREAD_SIGMASK = @LIB_PTHREAD_SIGMASK@
311
312INTERVALS_H = dispextern.h intervals.h composite.h 296INTERVALS_H = dispextern.h intervals.h composite.h
313 297
314GETLOADAVG_LIBS = @GETLOADAVG_LIBS@ 298GETLOADAVG_LIBS = @GETLOADAVG_LIBS@
315 299
316RUN_TEMACS = `/bin/pwd`/temacs 300RUN_TEMACS = ./temacs
317
318## Invoke ../nt/addsection for MinGW, ":" elsewhere.
319TEMACS_POST_LINK = @TEMACS_POST_LINK@
320ADDSECTION = @ADDSECTION@
321EMACS_HEAPSIZE = @EMACS_HEAPSIZE@
322MINGW_TEMACS_POST_LINK = \
323 mv temacs$(EXEEXT) temacs.tmp; \
324 ../nt/addsection temacs.tmp temacs$(EXEEXT) EMHEAP $(EMACS_HEAPSIZE)
325 301
326UNEXEC_OBJ = @UNEXEC_OBJ@ 302UNEXEC_OBJ = @UNEXEC_OBJ@
327 303
328CANNOT_DUMP=@CANNOT_DUMP@ 304CANNOT_DUMP=@CANNOT_DUMP@
329 305
306# 'make' verbosity.
307AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
308
309AM_V_CC = $(am__v_CC_@AM_V@)
310am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
311am__v_CC_0 = @echo " CC " $@;
312am__v_CC_1 =
313
314AM_V_CCLD = $(am__v_CCLD_@AM_V@)
315am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
316am__v_CCLD_0 = @echo " CCLD " $@;
317am__v_CCLD_1 =
318
319AM_V_GEN = $(am__v_GEN_@AM_V@)
320am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
321am__v_GEN_0 = @echo " GEN " $@;
322am__v_GEN_1 =
323
324AM_V_at = $(am__v_at_@AM_V@)
325am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
326am__v_at_0 = @
327am__v_at_1 =
328
330DEPDIR=deps 329DEPDIR=deps
331## -MMD -MF $(DEPDIR)/$*.d if AUTO_DEPEND; else empty. 330AUTO_DEPEND = @AUTO_DEPEND@
332DEPFLAGS=@DEPFLAGS@ 331
333## ${MKDIR_P} ${DEPDIR} (if AUTO_DEPEND); else ':'. 332ifeq ($(AUTO_DEPEND),yes)
334MKDEPDIR=@MKDEPDIR@ 333DEPFLAGS = -MMD -MF ${DEPDIR}/$*.d -MP
334MKDEPDIR = ${MKDIR_P} ${DEPDIR}
335else
336DEPFLAGS =
337MKDEPDIR = :
338endif
335 339
336## DO NOT use -R. There is a special hack described in lastfile.c 340## DO NOT use -R. There is a special hack described in lastfile.c
337## which is used instead. Some initialized data areas are modified 341## which is used instead. Some initialized data areas are modified
@@ -343,23 +347,24 @@ MKDEPDIR=@MKDEPDIR@
343## 347##
344## FIXME? MYCPPFLAGS only referenced in etc/DEBUG. 348## FIXME? MYCPPFLAGS only referenced in etc/DEBUG.
345ALL_CFLAGS=-Demacs $(MYCPPFLAGS) -I. -I$(srcdir) \ 349ALL_CFLAGS=-Demacs $(MYCPPFLAGS) -I. -I$(srcdir) \
346 -I$(lib) -I$(srcdir)/../lib \ 350 -I$(lib) -I$(top_srcdir)/lib \
347 $(C_SWITCH_MACHINE) $(C_SWITCH_SYSTEM) $(C_SWITCH_X_SITE) \ 351 $(C_SWITCH_MACHINE) $(C_SWITCH_SYSTEM) $(C_SWITCH_X_SITE) \
348 $(GNUSTEP_CFLAGS) $(CFLAGS_SOUND) $(RSVG_CFLAGS) $(IMAGEMAGICK_CFLAGS) \ 352 $(GNUSTEP_CFLAGS) $(CFLAGS_SOUND) $(RSVG_CFLAGS) $(IMAGEMAGICK_CFLAGS) \
349 $(LIBXML2_CFLAGS) $(DBUS_CFLAGS) $(XRANDR_CFLAGS) $(XINERAMA_CFLAGS) \ 353 $(PNG_CFLAGS) $(LIBXML2_CFLAGS) $(DBUS_CFLAGS) \
354 $(XRANDR_CFLAGS) $(XINERAMA_CFLAGS) $(XFIXES_CFLAGS) \
350 $(SETTINGS_CFLAGS) $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) \ 355 $(SETTINGS_CFLAGS) $(FREETYPE_CFLAGS) $(FONTCONFIG_CFLAGS) \
351 $(LIBOTF_CFLAGS) $(M17N_FLT_CFLAGS) $(DEPFLAGS) \ 356 $(LIBOTF_CFLAGS) $(M17N_FLT_CFLAGS) $(DEPFLAGS) \
352 $(LIBGNUTLS_CFLAGS) $(GFILENOTIFY_CFLAGS) \ 357 $(LIBGNUTLS_CFLAGS) $(GFILENOTIFY_CFLAGS) $(CAIRO_CFLAGS) \
353 $(WARN_CFLAGS) $(WERROR_CFLAGS) $(CFLAGS) 358 $(WARN_CFLAGS) $(WERROR_CFLAGS) $(CFLAGS)
354ALL_OBJC_CFLAGS=$(ALL_CFLAGS) $(GNU_OBJC_CFLAGS) 359ALL_OBJC_CFLAGS=$(ALL_CFLAGS) $(GNU_OBJC_CFLAGS)
355 360
356.SUFFIXES: .m 361.SUFFIXES: .m
357.c.o: 362.c.o:
358 @$(MKDEPDIR) 363 @$(MKDEPDIR)
359 $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $(PROFILING_CFLAGS) $< 364 $(AM_V_CC)$(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $(PROFILING_CFLAGS) $<
360.m.o: 365.m.o:
361 @$(MKDEPDIR) 366 @$(MKDEPDIR)
362 $(CC) -c $(CPPFLAGS) $(ALL_OBJC_CFLAGS) $(PROFILING_CFLAGS) $< 367 $(AM_V_CC)$(CC) -c $(CPPFLAGS) $(ALL_OBJC_CFLAGS) $(PROFILING_CFLAGS) $<
363 368
364## lastfile must follow all files whose initialized data areas should 369## lastfile must follow all files whose initialized data areas should
365## be dumped as pure by dump-emacs. 370## be dumped as pure by dump-emacs.
@@ -389,7 +394,7 @@ obj = $(base_obj) $(NS_OBJC_OBJ)
389SOME_MACHINE_OBJECTS = dosfns.o msdos.o \ 394SOME_MACHINE_OBJECTS = dosfns.o msdos.o \
390 xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o fringe.o image.o \ 395 xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o fringe.o image.o \
391 fontset.o dbusbind.o cygw32.o \ 396 fontset.o dbusbind.o cygw32.o \
392 nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \ 397 nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o macfont.o \
393 w32.o w32console.o w32fns.o w32heap.o w32inevt.o w32notify.o \ 398 w32.o w32console.o w32fns.o w32heap.o w32inevt.o w32notify.o \
394 w32menu.o w32proc.o w32reg.o w32select.o w32term.o w32xfns.o \ 399 w32menu.o w32proc.o w32reg.o w32select.o w32term.o w32xfns.o \
395 w16select.o widget.o xfont.o ftfont.o xftfont.o ftxfont.o gtkutil.o \ 400 w16select.o widget.o xfont.o ftfont.o xftfont.o ftxfont.o gtkutil.o \
@@ -418,52 +423,98 @@ otherobj= $(TERMCAP_OBJ) $(PRE_ALLOC_OBJ) $(GMALLOC_OBJ) $(RALLOC_OBJ) \
418FIRSTFILE_OBJ=@FIRSTFILE_OBJ@ 423FIRSTFILE_OBJ=@FIRSTFILE_OBJ@
419ALLOBJS = $(FIRSTFILE_OBJ) $(VMLIMIT_OBJ) $(obj) $(otherobj) 424ALLOBJS = $(FIRSTFILE_OBJ) $(VMLIMIT_OBJ) $(obj) $(otherobj)
420 425
421## Configure inserts the file lisp.mk at this point, defining $lisp. 426all: emacs$(EXEEXT) $(OTHER_FILES)
422@lisp_frag@ 427.PHONY: all
423 428
429## This is the list of all Lisp files that might be loaded into the
430## dumped Emacs. Some of them are not loaded on all platforms, but
431## the DOC file on every platform uses them (because the DOC file is
432## supposed to be platform-independent).
433## Note that this list should not include lisp files which might not
434## be present, like site-load.el and site-init.el; this makefile
435## expects them all to be either present or buildable.
436##
437## To generate this list from loadup.el, we can either:
438## 1) Extract everything matching (load "..."), in which case
439## we need to add charprop.el by hand; or
440## 2) Extract everything matching (load "...", in which case
441## we need to remove leim-list, site-init, and site-load by hand.
442## There's not much to choose between these two approaches,
443## but the second one seems like it could be more future-proof.
444shortlisp =
445lisp.mk: $(lispsource)/loadup.el
446 @rm -f $@
447 ${AM_V_GEN}( printf 'shortlisp = \\\n'; \
448 sed -n 's/^[ \t]*(load "\([^"]*\)".*/\1/p' $< | \
449 sed -e 's/$$/.elc \\/' -e 's/\.el\.elc/.el/'; \
450 echo "" ) > $@
451
452-include lisp.mk
453shortlisp_filter = leim/leim-list.el site-load.elc site-init.elc
454shortlisp := $(filter-out ${shortlisp_filter},${shortlisp})
455## Place loaddefs.el first, so it gets generated first, since it is on
456## the critical path (relevant in parallel compilations).
457## We don't really need to sort, but may as well use it to remove duplicates.
458shortlisp := loaddefs.el loadup.el $(sort ${shortlisp})
459lisp = $(addprefix ${lispsource}/,${shortlisp})
424 460
425## Construct full set of libraries to be linked. 461## Construct full set of libraries to be linked.
426LIBES = $(LIBS) $(W32_LIBS) $(LIBS_GNUSTEP) $(LIBX_BASE) $(LIBIMAGE) \ 462LIBES = $(LIBS) $(W32_LIBS) $(LIBS_GNUSTEP) $(LIBX_BASE) $(LIBIMAGE) \
427 $(LIBX_OTHER) $(LIBSOUND) \ 463 $(LIBX_OTHER) $(LIBSOUND) \
428 $(RSVG_LIBS) $(IMAGEMAGICK_LIBS) $(LIB_ACL) $(LIB_CLOCK_GETTIME) \ 464 $(RSVG_LIBS) $(IMAGEMAGICK_LIBS) $(LIB_ACL) $(LIB_CLOCK_GETTIME) \
429 $(LIB_EACCESS) $(LIB_FDATASYNC) $(LIB_TIMER_TIME) $(DBUS_LIBS) \ 465 $(LIB_EACCESS) $(LIB_FDATASYNC) $(LIB_TIMER_TIME) $(DBUS_LIBS) \
430 $(LIB_EXECINFO) $(XRANDR_LIBS) $(XINERAMA_LIBS) \ 466 $(LIB_EXECINFO) $(XRANDR_LIBS) $(XINERAMA_LIBS) $(XFIXES_LIBS) \
431 $(LIBXML2_LIBS) $(LIBGPM) $(LIBRESOLV) $(LIBS_SYSTEM) \ 467 $(LIBXML2_LIBS) $(LIBGPM) $(LIBRESOLV) $(LIBS_SYSTEM) $(CAIRO_LIBS) \
432 $(LIBS_TERMCAP) $(GETLOADAVG_LIBS) $(SETTINGS_LIBS) $(LIBSELINUX_LIBS) \ 468 $(LIBS_TERMCAP) $(GETLOADAVG_LIBS) $(SETTINGS_LIBS) $(LIBSELINUX_LIBS) \
433 $(FREETYPE_LIBS) $(FONTCONFIG_LIBS) $(LIBOTF_LIBS) $(M17N_FLT_LIBS) \ 469 $(FREETYPE_LIBS) $(FONTCONFIG_LIBS) $(LIBOTF_LIBS) $(M17N_FLT_LIBS) \
434 $(LIBGNUTLS_LIBS) $(LIB_PTHREAD) $(LIB_PTHREAD_SIGMASK) \ 470 $(LIBGNUTLS_LIBS) $(LIB_PTHREAD) \
435 $(GFILENOTIFY_LIBS) $(LIB_MATH) $(LIBZ) 471 $(GFILENOTIFY_LIBS) $(LIB_MATH) $(LIBZ)
436 472
437all: emacs$(EXEEXT) $(OTHER_FILES)
438.PHONY: all
439
440$(leimdir)/leim-list.el: bootstrap-emacs$(EXEEXT) 473$(leimdir)/leim-list.el: bootstrap-emacs$(EXEEXT)
441 cd $(leimdir) && $(MAKE) $(MFLAGS) leim-list.el EMACS=$(bootstrap_exe) 474 $(MAKE) -C ../leim leim-list.el EMACS="$(bootstrap_exe)"
475
476## FORCE it so that admin/unidata can decide whether these files
477## are up-to-date. Although since charprop depends on bootstrap-emacs,
478## and emacs (which recreates bootstrap-emacs) depends on charprop,
479## in practice this rule was always run anyway.
480$(srcdir)/macuvs.h $(lispsource)/international/charprop.el: \
481 bootstrap-emacs$(EXEEXT) FORCE
482 $(MAKE) -C ../admin/unidata all EMACS="../$(bootstrap_exe)"
483
484lispintdir = ${lispsource}/international
485${lispintdir}/cp51932.el ${lispintdir}/eucjp-ms.el: FORCE
486 ${MAKE} -C ../admin/charsets $(notdir $@)
487
488charsets = ${top_srcdir}/admin/charsets/charsets.stamp
489${charsets}: FORCE
490 ${MAKE} -C ../admin/charsets all
491
492charscript = ${lispintdir}/charscript.el
493${charscript}: FORCE
494 $(MAKE) -C ../admin/unidata $(notdir $@)
495
496${lispintdir}/characters.elc: ${charscript:.el=.elc}
442 497
443## The dumped Emacs is as functional and more efficient than 498## The dumped Emacs is as functional and more efficient than
444## bootstrap-emacs, so we replace the latter with the former. 499## bootstrap-emacs, so we replace the latter with the former.
445## Strictly speaking, emacs does not depend directly on all of $lisp, 500## Strictly speaking, emacs does not depend directly on all of $lisp,
446## since not all pieces are used on all platforms. But DOC depends 501## since not all pieces are used on all platforms. But DOC depends
447## on all of $lisp, and emacs depends on DOC, so it is ok to use $lisp here. 502## on all of $lisp, and emacs depends on DOC, so it is ok to use $lisp here.
448emacs$(EXEEXT): temacs$(EXEEXT) $(ADDSECTION) \ 503emacs$(EXEEXT): temacs$(EXEEXT) \
449 $(etc)/DOC $(lisp) $(leimdir)/leim-list.el 504 lisp.mk $(etc)/DOC $(lisp) $(leimdir)/leim-list.el \
450 if test "$(CANNOT_DUMP)" = "yes"; then \ 505 $(lispsource)/international/charprop.el ${charsets}
451 rm -f emacs$(EXEEXT); \ 506ifeq ($(CANNOT_DUMP),yes)
452 ln temacs$(EXEEXT) emacs$(EXEEXT); \ 507 ln -f temacs$(EXEEXT) $@
453 else \ 508else
454 LC_ALL=C $(RUN_TEMACS) -batch -l loadup dump || exit 1; \ 509 LC_ALL=C $(RUN_TEMACS) -batch -l loadup dump
455 test "X$(PAXCTL)" = X || $(PAXCTL) -zex emacs$(EXEEXT); \ 510 $(PAXCTL_if_present) -zex $@
456 rm -f bootstrap-emacs$(EXEEXT); \ 511 ln -f $@ bootstrap-emacs$(EXEEXT)
457 ln emacs$(EXEEXT) bootstrap-emacs$(EXEEXT); \ 512endif
458 fi
459 513
460## We run make-docfile twice because the command line may get too long 514## We run make-docfile twice because the command line may get too long
461## on some systems. The sed command operating on lisp.mk also reduces 515## on some systems. Unfortunately, no-one has any idea
462## the length of the command line. Unfortunately, no-one has any idea
463## exactly how long the maximum safe command line length is on all the 516## exactly how long the maximum safe command line length is on all the
464## various systems that Emacs supports. Obviously, the length depends 517## various systems that Emacs supports.
465## on what your value of $srcdir is. If the length restriction goes
466## away, lisp.mk can be merged back into this file.
467## 518##
468## $(SOME_MACHINE_OBJECTS) comes before $(obj) because some files may 519## $(SOME_MACHINE_OBJECTS) comes before $(obj) because some files may
469## or may not be included in $(obj), but they are always included in 520## or may not be included in $(obj), but they are always included in
@@ -471,100 +522,91 @@ emacs$(EXEEXT): temacs$(EXEEXT) $(ADDSECTION) \
471## for the first time, this prevents any variation between configurations 522## for the first time, this prevents any variation between configurations
472## in the contents of the DOC file. 523## in the contents of the DOC file.
473## 524##
474$(etc)/DOC: $(libsrc)/make-docfile$(EXEEXT) $(obj) $(lisp) 525$(etc)/DOC: lisp.mk $(libsrc)/make-docfile$(EXEEXT) $(obj) $(lisp)
475 $(MKDIR_P) $(etc) 526 $(AM_V_GEN)$(MKDIR_P) $(etc)
476 -rm -f $(etc)/DOC 527 -$(AM_V_at)rm -f $(etc)/DOC
477 $(libsrc)/make-docfile -d $(srcdir) $(SOME_MACHINE_OBJECTS) $(obj) > $(etc)/DOC 528 $(AM_V_at)$(libsrc)/make-docfile -d $(srcdir) \
478 $(libsrc)/make-docfile -a $(etc)/DOC -d $(lispsource) `sed -n -e 's| \\\\||' -e 's|^[ ]*$$(lispsource)/||p' $(srcdir)/lisp.mk` 529 $(SOME_MACHINE_OBJECTS) $(obj) > $(etc)/DOC
530 $(AM_V_at)$(libsrc)/make-docfile -a $(etc)/DOC -d $(lispsource) \
531 $(shortlisp)
479 532
480$(libsrc)/make-docfile$(EXEEXT): 533$(libsrc)/make-docfile$(EXEEXT): $(lib)/libgnu.a
481 cd $(libsrc); $(MAKE) $(MFLAGS) make-docfile$(EXEEXT) 534 $(MAKE) -C $(libsrc) make-docfile$(EXEEXT)
482 535
483buildobj.h: Makefile 536buildobj.h: Makefile
484 for i in $(ALLOBJS); do \ 537 $(AM_V_GEN)for i in $(ALLOBJS); do \
485 echo "$$i" | sed 's,.*/,,; s/\.obj$$/\.o/; s/^/"/; s/$$/",/' \ 538 echo "$$i" | sed 's,.*/,,; s/\.obj$$/\.o/; s/^/"/; s/$$/",/' \
486 || exit; \ 539 || exit; \
487 done >$@.tmp 540 done >$@.tmp
488 mv $@.tmp $@ 541 $(AM_V_at)mv $@.tmp $@
489
490globals.h: gl-stamp; @true
491 542
492GLOBAL_SOURCES = $(base_obj:.o=.c) $(NS_OBJC_OBJ:.o=.m) 543GLOBAL_SOURCES = $(base_obj:.o=.c) $(NS_OBJC_OBJ:.o=.m)
493 544
545AM_V_GLOBALS = $(am__v_GLOBALS_@AM_V@)
546am__v_GLOBALS_ = $(am__v_GLOBALS_@AM_DEFAULT_V@)
547am__v_GLOBALS_0 = @echo " GEN " globals.h;
548am__v_GLOBALS_1 =
549
494gl-stamp: $(libsrc)/make-docfile$(EXEEXT) $(GLOBAL_SOURCES) 550gl-stamp: $(libsrc)/make-docfile$(EXEEXT) $(GLOBAL_SOURCES)
495 $(libsrc)/make-docfile -d $(srcdir) -g $(obj) > gl.tmp 551 $(AM_V_GLOBALS)$(libsrc)/make-docfile -d $(srcdir) -g $(obj) > globals.tmp
496 $(srcdir)/../build-aux/move-if-change gl.tmp globals.h 552 $(AM_V_at)$(top_srcdir)/build-aux/move-if-change globals.tmp globals.h
497 echo timestamp > $@ 553 $(AM_V_at)echo timestamp > $@
554
555globals.h: gl-stamp; @true
498 556
499$(ALLOBJS): globals.h 557$(ALLOBJS): globals.h
500 558
501$(lib)/libgnu.a: $(config_h) 559$(lib)/libgnu.a: $(config_h)
502 cd $(lib) && $(MAKE) libgnu.a 560 $(MAKE) -C $(lib) all
503 561
504## We have to create $(etc) here because init_cmdargs tests its 562## We have to create $(etc) here because init_cmdargs tests its
505## existence when setting Vinstallation_directory (FIXME?). 563## existence when setting Vinstallation_directory (FIXME?).
506## This goes on to affect various things, and the emacs binary fails 564## This goes on to affect various things, and the emacs binary fails
507## to start if Vinstallation_directory has the wrong value. 565## to start if Vinstallation_directory has the wrong value.
508temacs$(EXEEXT): stamp-oldxmenu $(ALLOBJS) \ 566temacs$(EXEEXT): $(LIBXMENU) $(ALLOBJS) \
509 $(lib)/libgnu.a $(EMACSRES) 567 $(lib)/libgnu.a $(EMACSRES) ${charsets} ${charscript}
510 $(CC) $(ALL_CFLAGS) $(TEMACS_LDFLAGS) $(LDFLAGS) \ 568 $(AM_V_CCLD)$(CC) $(ALL_CFLAGS) $(TEMACS_LDFLAGS) $(LDFLAGS) \
511 -o temacs $(ALLOBJS) $(lib)/libgnu.a $(W32_RES_LINK) $(LIBES) 569 -o temacs $(ALLOBJS) $(lib)/libgnu.a $(W32_RES_LINK) $(LIBES)
512 $(MKDIR_P) $(etc) 570 $(MKDIR_P) $(etc)
513 $(TEMACS_POST_LINK) 571ifneq ($(CANNOT_DUMP),yes)
514 test "$(CANNOT_DUMP)" = "yes" || \ 572 $(PAXCTL_if_present) -r $@
515 test "X$(PAXCTL)" = X || $(PAXCTL) -r temacs$(EXEEXT) 573 $(SETFATTR_if_present) -n user.pax.flags -v er $@
574endif
516 575
517## The following oldxmenu-related rules are only (possibly) used if 576## The following oldxmenu-related rules are only (possibly) used if
518## HAVE_X11 && !USE_GTK, but there is no harm in always defining them 577## HAVE_X11 && !USE_GTK, but there is no harm in always defining them.
519## (provided we take a little care that OLDXMENU is never empty). 578$(lwlibdir)/liblw.a: $(config_h) globals.h lisp.h FORCE
520really-lwlib: globals.h 579 $(MAKE) -C $(lwlibdir) liblw.a
521 cd $(lwlibdir); $(MAKE) $(MFLAGS) \ 580$(oldXMenudir)/libXMenu11.a: FORCE
522 CC='$(CC)' CFLAGS='$(CFLAGS)' MAKE='$(MAKE)' 581 $(MAKE) -C $(oldXMenudir) libXMenu11.a
523 @true # make -t should not create really-lwlib. 582FORCE:
524.PHONY: really-lwlib 583.PHONY: FORCE
525 584
526really-oldXMenu: 585ACLOCAL_INPUTS = $(top_srcdir)/configure.ac $(top_srcdir)/m4/*.m4
527 cd $(oldXMenudir); $(MAKE) $(MFLAGS) \ 586AUTOCONF_INPUTS = $(top_srcdir)/configure.ac $(top_srcdir)/aclocal.m4
528 CC='$(CC)' CFLAGS='$(CFLAGS)' MAKE='$(MAKE)' 587$(top_srcdir)/aclocal.m4: $(ACLOCAL_INPUTS)
529 @true # make -t should not create really-oldXMenu. 588$(top_srcdir)/configure config.in: $(AUTOCONF_INPUTS)
530.PHONY: really-oldXMenu 589.PRECIOUS: ../config.status Makefile
531 590../config.status: $(top_srcdir)/configure $(top_srcdir)/lisp/version.el
532## We do not really need this when OLDXMENU_DEPS is empty, but as 591Makefile: ../config.status $(srcdir)/Makefile.in
533## things stand we need something to satisfy the temacs dependency. 592$(top_srcdir)/aclocal.m4 $(top_srcdir)/configure config.in ../config.status \
534stamp-oldxmenu: $(OLDXMENU_DEPS) 593 Makefile:
535 touch stamp-oldxmenu 594 $(MAKE) -C .. am--refresh
536
537## Supply an ordering for parallel make.
538../src/$(OLDXMENU): $(OLDXMENU)
539
540$(OLDXMENU): $(OLDXMENU_TARGET)
541
542../config.status:: epaths.in
543 @echo "The file epaths.h needs to be set up from epaths.in."
544 @echo "Please run the `configure' script again."
545 exit 1
546
547../config.status:: config.in
548 @echo "The file config.h needs to be set up from config.in."
549 @echo "Please run the `configure' script again."
550 exit 1
551 595
552doc.o: buildobj.h 596doc.o: buildobj.h
553 597
554emacs.res: $(ntsource)/emacs.rc \ 598emacs.res: FORCE
555 $(ntsource)/icons/emacs.ico \ 599 $(MAKE) -C ../nt ../src/emacs.res
556 $(ntsource)/$(EMACS_MANIFEST)
557 $(WINDRES) -O COFF --include-dir=$(srcdir)/../nt \
558 -o $@ $(ntsource)/emacs.rc
559 600
601.PHONY: ns-app
560ns-app: emacs$(EXEEXT) 602ns-app: emacs$(EXEEXT)
561 cd ../nextstep && $(MAKE) $(MFLAGS) all 603 $(MAKE) -C ../nextstep all
562 604
563.PHONY: mostlyclean clean bootstrap-clean distclean maintainer-clean 605.PHONY: mostlyclean clean bootstrap-clean distclean maintainer-clean
564.PHONY: versionclean extraclean frc 606.PHONY: versionclean extraclean
565 607
566mostlyclean: 608mostlyclean:
567 rm -f temacs$(EXEEXT) core *.core \#* *.o libXMenu11.a liblw.a 609 rm -f temacs$(EXEEXT) core *.core \#* *.o
568 rm -f ../etc/DOC 610 rm -f ../etc/DOC
569 rm -f bootstrap-emacs$(EXEEXT) emacs-$(version)$(EXEEXT) 611 rm -f bootstrap-emacs$(EXEEXT) emacs-$(version)$(EXEEXT)
570 rm -f buildobj.h 612 rm -f buildobj.h
@@ -578,46 +620,53 @@ clean: mostlyclean
578## It should remove all files generated during a compilation/bootstrap, 620## It should remove all files generated during a compilation/bootstrap,
579## but not things like config.status or TAGS. 621## but not things like config.status or TAGS.
580bootstrap-clean: clean 622bootstrap-clean: clean
581 rm -f epaths.h config.h config.stamp stamp-h1 stamp-oldxmenu 623 rm -f epaths.h config.h config.stamp stamp-h1
582 if test -f ./.gdbinit; then \ 624 if test -f ./.gdbinit; then \
583 mv ./.gdbinit ./.gdbinit.save; \ 625 mv ./.gdbinit ./.gdbinit.save; \
584 if test -f "$(srcdir)/.gdbinit"; then rm -f ./.gdbinit.save; \ 626 if test -f "$(srcdir)/.gdbinit"; then rm -f ./.gdbinit.save; \
585 else mv ./.gdbinit.save ./.gdbinit; fi; \ 627 else mv ./.gdbinit.save ./.gdbinit; fi; \
586 fi 628 fi
587## This is used in making a distribution. 629
588## Do not use it on development directories!
589distclean: bootstrap-clean 630distclean: bootstrap-clean
590 rm -f Makefile 631 rm -f Makefile lisp.mk
632
591maintainer-clean: distclean 633maintainer-clean: distclean
592 @echo "This command is intended for maintainers to use;"
593 @echo "it deletes files that may require special tools to rebuild."
594 rm -f TAGS 634 rm -f TAGS
595versionclean: 635versionclean:
596 -rm -f emacs$(EXEEXT) emacs-*.*.*$(EXEEXT) ../etc/DOC* 636 -rm -f emacs$(EXEEXT) emacs-*.*.*$(EXEEXT) ../etc/DOC*
597extraclean: distclean 637extraclean: distclean
598 -rm -f *~ \#* m/?*~ s/?*~ 638 -rm -f *~ \#*
639
599 640
600## Arrange to make a tags table TAGS-LISP for ../lisp, 641ETAGS = ../lib-src/etags
601## plus TAGS for the C files, which includes ../lisp/TAGS by reference.
602 642
603ctagsfiles1 = [xyzXYZ]*.[hc] 643ctagsfiles1 = [xyzXYZ]*.[hc]
604ctagsfiles2 = [a-wA-W]*.[hc] 644ctagsfiles2 = [a-wA-W]*.[hc]
605ctagsfiles3 = [a-zA-Z]*.m 645ctagsfiles3 = [a-zA-Z]*.m
606 646
607TAGS: $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2) $(S_FILE) 647## FIXME? In out-of-tree builds, should TAGS be generated in srcdir?
608 ../lib-src/etags --include=TAGS-LISP --include=$(lwlibdir)/TAGS \ 648
609 --regex='{c}/[ ]*DEFVAR_[A-Z_ (]+"\([^"]+\)"/' \ 649## This does not need to depend on ../lisp and ../lwlib TAGS files,
610 $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2) $(S_FILE) \ 650## because etags "--include" only includes a pointer to the file,
611 --regex='{objc}/[ ]*DEFVAR_[A-Z_ (]+"\([^"]+\)"/' \ 651## rather than the file contents.
652TAGS: $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2) $(srcdir)/$(ctagsfiles3)
653 "$(ETAGS)" --include=../lisp/TAGS --include=$(lwlibdir)/TAGS \
654 --regex='{c}/[ ]*DEFVAR_[A-Z_ (]+"\([^"]+\)"/\1/' \
655 --regex='{c}/[ ]*DEFVAR_[A-Z_ (]+"[^"]+",[ ]\([A-Za-z0-9_]+\)/\1/' \
656 $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2) \
657 --regex='{objc}/[ ]*DEFVAR_[A-Z_ (]+"\([^"]+\)"/\1/' \
658 --regex='{objc}/[ ]*DEFVAR_[A-Z_ (]+"[^"]+",[ ]\([A-Za-z0-9_]+\)/\1/' \
612 $(srcdir)/$(ctagsfiles3) 659 $(srcdir)/$(ctagsfiles3)
613frc: 660
614TAGS-LISP: frc 661## Arrange to make tags tables for ../lisp and ../lwlib,
615 $(MAKE) -f $(lispdir)/Makefile TAGS-LISP ETAGS=../lib-src/etags 662## which the above TAGS file for the C files includes by reference.
663../lisp/TAGS:
664 $(MAKE) -C ../lisp TAGS ETAGS="$(ETAGS)"
616 665
617$(lwlibdir)/TAGS: 666$(lwlibdir)/TAGS:
618 (cd $(lwlibdir); $(MAKE) -f $(lwlibdir)/Makefile tags ETAGS=../lib-src/etags) 667 $(MAKE) -C $(lwlibdir) TAGS ETAGS="$(ETAGS)"
619 668
620tags: TAGS TAGS-LISP $(lwlibdir)/TAGS 669tags: TAGS ../lisp/TAGS $(lwlibdir)/TAGS
621.PHONY: tags 670.PHONY: tags
622 671
623 672
@@ -628,57 +677,48 @@ tags: TAGS TAGS-LISP $(lwlibdir)/TAGS
628## such as loaddefs.el or *.elc can typically be produced by any old 677## such as loaddefs.el or *.elc can typically be produced by any old
629## Emacs executable, so we would like to avoid rebuilding them whenever 678## Emacs executable, so we would like to avoid rebuilding them whenever
630## we build a new Emacs executable. 679## we build a new Emacs executable.
680##
681## (In other words, changing a single file src/foo.c would force
682## dumping a new bootstrap-emacs, then re-byte-compiling all preloaded
683## elisp files, and only then dump the actual src/emacs, which is not
684## wrong, but is overkill in 99.99% of the cases.)
685##
631## To solve the circularity, we use 2 different Emacs executables, 686## To solve the circularity, we use 2 different Emacs executables,
632## "emacs" is the main target and "bootstrap-emacs" is the one used 687## "emacs" is the main target and "bootstrap-emacs" is the one used
633## to build the *.elc and loaddefs.el files. 688## to build the *.elc and loaddefs.el files.
634## To solve the freshness issue, we used to use a third file "witness-emacs" 689## To solve the freshness issue, in the past we tried various clever tricks,
635## which was used to witness the fact that there is a bootstrap-emacs 690## but now that we require GNU make, we can simply specify
636## executable, and then have dependencies on witness-emacs rather than 691## bootstrap-emacs$(EXEEXT) as an order-only prerequisite.
637## bootstrap-emacs, but that lead to problems in parallel builds (because 692
638## witness-emacs needed to be free from dependencies (to avoid rebuilding 693%.elc: %.el | bootstrap-emacs$(EXEEXT)
639## it), so it was compiled in parallel, leading typically to having 2 694 @$(MAKE) -C ../lisp EMACS="$(bootstrap_exe)" THEFILE=$< $<c
640## processes dumping bootstrap-emacs at the same time).
641## So instead, we replace the witness-emacs dependencies by conditional
642## bootstrap-dependencies (via $(BOOTSTRAPEMACS)). Of course, since we do
643## not want to rely on GNU Make features, we have to rely on an external
644## script to do the conditional part of the dependency
645## (i.e. see the $(SUBDIR) rule ../Makefile.in).
646
647.SUFFIXES: .elc .el
648
649## These suffix rules do not allow additional dependencies, sadly, so
650## instead of adding a $(BOOTSTRAPEMACS) dependency here, we add it
651## separately below.
652## With GNU Make, we would just say "%.el : %.elc $(BOOTSTRAPEMACS)"
653.el.elc:
654 @cd ../lisp; $(MAKE) $(MFLAGS) compile-onefile \
655 THEFILE=$< EMACS=$(bootstrap_exe)
656
657## Since the .el.elc rule cannot specify an extra dependency, we do it here.
658$(lisp): $(BOOTSTRAPEMACS)
659 695
660## VCSWITNESS points to the file that holds info about the current checkout. 696## VCSWITNESS points to the file that holds info about the current checkout.
661## We use it as a heuristic to decide when to rebuild loaddefs.el. 697## We use it as a heuristic to decide when to rebuild loaddefs.el.
662$(lispsource)/loaddefs.el: $(BOOTSTRAPEMACS) $(VCSWITNESS) 698## If empty it is ignored; the parent makefile can set it to some other value.
663 cd ../lisp; $(MAKE) $(MFLAGS) autoloads EMACS=$(bootstrap_exe) 699VCSWITNESS =
700
701$(lispsource)/loaddefs.el: $(VCSWITNESS) | bootstrap-emacs$(EXEEXT)
702 $(MAKE) -C ../lisp autoloads EMACS="$(bootstrap_exe)"
664 703
665## Dump an Emacs executable named bootstrap-emacs containing the 704## Dump an Emacs executable named bootstrap-emacs containing the
666## files from loadup.el in source form. 705## files from loadup.el in source form.
667bootstrap-emacs$(EXEEXT): temacs$(EXEEXT) 706bootstrap-emacs$(EXEEXT): temacs$(EXEEXT)
668 cd ../lisp; $(MAKE) $(MFLAGS) update-subdirs 707 $(MAKE) -C ../lisp update-subdirs
669 if test "$(CANNOT_DUMP)" = "yes"; then \ 708ifeq ($(CANNOT_DUMP),yes)
670 rm -f bootstrap-emacs$(EXEEXT); \ 709 ln -f temacs$(EXEEXT) $@
671 ln temacs$(EXEEXT) bootstrap-emacs$(EXEEXT); \ 710else
672 else \ 711 $(RUN_TEMACS) --batch --load loadup bootstrap
673 $(RUN_TEMACS) --batch --load loadup bootstrap || exit 1; \ 712 $(PAXCTL_if_present) -zex emacs$(EXEEXT)
674 test "X$(PAXCTL)" = X || $(PAXCTL) -zex emacs$(EXEEXT); \ 713 mv -f emacs$(EXEEXT) $@
675 mv -f emacs$(EXEEXT) bootstrap-emacs$(EXEEXT); \ 714endif
676 fi
677 @: Compile some files earlier to speed up further compilation. 715 @: Compile some files earlier to speed up further compilation.
678 cd ../lisp; $(MAKE) $(MFLAGS) compile-first EMACS=$(bootstrap_exe) 716 $(MAKE) -C ../lisp compile-first EMACS="$(bootstrap_exe)"
679
680## Insert either autodeps.mk (if AUTO_DEPEND), else deps.mk.
681@deps_frag@
682 717
718ifeq ($(AUTO_DEPEND),yes)
719-include $(ALLOBJS:%.o=${DEPDIR}/%.d)
720else
721include $(srcdir)/deps.mk
722endif
683 723
684### Makefile.in ends here 724### Makefile.in ends here