makefile.w32-in 32.8 KB
Newer Older
1
# -*- Makefile -*- for GNU Emacs on the Microsoft Windows API.
2
# Copyright (C) 2000-2012  Free Software Foundation, Inc.
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18

# This file is part of GNU Emacs.

# GNU Emacs is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.

# GNU Emacs is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
# along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.

Andrew Innes's avatar
Andrew Innes committed
19 20 21 22 23

ALL = emacs

.PHONY: $(ALL)

Andrew Innes's avatar
Andrew Innes committed
24 25 26
# Set EMACSLOADPATH correctly (in case already defined in environment).
EMACSLOADPATH=$(CURDIR)/../lisp

27
# Size in MBs of the static heap in temacs.exe.
28
HEAPSIZE = $(EMACS_HEAPSIZE)
29

30
LOCAL_FLAGS     = -Demacs=1 -I../lib -I../nt/inc $(EMACS_EXTRA_C_FLAGS)
Andrew Innes's avatar
Andrew Innes committed
31

32
SRC             = .
Andrew Innes's avatar
Andrew Innes committed
33 34 35 36 37
EMACS           = $(BLD)/emacs.exe
TEMACS          = $(BLD)/temacs.exe
TEMACS_TMP      = $(BLD)/temacs.bin
TLIB0           = $(BLD)/temacs0.$(A)
TLIB1           = $(BLD)/temacs1.$(A)
38
TLIB2           = $(BLD)/temacs2.$(A)
Andrew Innes's avatar
Andrew Innes committed
39 40 41
TOBJ            = $(BLD)/firstfile.$(O)
TRES		= $(BLD)/emacs.res
TLASTLIB	= $(BLD)/lastfile.$(A)
42
GNULIB		= ../lib/$(BLD)/libgnu.$(A)
Andrew Innes's avatar
Andrew Innes committed
43

44 45
DOC		= $(OBJDIR)/etc/DOC-X

Jason Rumney's avatar
Jason Rumney committed
46 47
FULL_LINK_FLAGS = $(LINK_FLAGS) $(TEMACS_EXTRA_LINK)

Andrew Innes's avatar
Andrew Innes committed
48 49 50 51 52 53 54 55 56
#
# Split up the objects into two sets so that we don't run out of
# command line space when we link them into a library.
#
# Put emacs.$(O) in a separate lib, since we need to have firstfile.$(O)
# as the "main" object file when linking.
#
OBJ0 =  $(BLD)/emacs.$(O)

Jason Rumney's avatar
Jason Rumney committed
57
OBJ1 =  $(BLD)/alloc.$(O)		\
58 59
	$(BLD)/atimer.$(O)		\
	$(BLD)/buffer.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
60 61 62 63
	$(BLD)/bytecode.$(O)		\
	$(BLD)/callint.$(O)		\
	$(BLD)/callproc.$(O)		\
	$(BLD)/casefiddle.$(O)		\
64 65 66
	$(BLD)/cmds.$(O)		\
	$(BLD)/data.$(O)		\
	$(BLD)/dired.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
67 68
	$(BLD)/dispnew.$(O)		\
	$(BLD)/doc.$(O)			\
69
	$(BLD)/doprnt.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
70
	$(BLD)/editfns.$(O)		\
71 72
	$(BLD)/eval.$(O)		\
	$(BLD)/fileio.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
73 74
	$(BLD)/filelock.$(O)		\
	$(BLD)/fns.$(O)			\
75 76
	$(BLD)/indent.$(O)		\
	$(BLD)/insdel.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
77
	$(BLD)/keyboard.$(O)		\
78 79 80 81
	$(BLD)/keymap.$(O)		\
	$(BLD)/lread.$(O)		\
	$(BLD)/macros.$(O)		\
	$(BLD)/marker.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
82 83 84 85 86 87
	$(BLD)/minibuf.$(O)		\
	$(BLD)/w32.$(O)			\
	$(BLD)/w32heap.$(O)		\
	$(BLD)/w32inevt.$(O)		\
	$(BLD)/w32proc.$(O)		\
	$(BLD)/w32console.$(O)		\
88
	$(BLD)/print.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
89
	$(BLD)/process.$(O)		\
90 91 92 93
	$(BLD)/regex.$(O)		\
	$(BLD)/scroll.$(O)		\
	$(BLD)/search.$(O)		\
	$(BLD)/sound.$(O)		\
94 95 96
	$(BLD)/syntax.$(O)

OBJ2 =  $(BLD)/sysdep.$(O)		\
97 98 99
	$(BLD)/term.$(O)		\
	$(BLD)/tparam.$(O)		\
	$(BLD)/undo.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
100
	$(BLD)/unexw32.$(O)		\
101 102
	$(BLD)/window.$(O)		\
	$(BLD)/xdisp.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
