Reduce CPP usage.
[bpt/emacs.git] / src / Makefile.in
1 # Makefile for GNU Emacs.
2 # Copyright (C) 1985, 1987, 1988, 1993, 1994, 1995, 1999, 2000, 2001, 2002,
3 # 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
4 # Free Software Foundation, Inc.
5
6 # This file is part of GNU Emacs.
7
8 # GNU Emacs is free software: you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation, either version 3 of the License, or
11 # (at your option) any later version.
12
13 # GNU Emacs is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
17
18 # You should have received a copy of the GNU General Public License
19 # along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
20
21
22 # Note that this file is edited by msdos/sed1v2.inp for MSDOS. That
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.
25
26 # Don't try to replace the cpp processing using autoconf facilities,
27 # says rms.
28 # Replacing a particular part of the conditionals to work via autoconf
29 # is OK.
30 # Some of the conditionals might be dead now. Finding them and
31 # deleting them would be fine.
32
33
34 # Here are the things that we expect ../configure to edit.
35 # We use $(srcdir) explicitly in dependencies so as not to depend on VPATH.
36 srcdir = @srcdir@
37 abs_builddir = @abs_builddir@
38 VPATH = $(srcdir)
39 CC = @CC@
40 CPP = @CPP@
41 CFLAGS = @CFLAGS@
42 CPPFLAGS = @CPPFLAGS@
43 LDFLAGS = @LDFLAGS@
44 LN_S = @LN_S@
45 EXEEXT = @EXEEXT@
46 version = @version@
47 # Substitute an assignment for the MAKE variable, because
48 # BSD doesn't have it as a default.
49 @SET_MAKE@
50 # Don't use LIBS. configure puts stuff in it that either shouldn't be
51 # linked with Emacs or is duplicated by the cpp stuff below.
52 # LIBS = @LIBS@
53 LIBOBJS = @LIBOBJS@
54
55 lispsource = ${srcdir}/../lisp/
56 libsrc = ../lib-src/
57 etc = ../etc/
58 oldXMenudir = ../oldXMenu/
59 lwlibdir = ../lwlib/
60 lispdir = ../lisp/
61
62 # Configuration files for .o files to depend on.
63 M_FILE = ${srcdir}/@machfile@
64 S_FILE = ${srcdir}/@opsysfile@
65 config_h = config.h $(M_FILE) $(S_FILE)
66
67 bootstrap_exe = ${abs_builddir}/bootstrap-emacs${EXEEXT}
68
69 OTHER_FILES = @OTHER_FILES@
70
71 CRT_DIR=@CRT_DIR@
72
73 LIBTIFF=@LIBTIFF@
74 LIBJPEG=@LIBJPEG@
75 LIBPNG=@LIBPNG@
76 LIBGIF=@LIBGIF@
77 LIBXPM=@LIBXPM@
78 XFT_LIBS=@XFT_LIBS@
79
80 DBUS_CFLAGS = @DBUS_CFLAGS@
81 DBUS_LIBS = @DBUS_LIBS@
82 DBUS_OBJ = @DBUS_OBJ@
83
84 GCONF_CFLAGS = @GCONF_CFLAGS@
85 GCONF_LIBS = @GCONF_LIBS@
86
87 GTK_OBJ=@GTK_OBJ@
88
89 LIBXP=@LIBXP@
90 LIBXSM=@LIBXSM@
91
92 XMENU_OBJ=@XMENU_OBJ@
93 XOBJ=@XOBJ@
94
95 LUCID_LIBW=@LUCID_LIBW@
96
97 LIBSOUND= @LIBSOUND@
98 CFLAGS_SOUND= @CFLAGS_SOUND@
99
100 RSVG_LIBS= @RSVG_LIBS@
101 RSVG_CFLAGS= @RSVG_CFLAGS@
102
103 ## widget.o if USE_X_TOOLKIT, otherwise empty.
104 WIDGET_OBJ=@WIDGET_OBJ@
105
106 LIBSELINUX_LIBS = @LIBSELINUX_LIBS@
107
108 INTERVALS_H = dispextern.h intervals.h composite.h
109
110 GETLOADAVG_LIBS = @GETLOADAVG_LIBS@
111
112 RUN_TEMACS = `/bin/pwd`/temacs
113
114 # ========================== start of cpp stuff =======================
115 /* From here on, comments must be done in C syntax. */
116
117 /* just to be sure the sh is used */
118 SHELL=/bin/sh
119
120 #define THIS_IS_MAKEFILE
121 #define NOT_C_CODE
122 #include "config.h"
123
124 #ifdef AUTO_DEPEND
125 DEPFLAGS = -MMD -MF deps/$*.d
126 #endif
127
128 /* Do not let the file name mktime.c get messed up. */
129 #ifdef mktime
130 #undef mktime
131 #endif
132
133 /* Use HAVE_X11 as an alias for X11 in this file
134 to avoid problems with X11 as a subdirectory name
135 in -I and other such options which pass through this file. */
136
137 #ifdef X11
138 #define HAVE_X11
139 #undef X11
140 #endif
141
142 /* On some machines #define register is done in config;
143 do not let it interfere with this file. */
144 #undef register
145
146 /* Some machines do not find the standard C libraries in the usual place. */
147 #ifndef ORDINARY_LINK
148 #ifndef LIB_STANDARD
149 #define LIB_STANDARD -lc
150 #endif
151 #else
152 #ifndef LIB_STANDARD
153 #define LIB_STANDARD
154 #endif
155 #endif
156
157 /* Under GNUstep, putting libc on the link line causes problems. */
158 #ifdef NS_IMPL_GNUSTEP
159 #undef LIB_STANDARD
160 #define LIB_STANDARD
161 #endif
162
163 /* Some s/SYSTEM.h files define this to request special libraries. */
164 #ifndef LIBS_SYSTEM
165 #define LIBS_SYSTEM
166 #endif
167
168 /* Some s/SYSTEM.h files define this to request special switches in ld. */
169 #ifndef LD_SWITCH_SYSTEM
170 #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
171 #define LD_SWITCH_SYSTEM -X
172 #else /* (defined (BSD_SYSTEM) && !defined (COFF)) */
173 #define LD_SWITCH_SYSTEM
174 #endif /* (defined (BSD_SYSTEM) && !defined (COFF)) */
175 #endif /* LD_SWITCH_SYSTEM */
176
177 /* This holds special options for linking temacs
178 that should be used for linking anything else. */
179 #ifndef LD_SWITCH_SYSTEM_TEMACS
180 #define LD_SWITCH_SYSTEM_TEMACS
181 #endif
182
183 /* Some m/MACHINE.h files define this to request special switches in ld. */
184 #ifndef LD_SWITCH_MACHINE
185 #define LD_SWITCH_MACHINE
186 #endif
187
188 /* These macros are for switches specifically related to X Windows. */
189 #ifndef LD_SWITCH_X_SITE
190 #define LD_SWITCH_X_SITE
191 #endif
192
193 STARTFILES = START_FILES
194
195
196 #ifdef NS_IMPL_GNUSTEP
197 /* Pull in stuff from GNUstep-make. */
198 FOUNDATION_LIB=gnu
199 GUI_LIB=gnu
200 include @GNUSTEP_MAKEFILES@/Additional/base.make
201 include @GNUSTEP_MAKEFILES@/Additional/gui.make
202 shared=no
203 #endif
204
205 /* DO NOT use -R. There is a special hack described in lastfile.c
206 which is used instead. Some initialized data areas are modified
207 at initial startup, then labeled as part of the text area when
208 Emacs is dumped for the first time, and never changed again. */
209
210 /* -Demacs is needed to make some files produce the correct version
211 for use in Emacs.
212
213 -DHAVE_CONFIG_H is needed for some other files to take advantage of
214 the information in ``config.h''. */
215
216 /* C_SWITCH_X_SITE must come before C_SWITCH_X_SYSTEM
217 since it may have -I options that should override those two. */
218 ALL_CFLAGS=-Demacs -DHAVE_CONFIG_H $(MYCPPFLAGS) -I. -I${srcdir} @c_switch_machine@ @c_switch_system@ @C_SWITCH_X_SITE@ @C_SWITCH_X_SYSTEM@ ${CFLAGS_SOUND} ${RSVG_CFLAGS} ${DBUS_CFLAGS} ${GCONF_CFLAGS} ${CFLAGS} @FREETYPE_CFLAGS@ @FONTCONFIG_CFLAGS@ @LIBOTF_CFLAGS@ @M17N_FLT_CFLAGS@ ${DEPFLAGS}
219 ALL_OBJC_CFLAGS=$(ALL_CFLAGS) @GNU_OBJC_CFLAGS@
220
221 .SUFFIXES: .m
222 .c.o:
223 #ifdef AUTO_DEPEND
224 @-test -d deps || mkdir deps
225 #endif
226 $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) $<
227 .m.o:
228 #ifdef AUTO_DEPEND
229 @-test -d deps || mkdir deps
230 #endif
231 $(CC) -c $(CPPFLAGS) $(ALL_OBJC_CFLAGS) $<
232
233 #ifdef HAVE_X_WINDOWS
234 #ifdef HAVE_MENUS
235
236 /* The X Menu stuff is present in the X10 distribution, but missing
237 from X11. If we have X10, just use the installed library;
238 otherwise, use our own copy. */
239 #ifdef HAVE_X11
240 #ifdef USE_X_TOOLKIT
241 OLDXMENU=${lwlibdir}liblw.a
242 LIBXMENU= $(OLDXMENU)
243 #else /* not USE_X_TOOLKIT */
244 OLDXMENU= ${oldXMenudir}libXMenu11.a
245 LIBXMENU= $(OLDXMENU)
246 #endif /* not USE_X_TOOLKIT */
247 #else /* not HAVE_X11 */
248 LIBXMENU= -lXMenu
249 #endif /* not HAVE_X11 */
250
251 #else /* not HAVE_MENUS */
252
253 /* Otherwise, do not worry about the menu library at all. */
254 LIBXMENU=
255 #endif /* not HAVE_MENUS */
256
257 #ifdef USE_X_TOOLKIT
258 # define @X_TOOLKIT_TYPE@
259 # ifdef LIB_MOTIF
260 MOTIF_LIBW= LIB_MOTIF $(LIBXP)
261 # else
262 MOTIF_LIBW= -lXm $(LIBXP)
263 # endif
264 LIBW=$(@X_TOOLKIT_TYPE@_LIBW)
265
266 #ifdef HAVE_X11XTR6
267 #ifdef NEED_LIBW
268 LIBXTR6 = -lSM -lICE -lw
269 #else
270 LIBXTR6 = -lSM -lICE
271 #endif
272 #endif
273
274 #ifndef LIBXMU
275 #define LIBXMU -lXmu
276 #endif
277
278 LIBXT= $(LIBW) LIBXMU -lXt $(LIBXTR6) -lXext
279
280 #else /* not USE_X_TOOLKIT */
281
282 #ifdef USE_GTK
283 LIBW=@GTK_LIBS@
284 OLDXMENU=
285 LIBXMENU=
286 #endif /* USE_GTK */
287
288 LIBXT=$(LIBW) $(LIBXSM)
289 #endif /* not USE_X_TOOLKIT */
290
291 #ifdef HAVE_X11
292 X11_LDFLAGS = LD_SWITCH_X_SITE
293 LIBX= $(LIBXMENU) $(X11_LDFLAGS) $(LIBXT) $(LIBTIFF) $(LIBJPEG) $(LIBPNG) $(LIBGIF) $(LIBXPM) -lX11 $(XFT_LIBS)
294 #else /* not HAVE_X11 */
295 LIBX= $(LIBXMENU) LD_SWITCH_X_SITE
296 #endif /* not HAVE_X11 */
297 #endif /* not HAVE_X_WINDOWS */
298
299 #ifndef ORDINARY_LINK
300 /* Fix linking if compiled with GCC. */
301 #ifdef __GNUC__
302
303 #ifdef LINKER
304 #define LINKER_WAS_SPECIFIED
305 #endif
306
307 /* Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
308 places that are difficult to figure out at make time. Fortunately,
309 these same versions allow you to pass arbitrary flags on to the
310 linker, so there is no reason not to use it as a linker.
311
312 Well, it is not quite perfect. The "-nostdlib" keeps GCC from
313 searching for libraries in its internal directories, so we have to
314 ask GCC explicitly where to find libgcc.a. */
315
316 #ifndef LINKER
317 #define LINKER $(CC) -nostdlib
318 #endif
319
320 #ifndef LIB_GCC
321 /* Ask GCC where to find libgcc.a. */
322 #define LIB_GCC `$(CC) -print-libgcc-file-name`
323 #endif /* not LIB_GCC */
324
325 GNULIB_VAR = LIB_GCC
326
327 #ifndef LINKER_WAS_SPECIFIED
328 /* GCC passes any argument prefixed with -Xlinker directly to the
329 linker. See prefix-args.c for an explanation of why we do not do
330 this with the shell''s ``for'' construct.
331 Note that some people do not have '.' in their paths, so we must
332 use ./prefix-args. */
333 #define YMF_PASS_LDFLAGS(flags) `./prefix-args -Xlinker flags`
334 #else
335 #define YMF_PASS_LDFLAGS(flags) flags
336 #endif
337
338 #else /* not __GNUC__ */
339 GNULIB_VAR =
340
341 #endif /* not __GNUC__ */
342 #endif /* not ORDINARY_LINK */
343
344 #ifdef ORDINARY_LINK
345 LD = $(CC)
346 #else
347 #ifdef LINKER
348 LD=LINKER
349 #else /* not LINKER */
350 LD=ld
351 #endif /* not LINKER */
352 #endif /* not ORDINARY_LINK */
353
354 /* Flags to pass to LD only for temacs. */
355 /* Do not split this line with a backslash. That can cause trouble with
356 some cpps. */
357 TEMACS_LDFLAGS = LD_SWITCH_SYSTEM LD_SWITCH_SYSTEM_TEMACS LD_SWITCH_MACHINE
358
359 /* A macro which other sections of Makefile can redefine to munge the
360 flags before they are passed to LD. This is helpful if you have
361 redefined LD to something odd, like "gcc".
362 (The YMF prefix is a holdover from the old name "ymakefile".)
363 */
364 #ifndef YMF_PASS_LDFLAGS
365 #define YMF_PASS_LDFLAGS(flags) flags
366 #endif
367
368 #ifdef MSDOS
369 #ifdef HAVE_X_WINDOWS
370 MSDOS_OBJ = dosfns.o msdos.o xmenu.o
371 #else
372 MSDOS_OBJ = dosfns.o msdos.o w16select.o xmenu.o termcap.o
373 #endif
374 #endif
375
376 #ifdef CYGWIN
377 CYGWIN_OBJ = sheap.o
378 #endif
379
380 #ifdef HAVE_NS
381 ns_appdir=@ns_appdir@/
382 ns_appbindir=@ns_appbindir@/
383 ns_appresdir=@ns_appresdir@/
384 ns_appsrc=@ns_appsrc@
385 /* Object files for NeXTstep */
386 NS_OBJ= nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \
387 fontset.o fringe.o image.o
388 #endif /* HAVE_NS */
389
390 #ifdef HAVE_WINDOW_SYSTEM
391 #ifdef HAVE_X_WINDOWS
392 #if defined (HAVE_XFT)
393 FONT_DRIVERS = xfont.o ftfont.o xftfont.o ftxfont.o
394 #elif defined (HAVE_FREETYPE)
395 FONT_DRIVERS = xfont.o ftfont.o ftxfont.o
396 #else /* ! defined (HAVE_XFT) && ! defined (HAVE_FREETYPE) */
397 FONT_DRIVERS = xfont.o
398 #endif /* ! defined (HAVE_XFT) && ! defined (HAVE_FREETYPE) */
399 #endif /* HAVE_X_WINDOWS */
400 #endif /* HAVE_WINDOW_SYSTEM */
401
402 /* lastfile must follow all files
403 whose initialized data areas should be dumped as pure by dump-emacs. */
404 obj= dispnew.o frame.o scroll.o xdisp.o menu.o $(XMENU_OBJ) window.o \
405 charset.o coding.o category.o ccl.o character.o chartab.o bidi.o \
406 cm.o term.o terminal.o xfaces.o $(XOBJ) $(GTK_OBJ) $(DBUS_OBJ) \
407 emacs.o keyboard.o macros.o keymap.o sysdep.o \
408 buffer.o filelock.o insdel.o marker.o \
409 minibuf.o fileio.o dired.o filemode.o \
410 cmds.o casetab.o casefiddle.o indent.o search.o regex.o undo.o \
411 alloc.o data.o doc.o editfns.o callint.o \
412 eval.o floatfns.o fns.o font.o print.o lread.o \
413 syntax.o @unexec@ bytecode.o \
414 process.o callproc.o \
415 region-cache.o sound.o atimer.o \
416 doprnt.o strftime.o intervals.o textprop.o composite.o md5.o \
417 $(MSDOS_OBJ) $(NS_OBJ) $(CYGWIN_OBJ) $(FONT_DRIVERS)
418
419 /* Object files used on some machine or other.
420 These go in the DOC file on all machines
421 in case they are needed there. */
422 SOME_MACHINE_OBJECTS = dosfns.o msdos.o \
423 xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o fringe.o image.o \
424 fontset.o dbusbind.o \
425 nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \
426 w32.o w32console.o w32fns.o w32heap.o w32inevt.o \
427 w32menu.o w32proc.o w32reg.o w32select.o w32term.o w32xfns.o $(FONT_DRIVERS)
428
429
430 #ifdef TERMINFO
431 /* Used to be -ltermcap here. If your machine needs that,
432 define LIBS_TERMCAP in the m/MACHINE.h file. */
433 #ifndef LIBS_TERMCAP
434 #define LIBS_TERMCAP -lcurses
435 #endif /* LIBS_TERMCAP */
436 termcapobj = terminfo.o
437 #else /* ! defined (TERMINFO) */
438 #ifndef LIBS_TERMCAP
439 #define LIBS_TERMCAP
440 #endif /* LIBS_TERMCAP */
441 termcapobj = tparam.o
442 #endif /* ! defined (TERMINFO) */
443
444
445 #ifndef SYSTEM_MALLOC
446
447 #ifndef DOUG_LEA_MALLOC
448 gmallocobj = gmalloc.o
449 #endif
450
451 #ifdef REL_ALLOC
452 rallocobj = ralloc.o
453 #endif
454
455 mallocobj = $(gmallocobj) $(rallocobj) vm-limit.o
456
457 #endif /* SYSTEM_MALLOC */
458
459
460 /* define otherobj as list of object files that make-docfile
461 should not be told about. */
462 #ifdef CYGWIN
463 /* Cygwin differs because of its unexec(). */
464 otherobj= $(termcapobj) $(gmallocobj) $(rallocobj) lastfile.o vm-limit.o $(WIDGET_OBJ) $(LIBOBJS)
465 #else
466 otherobj= $(termcapobj) lastfile.o $(mallocobj) $(WIDGET_OBJ) $(LIBOBJS)
467 #endif
468
469 #ifdef HAVE_MOUSE
470 #define MOUSE_SUPPORT ${lispsource}mouse.elc \
471 ${lispsource}select.elc ${lispsource}scroll-bar.elc
472 #else
473 #ifdef HAVE_GPM
474 #define MOUSE_SUPPORT ${lispsource}mouse.elc
475 #else
476 #define MOUSE_SUPPORT
477 #endif
478 #endif
479
480 #ifdef MSDOS
481 #define MSDOS_SUPPORT ${lispsource}ls-lisp.elc ${lispsource}disp-table.elc \
482 ${lispsource}dos-fns.elc ${lispsource}dos-w32.elc ${lispsource}dos-vars.elc \
483 ${lispsource}term/internal.elc ${lispsource}term/pc-win.elc
484
485 #else
486 #define MSDOS_SUPPORT
487 #endif
488
489 #ifdef HAVE_WINDOW_SYSTEM
490 #ifdef HAVE_X_WINDOWS
491 #define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \
492 ${lispsource}international/fontset.elc ${lispsource}dnd.elc \
493 ${lispsource}tool-bar.elc ${lispsource}mwheel.elc ${lispsource}x-dnd.elc \
494 ${lispsource}term/common-win.elc ${lispsource}term/x-win.elc \
495 ${lispsource}dynamic-setting.elc
496 #else
497 #define WINDOW_SUPPORT ${lispsource}fringe.elc ${lispsource}image.elc \
498 ${lispsource}international/fontset.elc ${lispsource}dnd.elc \
499 ${lispsource}tool-bar.elc ${lispsource}mwheel.elc
500 #endif
501 #else
502 #define WINDOW_SUPPORT
503 #endif
504
505 #ifdef WINDOWSNT
506 #define WINNT_SUPPORT ${lispsource}ls-lisp.elc ${lispsource}disp-table.elc \
507 ${lispsource}dos-w32.elc ${lispsource}w32-vars.elc \
508 ${lispsource}w32-fns.elc ${lispsource}term/common-win.elc \
509 ${lispsource}term/w32-win.elc
510 #else
511 #define WINNT_SUPPORT
512 #endif
513
514 #ifdef HAVE_WINDOW_SYSTEM
515 #define TOOLTIP_SUPPORT ${lispsource}tooltip.elc
516 #else
517 #define TOOLTIP_SUPPORT
518 #endif
519
520 #ifdef HAVE_NS
521 #define NS_SUPPORT ${lispsource}emacs-lisp/easymenu.elc \
522 ${lispsource}term/ns-win.elc
523 #else
524 #define NS_SUPPORT
525 #endif
526
527 /* This is the platform-specific list of Lisp files loaded into the
528 dumped Emacs. It is arranged like this because it is easier to generate
529 it semi-mechanically from loadup.el this way.
530
531 Note that this list should not include lisp files which might not
532 be present, like site-load.el and site-init.el; this makefile
533 expects them all to be either present or buildable.
534
535 Files which are loaded unconditionally (i.e., on all platforms) should
536 also be in shortlisp. Files which are loaded conditionally (i.e., only
537 on some platforms) should instead be in SOME_MACHINE_LISP. */
538
539 /* Place loaddefs.el first, so it gets generated first, since it is on
540 the critical path (relevant in parallel compilations). */
541
542 lisp= \
543 ${lispsource}loaddefs.el \
544 ${lispsource}abbrev.elc \
545 ${lispsource}buff-menu.elc \
546 ${lispsource}button.elc \
547 ${lispsource}emacs-lisp/byte-run.elc \
548 ${lispsource}composite.elc \
549 ${lispsource}cus-face.elc \
550 ${lispsource}cus-start.elc \
551 ${lispsource}custom.elc \
552 ${lispsource}emacs-lisp/backquote.elc \
553 ${lispsource}emacs-lisp/lisp-mode.elc \
554 ${lispsource}emacs-lisp/lisp.elc \
555 ${lispsource}env.elc \
556 ${lispsource}faces.elc \
557 ${lispsource}files.elc \
558 ${lispsource}format.elc \
559 ${lispsource}facemenu.elc \
560 MOUSE_SUPPORT \
561 ${lispsource}emacs-lisp/float-sup.elc \
562 ${lispsource}frame.elc \
563 ${lispsource}help.elc \
564 ${lispsource}indent.elc \
565 ${lispsource}isearch.elc \
566 ${lispsource}rfn-eshadow.elc \
567 ${lispsource}loadup.el \
568 ${lispsource}bindings.elc \
569 ${lispsource}emacs-lisp/map-ynp.elc \
570 ${lispsource}menu-bar.elc \
571 ${lispsource}international/mule.elc \
572 ${lispsource}international/mule-conf.elc \
573 ${lispsource}international/mule-cmds.elc \
574 ${lispsource}international/characters.elc \
575 ${lispsource}international/charprop.el \
576 ${lispsource}case-table.elc \
577 ${lispsource}language/chinese.elc \
578 ${lispsource}language/cyrillic.elc \
579 ${lispsource}language/indian.elc \
580 ${lispsource}language/sinhala.el \
581 ${lispsource}language/english.el \
582 ${lispsource}language/ethiopic.elc \
583 ${lispsource}language/european.elc \
584 ${lispsource}language/czech.el \
585 ${lispsource}language/slovak.el \
586 ${lispsource}language/romanian.el \
587 ${lispsource}language/greek.el \
588 ${lispsource}language/hebrew.el \
589 ${lispsource}language/japanese.el \
590 ${lispsource}language/korean.el \
591 ${lispsource}language/lao.el \
592 ${lispsource}language/cham.el \
593 ${lispsource}language/tai-viet.el \
594 ${lispsource}language/thai.el \
595 ${lispsource}language/tibetan.elc \
596 ${lispsource}language/vietnamese.elc \
597 ${lispsource}language/misc-lang.el \
598 ${lispsource}language/utf-8-lang.el \
599 ${lispsource}language/georgian.el \
600 ${lispsource}language/khmer.el \
601 ${lispsource}language/burmese.el \
602 ${lispsource}paths.el \
603 ${lispsource}register.elc \
604 ${lispsource}replace.elc \
605 ${lispsource}simple.elc \
606 ${lispsource}minibuffer.elc \
607 ${lispsource}startup.elc \
608 ${lispsource}subr.elc \
609 ${lispsource}term/tty-colors.elc \
610 ${lispsource}font-core.elc \
611 ${lispsource}emacs-lisp/syntax.elc \
612 ${lispsource}font-lock.elc \
613 ${lispsource}jit-lock.elc \
614 ${lispsource}textmodes/fill.elc \
615 ${lispsource}textmodes/page.elc \
616 ${lispsource}textmodes/paragraphs.elc \
617 ${lispsource}textmodes/text-mode.elc \
618 ${lispsource}emacs-lisp/timer.elc \
619 ${lispsource}jka-cmpr-hook.elc \
620 ${lispsource}vc-hooks.elc \
621 ${lispsource}ediff-hook.elc \
622 ${lispsource}epa-hook.elc \
623 TOOLTIP_SUPPORT \
624 MSDOS_SUPPORT \
625 WINNT_SUPPORT \
626 WINDOW_SUPPORT \
627 NS_SUPPORT \
628 ${lispsource}widget.elc \
629 ${lispsource}window.elc \
630 ${lispsource}version.el
631
632 /* List of relative names for those files from $lisp that are loaded
633 unconditionally (i.e. on all platforms). Files from $lisp that
634 are only loaded on some platforms should instead be placed in
635 SOME_MACHINE_LISP. The only reason this variable exists is to prevent
636 the make-docfile command-line getting too long for some systems. */
637 shortlisp= \
638 ../lisp/loaddefs.el \
639 ../lisp/abbrev.elc \
640 ../lisp/buff-menu.elc \
641 ../lisp/button.elc \
642 ../lisp/emacs-lisp/byte-run.elc \
643 ../lisp/composite.elc \
644 ../lisp/cus-face.elc \
645 ../lisp/cus-start.elc \
646 ../lisp/custom.elc \
647 ../lisp/emacs-lisp/backquote.elc \
648 ../lisp/emacs-lisp/lisp-mode.elc \
649 ../lisp/emacs-lisp/lisp.elc \
650 ../lisp/facemenu.elc \
651 ../lisp/faces.elc \
652 ../lisp/files.elc \
653 ../lisp/emacs-lisp/float-sup.elc \
654 ../lisp/format.elc \
655 ../lisp/frame.elc \
656 ../lisp/help.elc \
657 ../lisp/indent.elc \
658 ../lisp/isearch.elc \
659 ../lisp/rfn-eshadow.elc \
660 ../lisp/loadup.el \
661 ../lisp/bindings.elc \
662 ../lisp/emacs-lisp/map-ynp.elc \
663 ../lisp/env.elc \
664 ../lisp/international/mule.elc \
665 ../lisp/international/mule-conf.elc \
666 ../lisp/international/mule-cmds.elc \
667 ../lisp/international/characters.elc \
668 ../lisp/case-table.elc \
669 ../lisp/language/chinese.elc \
670 ../lisp/language/cyrillic.elc \
671 ../lisp/language/indian.elc \
672 ../lisp/language/sinhala.el \
673 ../lisp/language/english.el \
674 ../lisp/language/ethiopic.elc \
675 ../lisp/language/european.elc \
676 ../lisp/language/czech.el \
677 ../lisp/language/slovak.el \
678 ../lisp/language/romanian.el \
679 ../lisp/language/greek.el \
680 ../lisp/language/hebrew.el \
681 ../lisp/language/japanese.el \
682 ../lisp/language/korean.el \
683 ../lisp/language/lao.el \
684 ../lisp/language/cham.el \
685 ../lisp/language/tai-viet.el \
686 ../lisp/language/thai.el \
687 ../lisp/language/tibetan.elc \
688 ../lisp/language/vietnamese.elc \
689 ../lisp/language/misc-lang.el \
690 ../lisp/language/utf-8-lang.el \
691 ../lisp/language/georgian.el \
692 ../lisp/language/khmer.el \
693 ../lisp/language/burmese.el \
694 ../lisp/menu-bar.elc \
695 ../lisp/paths.el \
696 ../lisp/register.elc \
697 ../lisp/replace.elc \
698 ../lisp/simple.elc \
699 ../lisp/minibuffer.elc \
700 ../lisp/startup.elc \
701 ../lisp/subr.elc \
702 ../lisp/term/tty-colors.elc \
703 ../lisp/font-core.elc \
704 ../lisp/emacs-lisp/syntax.elc \
705 ../lisp/font-lock.elc \
706 ../lisp/jit-lock.elc \
707 ../lisp/textmodes/fill.elc \
708 ../lisp/textmodes/page.elc \
709 ../lisp/textmodes/paragraphs.elc \
710 ../lisp/textmodes/text-mode.elc \
711 ../lisp/emacs-lisp/timer.elc \
712 ../lisp/vc-hooks.elc \
713 ../lisp/jka-cmpr-hook.elc \
714 ../lisp/ediff-hook.elc \
715 ../lisp/epa-hook.elc \
716 ../lisp/widget.elc \
717 ../lisp/window.elc \
718 ../lisp/version.el
719
720 /* Like $shortlisp, but includes only those files from $lisp that are loaded
721 conditionally (i.e., only on some platforms). */
722 SOME_MACHINE_LISP = ../lisp/mouse.elc \
723 ../lisp/select.elc ../lisp/scroll-bar.elc \
724 ../lisp/ls-lisp.elc ../lisp/dos-fns.elc \
725 ../lisp/w32-fns.elc ../lisp/dos-w32.elc \
726 ../lisp/disp-table.elc ../lisp/dos-vars.elc \
727 ../lisp/tooltip.elc ../lisp/image.elc \
728 ../lisp/fringe.elc ../lisp/dnd.elc \
729 ../lisp/mwheel.elc ../lisp/tool-bar.elc \
730 ../lisp/x-dnd.elc ../lisp/dynamic-setting.elc \
731 ../lisp/international/ccl.elc \
732 ../lisp/international/fontset.elc \
733 ../lisp/mouse.elc \
734 ../lisp/term/common-win.elc \
735 ../lisp/term/x-win.elc \
736 ../lisp/term/pc-win.elc ../lisp/term/internal.elc \
737 ../lisp/term/ns-win.elc ../lisp/term/w32-win.elc \
738 ../lisp/emacs-lisp/easymenu.elc
739
740 /* Construct full set of libraries to be linked.
741 Note that SunOS needs -lm to come before -lc; otherwise, you get
742 duplicated symbols. If the standard libraries were compiled
743 with GCC, we might need gnulib again after them. */
744
745 LIBES = $(LOADLIBES) $(LIBS) $(LIBX) $(LIBSOUND) $(RSVG_LIBS) $(DBUS_LIBS) \
746 @LIBGPM@ @LIBRESOLV@ LIBS_SYSTEM LIBS_TERMCAP \
747 $(GETLOADAVG_LIBS) ${GCONF_LIBS} ${LIBSELINUX_LIBS} \
748 @FREETYPE_LIBS@ @FONTCONFIG_LIBS@ @LIBOTF_LIBS@ @M17N_FLT_LIBS@ \
749 $(GNULIB_VAR) @LIB_MATH@ LIB_STANDARD $(GNULIB_VAR)
750
751 all: emacs${EXEEXT} $(OTHER_FILES)
752
753 emacs${EXEEXT}: temacs${EXEEXT} ${etc}DOC ${lisp}
754 #ifdef CANNOT_DUMP
755 rm -f emacs${EXEEXT}
756 ln temacs${EXEEXT} emacs${EXEEXT}
757 -EMACSLOADPATH=${lispsource} ./emacs -q -batch -f list-load-path-shadows
758 #else
759 LC_ALL=C $(RUN_TEMACS) -batch -l loadup dump
760 @: This new Emacs is as functional and more efficient then
761 @: bootstrap-emacs, so let us replace it.
762 -ln -f emacs${EXEEXT} bootstrap-emacs${EXEEXT}
763 -./emacs -q -batch -f list-load-path-shadows
764 #endif /* ! defined (CANNOT_DUMP) */
765
766 /* We run make-docfile twice because the command line may get too long
767 on some systems. */
768 /* ${SOME_MACHINE_OBJECTS} comes before ${obj} because some files may
769 or may not be included in ${obj}, but they are always included in
770 ${SOME_MACHINE_OBJECTS}. Since a file is processed when it is mentioned
771 for the first time, this prevents any variation between configurations
772 in the contents of the DOC file.
773 Likewise for ${SOME_MACHINE_LISP}. */
774 /* Most of this Makefile refers to Lisp files via ${lispsource}, so
775 we also use ${lisp} rather than ${shortlisp} for the dependency since
776 the Makefile uses string equality to decide when we talk about identical
777 files. Apparently we pass ${shortlisp} rather than ${lisp} to make-docfile
778 only in order to reduce the command line length. --Stef */
779 ${etc}DOC: ${libsrc}make-docfile${EXEEXT} ${obj} ${lisp} ${SOME_MACHINE_LISP}
780 -rm -f ${etc}DOC
781 ${libsrc}make-docfile -d ${srcdir} ${SOME_MACHINE_OBJECTS} ${obj} > ${etc}DOC
782 ${libsrc}make-docfile -a ${etc}DOC -d ${srcdir} ${SOME_MACHINE_LISP} ${shortlisp}
783
784 ${libsrc}make-docfile${EXEEXT}:
785 cd ${libsrc}; ${MAKE} ${MFLAGS} make-docfile${EXEEXT}
786
787 buildobj.h: Makefile
788 echo "#define BUILDOBJ \"${obj} ${otherobj} " "\"" > buildobj.h
789
790 temacs${EXEEXT}: $(LOCALCPP) $(STARTFILES) stamp-oldxmenu ${obj} ${otherobj} prefix-args${EXEEXT}
791 #ifdef NS_IMPL_GNUSTEP
792 $(CC) -rdynamic YMF_PASS_LDFLAGS ( ${TEMACS_LDFLAGS} \
793 -L@GNUSTEP_SYSTEM_LIBRARIES@ -lgnustep-gui -lgnustep-base \
794 -lobjc $(CONFIG_SYSTEM_LIBS) -lpthread ) -o temacs \
795 ${obj} ${otherobj} ${LIBES}
796 #else
797 $(LD) YMF_PASS_LDFLAGS (${STARTFLAGS} ${TEMACS_LDFLAGS}) $(LDFLAGS) \
798 -o temacs ${STARTFILES} ${obj} ${otherobj} \
799 ${LIBES}
800 #endif
801
802 /* We do not use ALL_LDFLAGS because LD_SWITCH_SYSTEM and LD_SWITCH_MACHINE
803 often contain options that have to do with using Emacs''s crt0,
804 which are only good with temacs. */
805 prefix-args${EXEEXT}: prefix-args.o $(config_h)
806 $(CC) $(LDFLAGS) prefix-args.o -o prefix-args
807
808 #if defined (HAVE_X_WINDOWS) && defined (HAVE_X11) && defined (HAVE_MENUS) && ! defined (USE_GTK)
809
810 /* We use stamp-xmenu with these two deps
811 to both ensure that lwlib gets remade based on its dependencies
812 in its own makefile,
813 and remake temacs if lwlib gets changed by this. */
814 stamp-oldxmenu: ${OLDXMENU} ../src/$(OLDXMENU)
815 touch stamp-oldxmenu
816 /* Supply an ordering for parallel make. */
817 ../src/$(OLDXMENU): ${OLDXMENU}
818
819 #ifdef USE_X_TOOLKIT
820 $(OLDXMENU): really-lwlib
821
822 really-lwlib:
823 cd ${lwlibdir}; ${MAKE} ${MFLAGS} \
824 CC='${CC}' CFLAGS='${CFLAGS}' MAKE='${MAKE}'
825 @true /* make -t should not create really-lwlib. */
826 .PHONY: really-lwlib
827 #else /* not USE_X_TOOLKIT */
828 $(OLDXMENU): really-oldXMenu
829
830 really-oldXMenu:
831 cd ${oldXMenudir}; ${MAKE} ${MFLAGS} \
832 CC='${CC}' CFLAGS='${CFLAGS}' MAKE='${MAKE}'
833 @true /* make -t should not create really-oldXMenu. */
834 .PHONY: really-oldXMenu
835 #endif /* not USE_X_TOOLKIT */
836 #else /* not (HAVE_X_WINDOWS && HAVE_X11 && HAVE_MENUS && ! USE_GTK) */
837
838 /* We don''t really need this, but satisfy the dependency. */
839 stamp-oldxmenu:
840 touch stamp-oldxmenu
841 #endif /* not (HAVE_X_WINDOWS && HAVE_X11 && HAVE_MENUS && ! USE_GTK) */
842
843 ../config.status:: epaths.in
844 @echo "The file epaths.h needs to be set up from epaths.in."
845 @echo "Please run the `configure' script again."
846 exit 1
847
848 ../config.status:: config.in
849 @echo "The file config.h needs to be set up from config.in."
850 @echo "Please run the `configure' script again."
851 exit 1
852
853 ecrt0.o: ecrt0.c $(config_h)
854 #ifdef AUTO_DEPEND
855 @-test -d deps || mkdir deps
856 #endif
857 $(CC) -c $(ALL_CFLAGS) ${srcdir}/ecrt0.c
858 doc.o: buildobj.h
859
860 #ifndef AUTO_DEPEND
861
862 atimer.o: atimer.c atimer.h syssignal.h systime.h lisp.h blockinput.h \
863 $(config_h)
864 bidi.o: bidi.c buffer.h character.h dispextern.h lisp.h $(config_h)
865 buffer.o: buffer.c buffer.h region-cache.h commands.h window.h \
866 $(INTERVALS_H) blockinput.h atimer.h systime.h character.h \
867 indent.h keyboard.h coding.h keymap.h frame.h lisp.h $(config_h)
868 callint.o: callint.c window.h commands.h buffer.h keymap.h \
869 keyboard.h dispextern.h systime.h coding.h composite.h lisp.h $(config_h)
870 callproc.o: callproc.c epaths.h buffer.h commands.h lisp.h $(config_h) \
871 process.h systty.h syssignal.h character.h coding.h ccl.h msdos.h \
872 composite.h w32.h blockinput.h atimer.h systime.h frame.h termhooks.h \
873 buffer.h
874 casefiddle.o: casefiddle.c syntax.h commands.h buffer.h character.h \
875 composite.h keymap.h lisp.h $(config_h)
876 casetab.o: casetab.c buffer.h character.h lisp.h $(config_h)
877 category.o: category.c category.h buffer.h charset.h keymap.h \
878 character.h lisp.h $(config_h)
879 ccl.o: ccl.c ccl.h charset.h character.h coding.h composite.h lisp.h $(config_h)
880 character.o: character.c character.h buffer.h charset.h composite.h disptab.h \
881 lisp.h $(config_h)
882 charset.o: charset.c charset.h character.h buffer.h coding.h composite.h \
883 disptab.h lisp.h $(config_h)
884 chartab.o: charset.h character.h ccl.h lisp.h $(config_h)
885 coding.o: coding.c coding.h ccl.h buffer.h character.h charset.h composite.h \
886 window.h dispextern.h frame.h termhooks.h lisp.h $(config_h)
887 cm.o: cm.c frame.h cm.h termhooks.h termchar.h dispextern.h lisp.h $(config_h)
888 cmds.o: cmds.c syntax.h buffer.h character.h commands.h window.h lisp.h $(config_h) \
889 msdos.h dispextern.h keyboard.h keymap.h systime.h coding.h frame.h \
890 composite.h
891 pre-crt0.o: pre-crt0.c
892 dbusbind.o: dbusbind.c termhooks.h frame.h keyboard.h lisp.h $(config_h)
893 dired.o: dired.c commands.h buffer.h lisp.h $(config_h) character.h charset.h \
894 coding.h regex.h systime.h blockinput.h atimer.h composite.h
895 dispnew.o: dispnew.c systime.h commands.h process.h frame.h coding.h \
896 window.h buffer.h termchar.h termopts.h termhooks.h cm.h \
897 disptab.h indent.h $(INTERVALS_H) \
898 xterm.h blockinput.h atimer.h character.h msdos.h keyboard.h \
899 syssignal.h lisp.h $(config_h)
900 doc.o: doc.c lisp.h $(config_h) epaths.h buffer.h keyboard.h keymap.h \
901 character.h systime.h coding.h composite.h
902 doprnt.o: doprnt.c character.h lisp.h $(config_h)
903 dosfns.o: buffer.h termchar.h termhooks.h frame.h blockinput.h window.h \
904 msdos.h dosfns.h dispextern.h charset.h coding.h atimer.h systime.h \
905 lisp.h $(config_h)
906 editfns.o: editfns.c window.h buffer.h systime.h $(INTERVALS_H) character.h \
907 coding.h frame.h blockinput.h atimer.h lisp.h $(config_h)
908 emacs.o: emacs.c commands.h systty.h syssignal.h blockinput.h process.h \
909 termhooks.h buffer.h atimer.h systime.h $(INTERVALS_H) lisp.h $(config_h) \
910 window.h dispextern.h keyboard.h keymap.h frame.h coding.h
911 fileio.o: fileio.c window.h buffer.h systime.h $(INTERVALS_H) character.h \
912 coding.h msdos.h blockinput.h atimer.h lisp.h $(config_h) frame.h commands.h
913 filelock.o: filelock.c buffer.h character.h coding.h systime.h composite.h \
914 lisp.h $(config_h)
915 filemode.o: filemode.c $(config_h)
916 frame.o: frame.c xterm.h window.h frame.h termhooks.h commands.h keyboard.h \
917 blockinput.h atimer.h systime.h buffer.h character.h fontset.h font.h \
918 msdos.h dosfns.h dispextern.h w32term.h termchar.h coding.h composite.h \
919 lisp.h $(config_h) termhooks.h ccl.h
920 fringe.o: fringe.c dispextern.h frame.h window.h buffer.h termhooks.h \
921 blockinput.h atimer.h systime.h lisp.h $(config_h)
922 font.o: font.c dispextern.h frame.h window.h ccl.h character.h charset.h \
923 font.h lisp.h $(config_h) buffer.h composite.h fontset.h xterm.h
924 ftfont.o: dispextern.h frame.h character.h charset.h composite.h font.h \
925 lisp.h $(config_h) blockinput.h atimer.h systime.h coding.h fontset.h \
926 ccl.h ftfont.h
927 fontset.o: fontset.c fontset.h ccl.h buffer.h character.h \
928 charset.h frame.h keyboard.h termhooks.h font.h lisp.h $(config_h) \
929 blockinput.h atimer.h systime.h coding.h $(INTERVALS_H) window.h xterm.h
930 getloadavg.o: getloadavg.c $(config_h)
931 gtkutil.o: gtkutil.c gtkutil.h xterm.h lisp.h frame.h lisp.h $(config_h) \
932 blockinput.h window.h atimer.h systime.h termhooks.h keyboard.h \
933 charset.h coding.h syssignal.h dispextern.h composite.h
934 image.o: image.c frame.h window.h dispextern.h blockinput.h atimer.h \
935 systime.h xterm.h w32term.h w32gui.h font.h epaths.h character.h coding.h \
936 nsterm.h nsgui.h lisp.h $(config_h) composite.h termhooks.h ccl.h
937 indent.o: indent.c frame.h window.h indent.h buffer.h lisp.h $(config_h) termchar.h \
938 termopts.h disptab.h region-cache.h character.h category.h \
939 keyboard.h systime.h coding.h $(INTERVALS_H)
940 insdel.o: insdel.c window.h buffer.h $(INTERVALS_H) blockinput.h character.h \
941 dispextern.h atimer.h systime.h region-cache.h lisp.h $(config_h)
942 keyboard.o: keyboard.c termchar.h termhooks.h termopts.h buffer.h character.h \
943 commands.h frame.h window.h macros.h disptab.h keyboard.h syssignal.h \
944 systime.h syntax.h $(INTERVALS_H) blockinput.h atimer.h composite.h \
945 xterm.h puresize.h msdos.h keymap.h w32term.h nsterm.h coding.h \
946 lisp.h $(config_h)
947 keymap.o: keymap.c buffer.h commands.h keyboard.h termhooks.h blockinput.h \
948 atimer.h systime.h puresize.h character.h charset.h $(INTERVALS_H) keymap.h window.h \
949 coding.h frame.h lisp.h $(config_h)
950 lastfile.o: lastfile.c $(config_h)
951 macros.o: macros.c window.h buffer.h commands.h macros.h keyboard.h \
952 dispextern.h lisp.h $(config_h) systime.h coding.h composite.h
953 gmalloc.o: gmalloc.c $(config_h)
954 ralloc.o: ralloc.c lisp.h $(config_h)
955 vm-limit.o: vm-limit.c mem-limits.h lisp.h $(config_h)
956 marker.o: marker.c buffer.h character.h lisp.h $(config_h)
957 md5.o: md5.c md5.h $(config_h)
958 minibuf.o: minibuf.c syntax.h frame.h window.h keyboard.h systime.h \
959 buffer.h commands.h character.h msdos.h $(INTERVALS_H) keymap.h \
960 termhooks.h lisp.h $(config_h) coding.h
961 mktime.o: mktime.c $(config_h)
962 msdos.o: msdos.c msdos.h dosfns.h systime.h termhooks.h dispextern.h frame.h \
963 termopts.h termchar.h character.h coding.h ccl.h disptab.h window.h \
964 keyboard.h $(INTERVALS_H) buffer.h commands.h blockinput.h atimer.h lisp.h $(config_h)
965 nsfns.o: nsfns.m charset.h nsterm.h nsgui.h frame.h window.h buffer.h \
966 dispextern.h nsgui.h fontset.h $(INTERVALS_H) keyboard.h blockinput.h \
967 atimer.h systime.h epaths.h termhooks.h coding.h systime.h lisp.h $(config_h)
968 nsfont.o: nsterm.h dispextern.h frame.h lisp.h lisp.h $(config_h)
969 nsimage.o: nsimage.m nsterm.h lisp.h $(config_h)
970 nsmenu.o: nsmenu.m termhooks.h frame.h window.h dispextern.h \
971 nsgui.h keyboard.h blockinput.h atimer.h systime.h buffer.h \
972 nsterm.h lisp.h $(config_h)
973 nsterm.o: nsterm.m blockinput.h atimer.h systime.h syssignal.h nsterm.h \
974 nsgui.h frame.h charset.h ccl.h dispextern.h fontset.h termhooks.h \
975 termopts.h termchar.h disptab.h buffer.h window.h keyboard.h \
976 $(INTERVALS_H) process.h coding.h lisp.h $(config_h)
977 nsselect.o: nsselect.m blockinput.h nsterm.h nsgui.h frame.h lisp.h $(config_h)
978 process.o: process.c process.h buffer.h window.h termhooks.h termopts.h \
979 commands.h syssignal.h systime.h systty.h syswait.h frame.h dispextern.h \
980 blockinput.h atimer.h charset.h coding.h ccl.h msdos.h composite.h \
981 keyboard.h lisp.h $(config_h) character.h xgselect.h sysselect.h
982 regex.o: regex.c syntax.h buffer.h lisp.h $(config_h) regex.h category.h character.h
983 region-cache.o: region-cache.c buffer.h region-cache.h lisp.h $(config_h)
984 scroll.o: scroll.c termchar.h dispextern.h frame.h msdos.h keyboard.h \
985 termhooks.h lisp.h $(config_h) systime.h coding.h composite.h window.h
986 search.o: search.c regex.h commands.h buffer.h region-cache.h syntax.h \
987 blockinput.h atimer.h systime.h category.h character.h charset.h \
988 $(INTERVALS_H) \
989 lisp.h $(config_h)
990 sound.o: sound.c dispextern.h syssignal.h lisp.h $(config_h) atimer.h systime.h
991 strftime.o: strftime.c $(config_h)
992 syntax.o: syntax.c syntax.h buffer.h commands.h category.h character.h \
993 keymap.h regex.h $(INTERVALS_H) lisp.h $(config_h)
994 sysdep.o: sysdep.c syssignal.h systty.h systime.h syswait.h blockinput.h \
995 process.h dispextern.h termhooks.h termchar.h termopts.h coding.h \
996 frame.h atimer.h window.h msdos.h dosfns.h keyboard.h cm.h lisp.h $(config_h) \
997 composite.h
998 term.o: term.c termchar.h termhooks.h termopts.h lisp.h $(config_h) cm.h frame.h \
999 disptab.h keyboard.h character.h charset.h coding.h ccl.h xterm.h \
1000 msdos.h window.h keymap.h blockinput.h atimer.h systime.h systty.h \
1001 syssignal.h $(INTERVALS_H) buffer.h
1002 termcap.o: termcap.c lisp.h $(config_h)
1003 terminal.o: terminal.c frame.h termchar.h termhooks.h charset.h coding.h \
1004 keyboard.h lisp.h $(config_h) dispextern.h composite.h systime.h
1005 terminfo.o: terminfo.c lisp.h $(config_h)
1006 tparam.o: tparam.c lisp.h $(config_h)
1007 undo.o: undo.c buffer.h commands.h window.h dispextern.h lisp.h $(config_h)
1008 unexaix.o: unexaix.c lisp.h $(config_h)
1009 unexalpha.o: unexalpha.c $(config_h)
1010 unexcw.o: unexcw.c lisp.h $(config_h)
1011 unexec.o: unexec.c lisp.h $(config_h)
1012 unexelf.o: unexelf.c $(config_h)
1013 unexhp9k800.o: unexhp9k800.c $(config_h)
1014 unexmacosx.o: unexmacosx.c $(config_h)
1015 unexsol.o: unexsol.c lisp.h $(config_h)
1016 unexw32.o: unexw32.c $(config_h)
1017 w16select.o: w16select.c dispextern.h frame.h blockinput.h atimer.h systime.h \
1018 msdos.h buffer.h charset.h coding.h composite.h lisp.h $(config_h)
1019 widget.o: widget.c xterm.h frame.h dispextern.h widgetprv.h \
1020 $(srcdir)/../lwlib/lwlib.h lisp.h $(config_h)
1021 window.o: window.c indent.h commands.h frame.h window.h buffer.h termchar.h \
1022 disptab.h keyboard.h msdos.h coding.h termhooks.h \
1023 keymap.h blockinput.h atimer.h systime.h $(INTERVALS_H) \
1024 xterm.h w32term.h nsterm.h lisp.h $(config_h)
1025 xdisp.o: xdisp.c macros.h commands.h process.h indent.h buffer.h dispextern.h \
1026 coding.h termchar.h frame.h window.h disptab.h termhooks.h character.h \
1027 charset.h lisp.h $(config_h) keyboard.h $(INTERVALS_H) region-cache.h xterm.h \
1028 w32term.h nsterm.h msdos.h composite.h fontset.h ccl.h \
1029 blockinput.h atimer.h systime.h keymap.h font.h
1030 xfaces.o: xfaces.c dispextern.h frame.h xterm.h buffer.h blockinput.h \
1031 window.h character.h charset.h msdos.h dosfns.h composite.h atimer.h \
1032 systime.h keyboard.h fontset.h w32term.h nsterm.h coding.h ccl.h \
1033 $(INTERVALS_H) termchar.h termhooks.h font.h lisp.h $(config_h)
1034 xfns.o: xfns.c buffer.h frame.h window.h keyboard.h xterm.h dispextern.h \
1035 $(srcdir)/../lwlib/lwlib.h blockinput.h atimer.h systime.h epaths.h \
1036 character.h charset.h coding.h gtkutil.h lisp.h $(config_h) termhooks.h \
1037 fontset.h termchar.h font.h xsettings.h $(INTERVALS_H) ccl.h
1038 xfont.o: dispextern.h xterm.h frame.h blockinput.h character.h charset.h \
1039 font.h lisp.h $(config_h) atimer.h systime.h fontset.h ccl.h
1040 xftfont.o: dispextern.h xterm.h frame.h blockinput.h character.h charset.h \
1041 font.h lisp.h $(config_h) atimer.h systime.h fontset.h ccl.h ftfont.h
1042 ftxfont.o: dispextern.h xterm.h frame.h blockinput.h character.h charset.h \
1043 font.h lisp.h $(config_h) atimer.h systime.h fontset.h ccl.h
1044 menu.o: menu.c lisp.h keyboard.h keymap.h frame.h termhooks.h blockinput.h \
1045 dispextern.h $(srcdir)/../lwlib/lwlib.h xterm.h gtkutil.h menu.h \
1046 lisp.h $(config_h) systime.h coding.h composite.h window.h atimer.h
1047 xmenu.o: xmenu.c xterm.h termhooks.h window.h dispextern.h frame.h buffer.h \
1048 charset.h keyboard.h $(srcdir)/../lwlib/lwlib.h blockinput.h atimer.h \
1049 systime.h gtkutil.h msdos.h coding.h menu.h lisp.h $(config_h) composite.h \
1050 keymap.h sysselect.h
1051 xterm.o: xterm.c xterm.h termhooks.h termopts.h termchar.h window.h buffer.h \
1052 dispextern.h frame.h disptab.h blockinput.h atimer.h systime.h syssignal.h \
1053 keyboard.h emacs-icon.h character.h charset.h ccl.h fontset.h composite.h \
1054 coding.h process.h gtkutil.h font.h fontset.h lisp.h $(config_h) \
1055 xsettings.h intervals.h keymap.h xgselect.h sysselect.h
1056 xselect.o: xselect.c process.h dispextern.h frame.h xterm.h blockinput.h \
1057 buffer.h atimer.h systime.h termhooks.h lisp.h $(config_h) keyboard.h \
1058 coding.h composite.h
1059 xgselect.o: xgselect.h systime.h sysselect.h lisp.h $(config_h)
1060 xrdb.o: xrdb.c lisp.h $(config_h) epaths.h
1061 xsmfns.o: xsmfns.c lisp.h $(config_h) systime.h sysselect.h termhooks.h xterm.h \
1062 lisp.h termopts.h frame.h dispextern.h
1063 xsettings.o: xterm.h xsettings.h lisp.h frame.h termhooks.h $(config_h) \
1064 dispextern.h keyboard.h systime.h coding.h composite.h blockinput.h atimer.h \
1065 termopts.h
1066 /* The files of Lisp proper */
1067
1068 alloc.o: alloc.c process.h frame.h window.h buffer.h puresize.h syssignal.h \
1069 keyboard.h blockinput.h atimer.h systime.h character.h lisp.h $(config_h) \
1070 $(INTERVALS_H) termhooks.h
1071 bytecode.o: bytecode.c buffer.h syntax.h character.h window.h dispextern.h \
1072 frame.h xterm.h lisp.h $(config_h)
1073 data.o: data.c buffer.h puresize.h character.h syssignal.h keyboard.h frame.h \
1074 termhooks.h systime.h coding.h composite.h dispextern.h font.h ccl.h \
1075 lisp.h $(config_h)
1076 eval.o: eval.c commands.h keyboard.h blockinput.h atimer.h systime.h \
1077 dispextern.h lisp.h $(config_h) coding.h composite.h xterm.h
1078 floatfns.o: floatfns.c syssignal.h lisp.h $(config_h)
1079 fns.o: fns.c commands.h lisp.h $(config_h) frame.h buffer.h character.h keyboard.h \
1080 keymap.h window.h dispextern.h $(INTERVALS_H) coding.h md5.h \
1081 blockinput.h atimer.h systime.h xterm.h
1082 print.o: print.c process.h frame.h window.h buffer.h keyboard.h character.h \
1083 lisp.h $(config_h) termchar.h $(INTERVALS_H) msdos.h termhooks.h \
1084 blockinput.h atimer.h systime.h font.h charset.h coding.h ccl.h
1085 lread.o: lread.c commands.h keyboard.h buffer.h epaths.h character.h \
1086 charset.h lisp.h $(config_h) $(INTERVALS_H) termhooks.h coding.h msdos.h \
1087 systime.h frame.h blockinput.h atimer.h
1088
1089 /* Text properties support */
1090 composite.o: composite.c buffer.h character.h coding.h font.h ccl.h \
1091 frame.h termhooks.h $(INTERVALS_H) window.h lisp.h $(config_h)
1092 intervals.o: intervals.c buffer.h $(INTERVALS_H) keyboard.h puresize.h \
1093 keymap.h lisp.h $(config_h) systime.h coding.h
1094 textprop.o: textprop.c buffer.h window.h $(INTERVALS_H) \
1095 lisp.h $(config_h)
1096
1097 #endif /* ! AUTO_DEPEND */
1098
1099 /* System-specific programs to be made.
1100 OTHER_FILES
1101 select which of these should be compiled. */
1102
1103 #ifdef HAVE_NS
1104 /* In fact, every .o file depends directly or indirectly on dispextern.h
1105 and hence nsgui.h under NS. But the ones that actually use stuff there
1106 are more limited. */
1107 dispnew.o font.o fontset.o frame.o fringe.o image.o keyboard.o menu.o \
1108 window.o xdisp.o xfaces.o: nsgui.h
1109
1110 ${ns_appdir}: ${ns_appsrc}
1111 rm -fr ${ns_appdir}
1112 mkdir -p ${ns_appdir}
1113 ( cd ${ns_appsrc} ; tar cfh - . ) | ( cd ${ns_appdir} ; tar xf - )
1114 ( cd ${ns_appdir} ; for subdir in `find . -type d ! -name CVS -print` ; do \
1115 chmod a+rx $${subdir} ; \
1116 rm -rf $${subdir}/CVS ; \
1117 rm -f $${subdir}/.cvsignore ; done ; )
1118
1119 ${ns_appbindir}Emacs: emacs${EXEEXT}
1120 mkdir -p ${ns_appbindir}
1121 cp -f emacs${EXEEXT} ${ns_appbindir}Emacs
1122
1123 ns-app: ${ns_appdir} ${ns_appbindir}Emacs
1124
1125 #endif /* HAVE_NS */
1126
1127 mostlyclean:
1128 rm -f temacs${EXEEXT} prefix-args${EXEEXT} core *.core \#* *.o libXMenu11.a liblw.a
1129 rm -f ../etc/DOC
1130 rm -f bootstrap-emacs${EXEEXT} emacs-${version}${EXEEXT}
1131 rm -f buildobj.h
1132 clean: mostlyclean
1133 rm -f emacs-*.*.*${EXEEXT} emacs${EXEEXT}
1134 -rm -rf deps
1135 #ifdef HAVE_NS
1136 rm -fr ${ns_appdir}
1137 #endif
1138 /* bootstrap-clean is used to clean up just before a bootstrap.
1139 It should remove all files generated during a compilation/bootstrap,
1140 but not things like config.status or TAGS. */
1141 bootstrap-clean: clean
1142 rm -f epaths.h config.h Makefile.c config.stamp stamp-oldxmenu ../etc/DOC-*
1143 if test -f ./.gdbinit; then \
1144 mv ./.gdbinit ./.gdbinit.save; \
1145 if test -f "${srcdir}/.gdbinit"; then rm -f ./.gdbinit.save; \
1146 else mv ./.gdbinit.save ./.gdbinit; fi; \
1147 fi
1148 /**/# This is used in making a distribution.
1149 /**/# Do not use it on development directories!
1150 distclean: bootstrap-clean
1151 rm -f Makefile
1152 maintainer-clean: distclean
1153 @echo "This command is intended for maintainers to use;"
1154 @echo "it deletes files that may require special tools to rebuild."
1155 rm -f TAGS
1156 versionclean:
1157 -rm -f emacs${EXEEXT} emacs-*.*.*${EXEEXT} ../etc/DOC*
1158 extraclean: distclean
1159 -rm -f *~ \#* m/?*~ s/?*~
1160
1161 /* Arrange to make a tags table TAGS-LISP for ../lisp,
1162 plus TAGS for the C files, which includes ../lisp/TAGS by reference. */
1163
1164 ctagsfiles1 = [xyzXYZ]*.[hcm]
1165 ctagsfiles2 = [a-wA-W]*.[hcm]
1166
1167 TAGS: $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2)
1168 ../lib-src/etags --include=TAGS-LISP --include=${lwlibdir}/TAGS \
1169 --regex='/[ ]*DEFVAR_[A-Z_ (]+"\([^"]+\)"/' \
1170 $(srcdir)/$(ctagsfiles1) $(srcdir)/$(ctagsfiles2)
1171 frc:
1172 TAGS-LISP: frc
1173 $(MAKE) -f ${lispdir}Makefile TAGS-LISP ETAGS=../lib-src/etags
1174
1175 $(lwlibdir)TAGS:
1176 (cd $(lwlibdir); $(MAKE) -f $(lwlibdir)Makefile tags ETAGS=../lib-src/etags)
1177
1178 tags: TAGS TAGS-LISP $(lwlibdir)TAGS
1179 .PHONY: tags
1180
1181
1182 /* Bootstrapping. */
1183 /* Bootstrapping right is difficult because of the circular dependencies.
1184 Furthermore, we have to deal with the fact that many compilation targets
1185 such as loaddefs.el or *.elc can typically be produced by any old
1186 Emacs executable, so we would like to avoid rebuilding them whenever
1187 we build a new Emacs executable.
1188 To solve the circularity, we use 2 different Emacs executables,
1189 "emacs" is the main target and "bootstrap-emacs" is the one used
1190 to build the *.elc and loaddefs.el files.
1191 To solve the freshness issue, we used to use a third file "witness-emacs"
1192 which was used to witness the fact that there is a bootstrap-emacs
1193 executable, and then have dependencies on witness-emacs rather than
1194 bootstrap-emacs, but that lead to problems in parallel builds (because
1195 witness-emacs needed to be free from dependencies (to avoid rebuilding
1196 it), so it was compiled in parallel, leading typically to having 2
1197 processes dumping bootstrap-emacs at the same time).
1198 So instead, we replace the witness-emacs dependencies by conditional
1199 bootstrap-dependencies (via ${BOOTSTRAPEMACS}). Of course, since we do
1200 not want to rely on GNU Make features, we have to rely on an external
1201 script to do the conditional part of the dependency
1202 (i.e. see the ${SUBDIR} rule ../Makefile.in). */
1203
1204 .SUFFIXES: .elc .el
1205
1206 /* These suffix rules do not allow additional dependencies, sadly, so
1207 instead of adding a $(BOOTSTRAPEMACS) dependency here, we add it
1208 separately below.
1209 With GNU Make, we would just say "%.el : %.elc $(BOOTSTRAPEMACS)" */
1210 .el.elc:
1211 @cd ../lisp; $(MAKE) $(MFLAGS) compile-onefile \
1212 THEFILE=$< EMACS=${bootstrap_exe}
1213
1214 /* Since the .el.elc rule cannot specify an extra dependency, we do it here. */
1215 ${lisp} ${SOME_MACHINE_LISP}: $(BOOTSTRAPEMACS)
1216
1217 ${lispsource}loaddefs.el: $(BOOTSTRAPEMACS)
1218 cd ../lisp; $(MAKE) $(MFLAGS) autoloads EMACS=${bootstrap_exe}
1219
1220 /* Dump an Emacs executable named bootstrap-emacs containing the
1221 files from loadup.el in source form. */
1222
1223 bootstrap-emacs${EXEEXT}: temacs${EXEEXT}
1224 cd ../lisp; $(MAKE) $(MFLAGS) update-subdirs
1225 #ifdef CANNOT_DUMP
1226 ln -f temacs${EXEEXT} bootstrap-emacs${EXEEXT}
1227 #else
1228 $(RUN_TEMACS) --batch --load loadup bootstrap
1229 mv -f emacs${EXEEXT} bootstrap-emacs${EXEEXT}
1230 #endif /* ! defined (CANNOT_DUMP) */
1231 @: Compile some files earlier to speed up further compilation.
1232 cd ../lisp; $(MAKE) $(MFLAGS) compile-first EMACS=${bootstrap_exe}
1233
1234 #ifdef AUTO_DEPEND
1235 ALLOBJS=$(STARTFILES) ${obj} ${otherobj} prefix-args.o
1236 -include $(ALLOBJS:%.o=deps/%.d)
1237 #endif