103 104
	$(BLD)/casetab.$(O)		\
	$(BLD)/floatfns.$(O)		\
105
	$(BLD)/frame.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
106
	$(BLD)/gmalloc.$(O)		\
107
	$(BLD)/gnutls.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
108 109
	$(BLD)/intervals.$(O)		\
	$(BLD)/composite.$(O)		\
110
	$(BLD)/ralloc.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
111 112
	$(BLD)/textprop.$(O)		\
	$(BLD)/vm-limit.$(O)		\
113
	$(BLD)/region-cache.$(O)	\
114
	$(BLD)/bidi.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
115 116 117
	$(BLD)/charset.$(O)		\
	$(BLD)/character.$(O)		\
	$(BLD)/chartab.$(O)		\
118
	$(BLD)/coding.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
119 120
	$(BLD)/category.$(O)		\
	$(BLD)/ccl.$(O)			\
121
	$(BLD)/font.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
122
	$(BLD)/fontset.$(O)		\
123 124
	$(BLD)/fringe.$(O)		\
	$(BLD)/image.$(O)		\
Jason Rumney's avatar
Jason Rumney committed
125
	$(BLD)/terminal.$(O)            \
126
	$(BLD)/menu.$(O)		\
127
	$(BLD)/xml.$(O)			\
128
	$(BLD)/profiler.$(O)		\
129 130 131 132 133 134 135 136 137
	$(BLD)/w32term.$(O)		\
	$(BLD)/w32xfns.$(O)		\
	$(BLD)/w32fns.$(O)		\
	$(BLD)/xfaces.$(O)		\
	$(BLD)/w32select.$(O)		\
	$(BLD)/w32menu.$(O)		\
	$(BLD)/w32reg.$(O)		\
	$(BLD)/w32font.$(O)		\
	$(BLD)/w32uniscribe.$(O)
138

Andrew Innes's avatar
Andrew Innes committed
139 140
LIBS =  $(TLIB0)	\
	$(TLIB1)	\
141
	$(TLIB2)	\
Andrew Innes's avatar
Andrew Innes committed
142
	$(TLASTLIB)	\
143
	$(GNULIB)	\
Jason Rumney's avatar
Jason Rumney committed
144
	$(WINMM)	\
Andrew Innes's avatar
Andrew Innes committed
145 146 147 148
	$(ADVAPI32)	\
	$(GDI32)	\
	$(COMDLG32)	\
	$(USER32)	\
149
	$(MPR)		\
Andrew Innes's avatar
Andrew Innes committed
150
	$(SHELL32)	\
151
	$(WINSPOOL)	\
Jason Rumney's avatar
Jason Rumney committed
152
	$(OLE32)	\
Jason Rumney's avatar
Jason Rumney committed
153
	$(COMCTL32)	\
154
	$(UNISCRIBE)    \
155
	$(USER_LIBS)    \
Andrew Innes's avatar
Andrew Innes committed
156 157 158 159 160 161 162 163 164 165
	$(libc)

#
# Build the executable and dump it.
#
all:            $(ALL)

#
# The dumped executable
#
166
emacs:          stamp_BLD $(EMACS)
167
$(EMACS):       $(DOC) $(TEMACS)
168
	"$(THISDIR)/$(BLD)/temacs.exe" -batch -l loadup dump
169
	-"$(THISDIR)/$(BLD)/emacs.exe" -batch -f list-load-path-shadows
Andrew Innes's avatar
Andrew Innes committed
170 171 172 173 174 175 176

#
# The undumped executable
# Note the extra post-link step to insert a static preload heap section.
# If preload runs out of memory, increase the last argument to addsection
# (it is the preload heap size in MB).
#
177
temacs:         stamp_BLD $(TEMACS)
178
$(TEMACS):      $(TLIB0) $(TLIB1) $(TLIB2) $(TLASTLIB) $(TOBJ) $(TRES) \
179
		  ../nt/$(BLD)/addsection.exe $(GNULIB)
Andrew Innes's avatar
Andrew Innes committed
180
	$(LINK) $(LINK_OUT)$(TEMACS_TMP) $(FULL_LINK_FLAGS) $(TOBJ) $(TRES) $(LIBS)
181
	"$(THISDIR)/../nt/$(BLD)/addsection" "$(TEMACS_TMP)" "$(TEMACS)" EMHEAP $(HEAPSIZE)
182 183 184

# These omit firstfile.${O}, but there's no documentation in there
# anyways.
185
buildobj.h: $(SRC)/makefile.w32-in
186 187
	$(MAKE) $(MFLAGS) make-buildobj-$(SHELLTYPE)

188 189
# Cannot have blanks between the backslash and the redirection
# characters, because CMD's `echo' will put them in buildobj.h.
190
make-buildobj-CMD:
191 192 193
	echo #define BUILDOBJ ^"\> buildobj.h
	echo $(OBJ0)            \>> buildobj.h
	echo $(OBJ1)            \>> buildobj.h
194
	echo $(OBJ2)            \>> buildobj.h
195
	echo ^">> buildobj.h
196

197 198 199
# "
# The above line is here to countermand the single quote
# on the last "echo" command above, wrt font-lock.
200
make-buildobj-SH:
201 202 203
	echo '#define BUILDOBJ $(DQUOTE)\'  > buildobj.h
	echo $(OBJ0)                   '\' >> buildobj.h
	echo $(OBJ1)                   '\' >> buildobj.h
204
	echo $(OBJ2)                   '\' >> buildobj.h
205
	echo '$(DQUOTE)'                   >> buildobj.h
Andrew Innes's avatar
Andrew Innes committed
206

207 208 209
GLOBAL_SOURCES =   dosfns.c msdos.c \
	xterm.c xfns.c xmenu.c xselect.c xrdb.c xsmfns.c fringe.c image.c \
	fontset.c menu.c dbusbind.c \
210
	w32.c w32console.c w32fns.c w32heap.c w32inevt.c cygw32.c \
211 212 213 214 215 216 217
	w32menu.c w32proc.c w32reg.c w32select.c w32term.c w32xfns.c \
	font.c w32font.c w32uniscribe.c \
	dispnew.c frame.c scroll.c xdisp.c window.c bidi.c \
	charset.c coding.c category.c ccl.c character.c chartab.c \
	cm.c term.c terminal.c xfaces.c \
	emacs.c keyboard.c macros.c keymap.c sysdep.c \
	buffer.c filelock.c insdel.c marker.c \
218
	minibuf.c fileio.c dired.c \
219 220 221 222 223 224
	cmds.c casetab.c casefiddle.c indent.c search.c regex.c undo.c \
	alloc.c data.c doc.c editfns.c callint.c \
	eval.c floatfns.c fns.c print.c lread.c \
	syntax.c bytecode.c \
	process.c callproc.c unexw32.c \
	region-cache.c sound.c atimer.c \
225
	doprnt.c intervals.c textprop.c composite.c \
226
	gnutls.c xml.c profiler.c
227
SOME_MACHINE_OBJECTS = dosfns.o msdos.o \
228
	xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o dbusbind.o
229 230 231
obj = $(GLOBAL_SOURCES:.c=.o)

globals.h: gl-stamp
232
	@cmd /c rem true
233 234 235

gl-stamp: ../lib-src/$(BLD)/make-docfile.exe $(GLOBAL_SOURCES)
	- $(DEL) gl-tmp
236
	"$(THISDIR)/../lib-src/$(BLD)/make-docfile" -d . -g $(SOME_MACHINE_OBJECTS) $(obj) > gl-tmp
237 238 239 240
	cmd /c "fc /b gl-tmp globals.h >nul 2>&1 || $(CP) gl-tmp globals.h"
	- $(DEL) gl-tmp
	echo timestamp > $@

Andrew Innes's avatar
Andrew Innes committed
241 242 243 244 245 246
bootstrap: bootstrap-emacs

#
# Build a temacs with a sufficiently large PURESIZE to load the
# Lisp files from loadup.el in source form.
#
247 248
# WARNING: Do NOT split the part inside $(ARGQUOTE)s into multiple lines as
#          this can break with GNU Make 3.81 and later if sh.exe is used.
249
bootstrap-temacs-CMD:
250
	$(MAKE) $(MFLAGS) $(XMFLAGS) temacs CFLAGS=$(ARGQUOTE)$(ESC_CFLAGS) -DPURESIZE=$(EMACS_PURESIZE)$(ARGQUOTE)
251 252

bootstrap-temacs-SH:
253
	$(MAKE) $(MFLAGS) $(XMFLAGS) temacs CFLAGS=$(ARGQUOTE)$(CFLAGS) -DPURESIZE=$(EMACS_PURESIZE)$(ARGQUOTE)
Andrew Innes's avatar
Andrew Innes committed
254

255 256 257
bootstrap-temacs:
	$(MAKE) $(MFLAGS) bootstrap-temacs-$(SHELLTYPE)

Andrew Innes's avatar
Andrew Innes committed
258
#
259
# Dump an Emacs executable named bootstrap-emacs containing the
Andrew Innes's avatar
Andrew Innes committed
260 261 262
# files from loadup.el in source form.
#
bootstrap-emacs: bootstrap-temacs
263
	"$(THISDIR)/$(BLD)/temacs.exe" -batch -l loadup bootstrap
Andrew Innes's avatar
Andrew Innes committed
264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280
	- mkdir "../bin"
	$(CP) $(EMACS) ../bin

#
# Force recompile of files that depend on PURESIZE
#
bootstrap-clean:
	- $(DEL) $(BLD)/alloc.$(O)
	- $(DEL) $(BLD)/data.$(O)
	- $(DEL) $(BLD)/intervals.$(O)
	- $(DEL) $(BLD)/keyboard.$(O)
	- $(DEL) $(BLD)/keymap.$(O)

#
# The resource file.  NT 3.10 requires the use of cvtres; even though
# it is not necessary on later versions, it is still ok to use it.
#
281
$(TRES): ../nt/emacs.rc stamp_BLD
282
	$(RC) $(RC_INCLUDE)../nt $(RC_OUT)$@ ../nt/emacs.rc
Andrew Innes's avatar
Andrew Innes committed
283 284

#
285
# Build the library.  Split up the build into two phases...otherwise we
Andrew Innes's avatar
Andrew Innes committed
286 287 288 289 290 291 292 293
# run out of command line space.
#
$(TLIB0):       $(OBJ0)
	- $(DEL) $@
	$(AR) $(AR_OUT)$@ $(ALL_DEPS)
$(TLIB1):       $(OBJ1)
	- $(DEL) $@
	$(AR) $(AR_OUT)$@ $(ALL_DEPS)
294
$(TLIB2):	$(OBJ2)
Andrew Innes's avatar
Andrew Innes committed
295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315
	- $(DEL) $@
	$(AR) $(AR_OUT)$@ $(ALL_DEPS)

#
# Place lastfile.$(O) in its own library so that it can be loaded after
# the source libraries but before any system libraries.  Doing so defines
# the end of Emacs' data section portably across compilers and systems.
#
$(TLASTLIB):	$(BLD)/lastfile.$(O)
	- $(DEL) $@
	$(AR) $(AR_OUT)$@ $(ALL_DEPS)

#
# Assuming INSTALL_DIR is defined, build and install emacs in it.
#
install:        $(ALL)
	- mkdir "$(INSTALL_DIR)/bin"
	$(CP) $(EMACS) $(INSTALL_DIR)/bin

#
# Maintenance
316
#
Eli Zaretskii's avatar
Eli Zaretskii committed
317 318
# We used to delete *~, s/*~, m/*~ here, but that might inadvertently
# remove precious files if it happens to match their short 8+3 aliases.
Andrew Innes's avatar
Andrew Innes committed
319
clean:
Eli Zaretskii's avatar
Eli Zaretskii committed
320
	- $(DEL) "s/*.h~" "m/*.h~"
321
	- $(DEL) $(COMPILER_TEMP_FILES)
Andrew Innes's avatar
Andrew Innes committed
322
	- $(DEL_TREE) $(OBJDIR)
323
	- $(DEL) stamp_BLD gl-stamp globals.h
Eli Zaretskii's avatar
Eli Zaretskii committed
324
	- $(DEL) buildobj.h
Andrew Innes's avatar
Andrew Innes committed
325

326 327 328 329 330
distclean:	cleanall
	- $(DEL) config.h epaths.h Makefile

maintainer-clean: distclean
	- $(DEL) TAGS
Andrew Innes's avatar
Andrew Innes committed
331 332 333 334 335 336 337

cleanall:	clean
	- $(DEL_TREE) obj
	- $(DEL_TREE) obj-spd
	- $(DEL_TREE) oo
	- $(DEL_TREE) oo-spd

338 339 340 341 342
## Arrange to make a tags table TAGS-LISP for ../lisp,
## plus TAGS for the C files, which includes ../lisp/TAGS by reference.
##
## This works only with GNU Make.

343
TAGS: $(OBJ0) $(OBJ1) $(OBJ2) $(CURDIR)/../nt/inc/ms-w32.h
344 345
	$(MAKE) $(MFLAGS) TAGS-$(MAKETYPE)

346
TAGS-LISP: $(OBJ0) $(OBJ1) $(OBJ2)
347 348 349 350 351
	$(MAKE) $(MFLAGS) TAGS-LISP-$(MAKETYPE)

TAGS-gmake:
	../lib-src/$(BLD)/etags.exe --include=TAGS-LISP --include=../nt/TAGS \
	  --regex=@../nt/emacs-src.tags \
352
	  $(OBJ0_c)
353
	../lib-src/$(BLD)/etags.exe -a --regex=@../nt/emacs-src.tags \
354
	  $(OBJ1_c)
355
	../lib-src/$(BLD)/etags.exe -a --regex=@../nt/emacs-src.tags \
356
	  $(OBJ2_c) \
357
	  $(CURDIR)/*.h $(CURDIR)/../nt/inc/ms-w32.h
358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380

TAGS-nmake:
	echo This target is not supported with NMake
	exit -1

frc:
TAGS-LISP-gmake: frc
	$(MAKE) $(MFLAGS) -C ../lisp TAGS-LISP DEST=../src

TAGS-LISP-nmake:
	echo This target is not supported with NMake
	exit -1

../nt/TAGS: frc
	$(MAKE) $(MFLAGS) nt-TAGS-$(MAKETYPE)

nt-TAGS-gmake:
	$(MAKE) $(MFLAGS) -C ../nt TAGS

nt-TAGS-nmake:
	echo This target is not supported with NMake
	exit -1

381 382
full-tags: TAGS TAGS-LISP ../nt/TAGS
.PHONY: full-tags
383

Andrew Innes's avatar
Andrew Innes committed
384 385
### DEPENDENCIES ###

386
EMACS_ROOT = ..
387 388 389
GNU_LIB = $(EMACS_ROOT)/lib
NT_INC = $(EMACS_ROOT)/nt/inc

390
SYSTIME_H      = $(SRC)/systime.h \
391 392
		 $(NT_INC)/sys/time.h \
		 $(GNU_LIB)/timespec.h
393
ATIMER_H       = $(SRC)/atimer.h \
394
		 $(NT_INC)/stdbool.h \
395
		 $(SYSTIME_H)
396 397
BUFFER_H       = $(SRC)/buffer.h \
		 $(SYSTIME_H)
398 399
C_CTYPE_H      = $(GNU_LIB)/c-ctype.h \
		 $(NT_INC)/stdbool.h
400 401 402 403
CAREADLINKAT_H = $(GNU_LIB)/careadlinkat.h \
		 $(NT_INC)/unistd.h
CHARACTER_H    = $(SRC)/character.h \
		 $(GNU_LIB)/verify.h
404 405
CCL_H          = $(SRC)/ccl.h \
		 $(CHARACTER_H)
406 407 408 409
CHARSET_H      = $(SRC)/charset.h \
		 $(GNU_LIB)/verify.h
CODING_H       = $(SRC)/coding.h \
		 $(SRC)/composite.h
410
MS_W32_H       = $(NT_INC)/ms-w32.h \
411
		 $(NT_INC)/sys/stat.h
412
CONF_POST_H    = $(SRC)/conf_post.h \
413
		 $(MS_W32_H)
414 415
CONFIG_H       = $(SRC)/config.h \
		 $(CONF_POST_H)
416 417 418 419 420
DIR_H          = $(NT_INC)/sys/dir.h \
		 $(SRC)/ndir.h
W32GUI_H       = $(SRC)/w32gui.h \
		 $(SYSTIME_H)
DISPEXTERN_H   = $(SRC)/dispextern.h \
421
		 $(GNU_LIB)/c-strcase.h \
422
		 $(SYSTIME_H) \
423 424 425 426 427
		 $(W32GUI_H)
FILEMODE_H     = $(GNU_LIB)/filemode.h \
		 $(NT_INC)/sys/stat.h
FRAME_H        = $(SRC)/frame.h \
		 $(DISPEXTERN_H)
428 429 430
FONT_H         = $(SRC)/font.h \
		 $(CCL_H) \
		 $(FRAME_H)
431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447
FTOASTR_H      = $(GNU_LIB)/ftoastr.h \
		 $(GNU_LIB)/intprops.h
GRP_H          = $(NT_INC)/grp.h \
		 $(NT_INC)/pwd.h
INTERVALS_H    = $(SRC)/intervals.h \
		 $(SRC)/composite.h \
		 $(DISPEXTERN_H)
INTTYPES_H     = $(NT_INC)/inttypes.h \
		 $(NT_INC)/stdint.h
KEYBOARD_H     = $(SRC)/keyboard.h \
		 $(CODING_H) \
		 $(SYSTIME_H)
LANGINFO_H     = $(NT_INC)/langinfo.h \
		 $(NT_INC)/nl_types.h
LISP_H         = $(SRC)/lisp.h \
		 $(SRC)/globals.h \
		 $(GNU_LIB)/intprops.h \
448
		 $(INTTYPES_H) \
449 450
		 $(NT_INC)/stdalign.h \
		 $(NT_INC)/stdbool.h
451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467
MD5_H          = $(GNU_LIB)/md5.h \
		 $(NT_INC)/stdint.h
MENU_H         = $(SRC)/menu.h \
		 $(SYSTIME_H)
PROCESS_H      = $(SRC)/process.h \
		 $(SRC)/gnutls.h \
		 $(NT_INC)/unistd.h
SHA1_H         = $(GNU_LIB)/sha1.h \
		 $(NT_INC)/stdint.h
SHA256_H       = $(GNU_LIB)/sha256.h \
		 $(NT_INC)/stdint.h
U64_H          = $(GNU_LIB)/u64.h \
		 $(NT_INC)/stdint.h
SHA512_H       = $(GNU_LIB)/sha512.h \
		 $(U64_H)
SOCKET_H       = $(NT_INC)/sys/socket.h \
		 $(SRC)/w32.h
468
STAT_TIME_H    = $(GNU_LIB)/stat-time.h \
469
		 $(NT_INC)/sys/stat.h
470 471
SYSSIGNAL_H    = $(SRC)/syssignal.h \
		 $(NT_INC)/stdbool.h
472 473 474 475 476
SYSTTY_H       = $(SRC)/systty.h \
		 $(NT_INC)/sys/ioctl.h \
		 $(NT_INC)/unistd.h
TERMHOOKS_H    = $(SRC)/termhooks.h \
		 $(SYSTIME_H)
477 478
W32FONT_H      = $(SRC)/w32font.h \
		 $(FONT_H)
479
W32TERM_H      = $(SRC)/w32term.h \
480 481
		 $(ATIMER_H) \
		 $(FRAME_H) \
482 483 484
		 $(W32GUI_H)
WINDOW_H       = $(SRC)/window.h \
		 $(DISPEXTERN_H)
Andrew Innes's avatar
Andrew Innes committed
485

486
$(BLD)/alloc.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
487
	$(SRC)/alloc.c \
488
	$(SRC)/blockinput.h \
Andrew Innes's avatar
Andrew Innes committed
489
	$(SRC)/puresize.h \
490
	$(SRC)/w32.h \
491
	$(SRC)/w32heap.h \
492
	$(NT_INC)/unistd.h \
493
	$(GNU_LIB)/verify.h \
494
	$(BUFFER_H) \
495 496 497 498 499 500 501 502 503
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(PROCESS_H) \
	$(TERMHOOKS_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
504

505
$(BLD)/atimer.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
506
	$(SRC)/atimer.c \
507
	$(SRC)/blockinput.h \
508 509
	$(NT_INC)/unistd.h \
	$(ATIMER_H) \
510
	$(CONFIG_H) \
511
	$(LISP_H) \
512
	$(SYSSIGNAL_H) \
513
	$(SYSTIME_H)
Andrew Innes's avatar
Andrew Innes committed
514

515 516
$(BLD)/bidi.$(O) : \
	$(SRC)/bidi.c \
517
	$(BUFFER_H) \
518 519 520 521
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(DISPEXTERN_H) \
	$(LISP_H)
522

523
$(BLD)/buffer.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
524
	$(SRC)/buffer.c \
525
	$(SRC)/blockinput.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
526
	$(SRC)/commands.h \
Andrew Innes's avatar
Andrew Innes committed
527
	$(SRC)/indent.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
528 529
	$(SRC)/keymap.h \
	$(SRC)/region-cache.h \
530 531 532 533
	$(NT_INC)/sys/param.h \
	$(NT_INC)/sys/stat.h \
	$(NT_INC)/unistd.h \
	$(GNU_LIB)/verify.h \
534
	$(BUFFER_H) \
535 536 537 538 539 540 541
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
542

543
$(BLD)/bytecode.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
544
	$(SRC)/bytecode.c \
545
	$(SRC)/syntax.h \
546
	$(BUFFER_H) \
547 548 549 550
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(LISP_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
551

552
$(BLD)/callint.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
553 554
	$(SRC)/callint.c \
	$(SRC)/commands.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
555
	$(SRC)/keymap.h \
556
	$(BUFFER_H) \
557 558 559 560 561
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
562

563
$(BLD)/callproc.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
564
	$(SRC)/callproc.c \
565
	$(SRC)/blockinput.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
566 567 568
	$(SRC)/commands.h \
	$(SRC)/composite.h \
	$(SRC)/epaths.h \
569
	$(SRC)/syswait.h \
570
	$(SRC)/w32.h \
571 572
	$(NT_INC)/sys/file.h \
	$(NT_INC)/unistd.h \
573
	$(BUFFER_H) \
574
	$(CCL_H) \
575 576 577 578 579 580
	$(CHARACTER_H) \
	$(CODING_H) \
	$(CONFIG_H) \
	$(FRAME_H) \
	$(LISP_H) \
	$(PROCESS_H) \
581
	$(SYSSIGNAL_H) \
582 583
	$(SYSTTY_H) \
	$(TERMHOOKS_H)
Andrew Innes's avatar
Andrew Innes committed
584

585
$(BLD)/casefiddle.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
586 587
	$(SRC)/casefiddle.c \
	$(SRC)/commands.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
588 589
	$(SRC)/composite.h \
	$(SRC)/keymap.h \
590
	$(SRC)/syntax.h \
591
	$(BUFFER_H) \
592 593 594
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
595

596
$(BLD)/casetab.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
597
	$(SRC)/casetab.c \
598
	$(BUFFER_H) \
599 600 601
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(LISP_H)
Juanma Barranquero's avatar
Juanma Barranquero committed
602 603 604 605

$(BLD)/category.$(O) : \
	$(SRC)/category.c \
	$(SRC)/category.h \
606
	$(SRC)/keymap.h \
607
	$(BUFFER_H) \
608 609 610 611
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CONFIG_H) \
	$(LISP_H)
Juanma Barranquero's avatar
Juanma Barranquero committed
612 613 614

$(BLD)/ccl.$(O) : \
	$(SRC)/ccl.c \
615
	$(CCL_H) \
616 617 618 619 620
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CODING_H) \
	$(CONFIG_H) \
	$(LISP_H)
Juanma Barranquero's avatar
Juanma Barranquero committed
621

622 623 624
$(BLD)/character.$(O) : \
	$(SRC)/character.c \
	$(SRC)/composite.h \
625 626
	$(SRC)/disptab.h \
	$(GNU_LIB)/intprops.h \
627
	$(BUFFER_H) \
628 629 630 631
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CONFIG_H) \
	$(LISP_H)
632

Juanma Barranquero's avatar
Juanma Barranquero committed
633 634
$(BLD)/charset.$(O) : \
	$(SRC)/charset.c \
635 636
	$(SRC)/disptab.h \
	$(NT_INC)/unistd.h \
637
	$(BUFFER_H) \
638 639 640 641
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CODING_H) \
	$(CONFIG_H) \
642
	$(C_CTYPE_H) \
643
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
644

645 646
$(BLD)/chartab.$(O) : \
	$(SRC)/chartab.c \
647
	$(CCL_H) \
648 649 650 651
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CONFIG_H) \
	$(LISP_H)
652

653
$(BLD)/cmds.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
654 655
	$(SRC)/cmds.c \
	$(SRC)/commands.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
656 657
	$(SRC)/keymap.h \
	$(SRC)/syntax.h \
658
	$(BUFFER_H) \
659 660 661 662 663 664 665
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(DISPEXTERN_H) \
	$(FRAME_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(WINDOW_H)
Juanma Barranquero's avatar
Juanma Barranquero committed
666 667 668 669

$(BLD)/coding.$(O) : \
	$(SRC)/coding.c \
	$(SRC)/composite.h \
670
	$(BUFFER_H) \
671
	$(CCL_H) \
672 673 674 675 676 677 678 679
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CODING_H) \
	$(CONFIG_H) \
	$(FRAME_H) \
	$(LISP_H) \
	$(TERMHOOKS_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
680

681
$(BLD)/composite.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
682
	$(SRC)/composite.c \
683
	$(BUFFER_H) \
684 685
	$(CHARACTER_H) \
	$(CODING_H) \
686
	$(CONFIG_H) \
687 688 689 690
	$(DISPEXTERN_H) \
	$(FONT_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
691
	$(LISP_H) \
692 693
	$(TERMHOOKS_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
694

695
$(BLD)/data.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
696
	$(SRC)/data.c \
697
	$(SRC)/keymap.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
698
	$(SRC)/puresize.h \
699
	$(GNU_LIB)/intprops.h \
700
	$(BUFFER_H) \
701 702 703 704 705 706
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(FONT_H) \
	$(FRAME_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
707
	$(SYSSIGNAL_H) \
708
	$(TERMHOOKS_H)
Andrew Innes's avatar
Andrew Innes committed
709

710
$(BLD)/dired.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
711
	$(SRC)/dired.c \
712
	$(SRC)/blockinput.h \
Andrew Innes's avatar
Andrew Innes committed
713
	$(SRC)/commands.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
714
	$(SRC)/regex.h \
715 716 717
	$(NT_INC)/pwd.h \
	$(NT_INC)/sys/stat.h \
	$(NT_INC)/unistd.h \
718
	$(BUFFER_H) \
719 720 721 722 723 724 725 726
	$(CHARACTER_H) \
	$(CHARSET_H) \
	$(CODING_H) \
	$(CONFIG_H) \
	$(DIR_H) \
	$(FILEMODE_H) \
	$(GRP_H) \
	$(LISP_H) \
727
	$(STAT_TIME_H) \
728
	$(SYSTIME_H)
Andrew Innes's avatar
Andrew Innes committed
729

730
$(BLD)/dispnew.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
731
	$(SRC)/dispnew.c \
732
	$(SRC)/blockinput.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
733
	$(SRC)/cm.h \
Andrew Innes's avatar
Andrew Innes committed
734 735 736
	$(SRC)/commands.h \
	$(SRC)/disptab.h \
	$(SRC)/indent.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
737
	$(SRC)/termchar.h \
738
	$(NT_INC)/unistd.h \
739
	$(BUFFER_H) \
740 741 742 743 744 745 746 747
	$(CHARACTER_H) \
	$(CONFIG_H) \
	$(DISPEXTERN_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(PROCESS_H) \
748
	$(SYSSIGNAL_H) \
749 750 751 752
	$(SYSTIME_H) \
	$(TERMHOOKS_H) \
	$(W32TERM_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
753

754
$(BLD)/doc.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
755
	$(SRC)/doc.c \
756
	$(SRC)/buildobj.h \
757
	$(SRC)/keymap.h \
758 759
	$(NT_INC)/sys/file.h \
	$(NT_INC)/unistd.h \
760
	$(BUFFER_H) \
761 762
	$(CHARACTER_H) \
	$(CONFIG_H) \
763
	$(C_CTYPE_H) \
764 765
	$(KEYBOARD_H) \
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
766

767
$(BLD)/doprnt.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
768
	$(SRC)/doprnt.c \
769 770
	$(NT_INC)/unistd.h \
	$(CHARACTER_H) \
771
	$(CONFIG_H) \
772
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
773

774
$(BLD)/editfns.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
775
	$(SRC)/editfns.c \
776
	$(SRC)/blockinput.h \
777 778 779 780 781
	$(NT_INC)/pwd.h \
	$(NT_INC)/unistd.h \
	$(GNU_LIB)/intprops.h \
	$(GNU_LIB)/strftime.h \
	$(GNU_LIB)/verify.h \
782
	$(BUFFER_H) \
783 784
	$(CHARACTER_H) \
	$(CODING_H) \
785
	$(CONFIG_H) \
786 787
	$(FRAME_H) \
	$(INTERVALS_H) \
788
	$(LISP_H) \
789 790
	$(SYSTIME_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
791

792
$(BLD)/emacs.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
793
	$(SRC)/emacs.c \
794
	$(SRC)/blockinput.h \
Andrew Innes's avatar
Andrew Innes committed
795
	$(SRC)/commands.h \
796
	$(SRC)/gnutls.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
797
	$(SRC)/keymap.h \
798
	$(SRC)/unexec.h \
799
	$(SRC)/w32.h \
800
	$(SRC)/w32heap.h \
801
	$(SRC)/w32select.h \
802 803
	$(NT_INC)/sys/file.h \
	$(NT_INC)/unistd.h \
804 805
	$(GNU_LIB)/ignore-value.h \
	$(ATIMER_H) \
806
	$(BUFFER_H) \
807
	$(CHARACTER_H) \
808 809 810 811 812 813
	$(CONFIG_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
	$(KEYBOARD_H) \
	$(LISP_H) \
	$(PROCESS_H) \
814
	$(SYSSIGNAL_H) \
815 816
	$(SYSTTY_H) \
	$(TERMHOOKS_H) \
817
	$(W32FONT_H) \
818
	$(W32TERM_H) \
819
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
820

821
$(BLD)/eval.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
822
	$(SRC)/eval.c \
823
	$(SRC)/blockinput.h \
Andrew Innes's avatar
Andrew Innes committed
824
	$(SRC)/commands.h \
825 826 827 828 829
	$(CONFIG_H) \
	$(DISPEXTERN_H) \
	$(FRAME_H) \
	$(KEYBOARD_H) \
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
830

831
$(BLD)/fileio.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
832
	$(SRC)/fileio.c \
833
	$(SRC)/blockinput.h \
Juanma Barranquero's avatar
Juanma Barranquero committed
834
	$(SRC)/commands.h \
835
	$(NT_INC)/pwd.h \
836
	$(NT_INC)/sys/file.h \
837 838
	$(NT_INC)/sys/stat.h \
	$(NT_INC)/unistd.h \
839
	$(BUFFER_H) \
840 841 842
	$(CHARACTER_H) \
	$(CODING_H) \
	$(CONFIG_H) \
843
	$(C_CTYPE_H) \
844 845 846 847
	$(DISPEXTERN_H) \
	$(FRAME_H) \
	$(INTERVALS_H) \
	$(LISP_H) \
848
	$(STAT_TIME_H) \
849 850
	$(SYSTIME_H) \
	$(WINDOW_H)
Andrew Innes's avatar
Andrew Innes committed
851

852
$(BLD)/filelock.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
853
	$(SRC)/filelock.c \
854 855 856 857
	$(NT_INC)/pwd.h \
	$(NT_INC)/sys/file.h \
	$(NT_INC)/sys/stat.h \
	$(NT_INC)/unistd.h \
858
	$(BUFFER_H) \
859 860
	$(CHARACTER_H) \
	$(CODING_H) \
861
	$(CONFIG_H) \
862
	$(LISP_H) \
863
	$(SYSTIME_H)
Andrew Innes's avatar
Andrew Innes committed
864

865
$(BLD)/firstfile.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
866
	$(SRC)/firstfile.c \
867
	$(CONFIG_H)
Andrew Innes's avatar
Andrew Innes committed
868

869
$(BLD)/floatfns.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
870
	$(SRC)/floatfns.c \
871
	$(CONFIG_H) \
872
	$(LISP_H)
Andrew Innes's avatar
Andrew Innes committed
873

874
$(BLD)/fns.$(O) : \
Andrew Innes's avatar
Andrew Innes committed
875
	$(SRC)/fns.c \
876
	$(SRC)/blockinput.h \