]> code.delx.au - gnu-emacs/blob - lib-src/makefile.nt
(BASE_PURESIZE): Increased by 10k.
[gnu-emacs] / lib-src / makefile.nt
1 # Makefile for GNU Emacs lib-src directory.
2 # Geoff Voelker (voelker@cs.washington.edu)
3 # Copyright (C) 1994 Free Software Foundation, Inc.
4 #
5 # This file is part of GNU Emacs.
6 #
7 # GNU Emacs is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2, or (at your option)
10 # any later version.
11 #
12 # GNU Emacs is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with GNU Emacs; see the file COPYING. If not, write to the
19 # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 # Boston, MA 02111-1307, USA.
21 #
22
23 #
24 # Sets up the system dependent macros.
25 #
26 !include ..\nt\makefile.def
27
28 LOCAL_FLAGS = -DWINDOWSNT -DDOS_NT -DSTDC_HEADERS=1 -DNO_LDAV=1 -DNO_ARCHIVES=1 -I..\nt\inc -I..\src
29
30 LINK_FLAGS = $(ARCH_LDFLAGS) -debug:PARTIAL -machine:$(ARCH) -subsystem:console -entry:mainCRTStartup setargv.obj
31
32 ALL = $(BLD)\make-docfile.exe \
33 $(BLD)\hexl.exe \
34 $(BLD)\ctags.exe \
35 $(BLD)\etags.exe \
36 $(BLD)\movemail.exe \
37 $(BLD)\fakemail.exe \
38
39
40 # don't know what (if) to do with these yet...
41 #
42 # $(BLD)\sorted-doc.exe \
43 # $(BLD)\env.exe \
44 # $(BLD)\server.exe \
45 # $(BLD)\emacstool.exe \
46 # $(BLD)\leditcfns.exe \
47 # $(BLD)\emacsclient.exe \
48 # $(BLD)\cvtmail.exe \
49 # $(BLD)\digest-doc.exe \
50 # $(BLD)\test-distrib.exe \
51
52
53 LIBS = $(BASE_LIBS)
54
55 $(BLD)\make-docfile.exe: $(BLD)\make-docfile.obj $(BLD)\ntlib.obj
56 $(LINK) -out:$@ $(LINK_FLAGS) $(BLD)\make-docfile.obj $(BLD)\ntlib.obj $(LIBS)
57 $(BLD)\hexl.exe: $(BLD)\hexl.obj
58 $(BLD)\fakemail.exe: $(BLD)\fakemail.obj $(BLD)\ntlib.obj
59 $(LINK) -out:$@ $(LINK_FLAGS) -debug:full $(BLD)\fakemail.obj $(BLD)\ntlib.obj $(LIBS)
60
61 make-docfile: $(BLD) $(BLD)\make-docfile.exe
62 etags: $(BLD) $(BLD)\etags.exe
63 hexl: $(BLD) $(BLD)\hexl.exe
64 movemail: $(BLD) $(BLD)\movemail.exe
65 fakemail: $(BLD) $(BLD)\fakemail.exe
66
67 GETOPTOBJS = $(BLD)\getopt.obj $(BLD)\getopt1.obj
68 GETOPTDEPS = $(GETOPTOBJS) getopt.h
69 MOVEMAILOBJS = $(BLD)\movemail.obj \
70 $(BLD)\pop.obj \
71 $(BLD)\ntlib.obj \
72 $(GETOPTOBJS)
73
74 $(BLD)\movemail.exe: $(MOVEMAILOBJS) getopt.h
75 $(LINK) -out:$@ $(LINK_FLAGS) -debug:FULL $(MOVEMAILOBJS) $(LIBS) wsock32.lib
76
77 ETAGSOBJ = $(BLD)\etags.obj \
78 $(BLD)\getopt.obj \
79 $(BLD)\getopt1.obj \
80 $(BLD)\ntlib.obj \
81 $(BLD)\regex.obj \
82 $(BLD)\alloca.obj
83
84
85 $(BLD)\etags.exe: $(ETAGSOBJ)
86 $(LINK) -out:$@ $(LINK_FLAGS) $(ETAGSOBJ) $(LIBS)
87
88
89 $(BLD)\regex.obj: ../src/regex.c ../src/regex.h ../src/config.h
90 $(CC) $(CFLAGS) -DCONFIG_BROKETS -DINHIBIT_STRING_HEADER \
91 ../src/regex.c -Fo$@
92
93 ETAGS_CFLAGS = -DETAGS_REGEXPS -DHAVE_GETCWD
94 $(BLD)\etags.obj: etags.c
95 $(CC) $(CFLAGS) $(ETAGS_CFLAGS) -Fo$@ etags.c
96
97 CTAGSOBJ = $(BLD)\ctags.obj \
98 $(BLD)\getopt.obj \
99 $(BLD)\getopt1.obj \
100 $(BLD)\ntlib.obj \
101 $(BLD)\regex.obj \
102 $(BLD)\alloca.obj
103
104 $(BLD)\ctags.exe: ctags.c $(CTAGSOBJ)
105 $(LINK) -out:$@ $(LINK_FLAGS) $(CTAGSOBJ) $(LIBS)
106
107 ctags.c: etags.c
108 - $(DEL) ctags.c
109 copy etags.c ctags.c
110
111 CTAGS_CFLAGS = -DCTAGS $(ETAGS_CFLAGS)
112 $(BLD)\ctags.obj: ctags.c
113 $(CC) $(CFLAGS) $(CTAGS_CFLAGS) -Fo$@ ctags.c
114
115 #
116 # don't know what to do with these yet...
117 #
118 # $(BLD)\sorted-doc.exe: $(BLD)\sorted-doc.obj
119 # $(BLD)\yow.exe: $(BLD)\yow.obj
120 # $(BLD)\emacstool.exe: $(BLD)\emacstool.obj
121 # $(BLD)\leditcfns.exe: $(BLD)\leditcfns.obj
122 # $(BLD)\server.exe: $(BLD)\server.obj
123 # $(BLD)\cvtmail.exe: $(BLD)\cvtmail.obj
124 # $(BLD)\digest-doc.exe: $(BLD)\digest-doc.obj
125 # $(BLD)\emacsclient.exe: $(BLD)\emacsclient.obj
126 # $(BLD)\test-distrib.exe: $(BLD)\test-distrib.obj
127
128 #
129 # From ..\src\makefile.nt.
130 #
131 obj = abbrev.c alloc.c alloca.c buffer.c bytecode.c callint.c callproc.c casefiddle.c cm.c cmds.c charset.c coding.c category.c ccl.c data.c dired.c dispnew.c doc.c doprnt.c editfns.c eval.c fileio.c filelock.c filemode.c fns.c fontset.c indent.c insdel.c keyboard.c keymap.c lastfile.c lread.c macros.c marker.c minibuf.c xfaces.c mocklisp.c print.c process.c regex.c scroll.c search.c syntax.c sysdep.c term.c termcap.c tparam.c undo.c unexw32.c window.c xdisp.c casetab.c floatfns.c frame.c gmalloc.c intervals.c ralloc.c textprop.c vm-limit.c region-cache.c strftime.c w32.c w32console.c w32faces.c w32fns.c w32heap.c w32inevt.c w32proc.c w32reg.c w32menu.c w32select.c w32term.c w32xfns.c
132
133 #
134 # These are the lisp files that are loaded up in loadup.el
135 #
136 lispsource = ../lisp/
137
138 FACE_SUPPORT = $(lispsource)facemenu.elc
139 MOUSE_SUPPORT = $(lispsource)select.elc $(lispsource)scroll-bar.elc
140 FLOAT_SUPPORT = $(lispsource)float-sup.elc
141 WINNT_SUPPORT = $(lispsource)ls-lisp.elc $(lispsource)w32-fns.elc $(lispsource)dos-w32.elc
142
143 lisp= \
144 $(lispsource)abbrev.elc \
145 $(lispsource)buff-menu.elc \
146 $(lispsource)byte-run.elc \
147 $(lispsource)cus-start.el \
148 $(lispsource)custom.elc \
149 $(lispsource)faces.elc \
150 $(lispsource)files.elc \
151 $(lispsource)textmodes/fill.elc \
152 $(lispsource)format.elc \
153 $(FACE_SUPPORT) \
154 $(MOUSE_SUPPORT) \
155 $(FLOAT_SUPPORT) \
156 $(lispsource)frame.elc\
157 $(X_WINDOWS_SUPPORT) \
158 $(lispsource)help.elc \
159 $(lispsource)indent.elc \
160 $(lispsource)isearch.elc \
161 $(lispsource)emacs-lisp/lisp-mode.elc \
162 $(lispsource)emacs-lisp/lisp.elc \
163 $(lispsource)loadup.el \
164 $(lispsource)loaddefs.el \
165 $(lispsource)map-ynp.elc \
166 $(lispsource)menu-bar.elc \
167 $(lispsource)international/mule.elc \
168 $(lispsource)international/mule-conf.el \
169 $(lispsource)international/mule-cmds.elc \
170 $(lispsource)international/characters.elc \
171 $(lispsource)language/chinese.elc \
172 $(lispsource)language/cyrillic.elc \
173 $(lispsource)language/devanagari.elc \
174 $(lispsource)language/english.elc \
175 $(lispsource)language/ethiopic.elc \
176 $(lispsource)language/european.elc \
177 $(lispsource)language/greek.elc \
178 $(lispsource)language/hebrew.elc \
179 $(lispsource)language/indian.elc \
180 $(lispsource)language/japanese.elc \
181 $(lispsource)language/korean.elc \
182 $(lispsource)language/lao.elc \
183 $(lispsource)language/thai.elc \
184 $(lispsource)language/tibetan.elc \
185 $(lispsource)language/vietnamese.elc \
186 $(lispsource)language/misc-lang.elc \
187 $(lispsource)textmodes/page.elc \
188 $(lispsource)textmodes/paragraphs.elc \
189 $(lispsource)paths.el \
190 $(lispsource)register.elc \
191 $(lispsource)replace.elc \
192 $(lispsource)simple.elc \
193 $(lispsource)startup.elc \
194 $(lispsource)subr.elc \
195 $(lispsource)textmodes/text-mode.elc \
196 $(lispsource)vc-hooks.elc \
197 $(lispsource)ediff-hook.elc \
198 $(VMS_SUPPORT) \
199 $(MSDOS_SUPPORT) \
200 $(WINNT_SUPPORT) \
201 $(lispsource)window.elc \
202 $(lispsource)version.el
203
204
205 DOC = DOC
206 $(DOC): $(BLD)\make-docfile.exe
207 - $(DEL) $(DOC)
208 $(BLD)\make-docfile -d ..\src $(obj) > $(DOC)
209 $(BLD)\make-docfile -d ..\src $(lisp) >> $(DOC)
210 $(CP) $(DOC) ..\etc\DOC-X
211 - mkdir ..\src\$(OBJDIR)
212 - mkdir ..\src\$(OBJDIR)\etc
213 $(CP) $(DOC) ..\src\$(OBJDIR)\etc\DOC-X
214
215 {$(BLD)}.obj{$(BLD)}.exe:
216 $(LINK) -out:$@ $(LINK_FLAGS) $*.obj $(LIBS)
217
218 .c{$(BLD)}.obj:
219 $(CC) $(CFLAGS) -Fo$@ $<
220
221 #
222 # Build the executables
223 #
224 all: $(BLD) $(ALL) $(DOC)
225
226 #
227 # Assuming INSTALL_DIR is defined, build and install emacs in it.
228 #
229 INSTALL_FILES = $(ALL)
230 install: $(INSTALL_FILES)
231 - mkdir $(INSTALL_DIR)\bin
232 $(CP) $(BLD)\etags.exe $(INSTALL_DIR)\bin
233 $(CP) $(BLD)\ctags.exe $(INSTALL_DIR)\bin
234 $(CP) $(BLD)\hexl.exe $(INSTALL_DIR)\bin
235 $(CP) $(BLD)\movemail.exe $(INSTALL_DIR)\bin
236 $(CP) $(BLD)\fakemail.exe $(INSTALL_DIR)\bin
237 - mkdir $(INSTALL_DIR)\etc
238 $(CP) $(DOC) $(INSTALL_DIR)\etc
239
240 #
241 # Maintenance
242 #
243 clean:; - $(DEL) *~ *.pdb DOC*
244 - $(DEL_TREE) deleted
245 - $(DEL_TREE) $(OBJDIR)
246
247 #
248 # Headers we would preprocess if we could.
249 #
250 ..\src\config.h: ..\nt\$(CONFIG_H)
251 $(CP) $** $@
252 ..\src\paths.h: ..\nt\paths.h
253 $(CP) $** $@
254
255 ### DEPENDENCIES ###
256
257 EMACS_ROOT = ..
258 SRC = .
259
260 $(BLD)\alloca.obj : \
261 $(SRC)\alloca.c \
262 $(EMACS_ROOT)\src\s\ms-w32.h \
263 $(EMACS_ROOT)\src\m\intel386.h \
264 $(EMACS_ROOT)\src\config.h \
265 $(EMACS_ROOT)\src\blockinput.h
266
267 $(BLD)\b2m.obj : \
268 $(SRC)\b2m.c \
269 $(EMACS_ROOT)\src\s\ms-w32.h \
270 $(EMACS_ROOT)\src\m\intel386.h \
271 $(EMACS_ROOT)\lib-src\..\src\config.h
272
273 $(BLD)\ctags.obj : \
274 $(SRC)\ctags.c \
275 $(EMACS_ROOT)\nt\inc\sys\param.h \
276 $(EMACS_ROOT)\src\s\ms-w32.h \
277 $(EMACS_ROOT)\src\m\intel386.h \
278 $(EMACS_ROOT)\lib-src\..\src\config.h \
279 $(SRC)\ntlib.h \
280 $(SRC)\getopt.h
281
282 $(BLD)\cvtmail.obj : \
283 $(SRC)\cvtmail.c
284
285 $(BLD)\digest-doc.obj : \
286 $(SRC)\digest-doc.c
287
288 $(BLD)\emacsclient.obj : \
289 $(SRC)\emacsclient.c \
290 $(EMACS_ROOT)\src\s\ms-w32.h \
291 $(EMACS_ROOT)\src\m\intel386.h \
292 $(EMACS_ROOT)\lib-src\..\src\config.h
293
294 $(BLD)\emacsserver.obj : \
295 $(SRC)\emacsserver.c \
296 $(EMACS_ROOT)\src\s\ms-w32.h \
297 $(EMACS_ROOT)\src\m\intel386.h \
298 $(EMACS_ROOT)\lib-src\..\src\config.h \
299 $(EMACS_ROOT)\nt\inc\sys\file.h
300
301 $(BLD)\emacstool.obj : \
302 $(SRC)\emacstool.c \
303 $(EMACS_ROOT)\nt\inc\sys\file.h
304
305 $(BLD)\etags.obj : \
306 $(SRC)\etags.c \
307 $(EMACS_ROOT)\nt\inc\sys\param.h \
308 $(EMACS_ROOT)\src\s\ms-w32.h \
309 $(EMACS_ROOT)\src\m\intel386.h \
310 $(EMACS_ROOT)\lib-src\..\src\config.h \
311 $(SRC)\ntlib.h \
312 $(SRC)\getopt.h
313
314 $(BLD)\fakemail.obj : \
315 $(SRC)\fakemail.c \
316 $(SRC)\ntlib.h \
317 $(EMACS_ROOT)\src\s\ms-w32.h \
318 $(EMACS_ROOT)\src\m\intel386.h \
319 $(EMACS_ROOT)\lib-src\..\src\config.h \
320 $(EMACS_ROOT)\nt\inc\pwd.h
321
322 $(BLD)\getdate.obj : \
323 $(SRC)\getdate.c \
324 $(EMACS_ROOT)\src\s\ms-w32.h \
325 $(EMACS_ROOT)\src\m\intel386.h \
326 $(EMACS_ROOT)\src\config.h \
327 $(MSTOOLS_SYS)\types.h
328
329 $(BLD)\getopt.obj : \
330 $(SRC)\getopt.c \
331 $(EMACS_ROOT)\src\s\ms-w32.h \
332 $(EMACS_ROOT)\src\m\intel386.h \
333 $(EMACS_ROOT)\src\config.h \
334 $(SRC)\ntlib.h \
335 $(SRC)\getopt.h
336
337 $(BLD)\getopt1.obj : \
338 $(SRC)\getopt1.c \
339 $(EMACS_ROOT)\src\s\ms-w32.h \
340 $(EMACS_ROOT)\src\m\intel386.h \
341 $(EMACS_ROOT)\src\config.h \
342 $(SRC)\getopt.h
343
344 $(BLD)\hexl.obj : \
345 $(SRC)\hexl.c
346
347 $(BLD)\leditcfns.obj : \
348 $(SRC)\leditcfns.c
349
350 $(BLD)\make-docfile.obj : \
351 $(SRC)\make-docfile.c \
352 $(EMACS_ROOT)\src\config.h
353
354 $(BLD)\make-path.obj : \
355 $(SRC)\make-path.c
356
357 $(BLD)\movemail.obj : \
358 $(SRC)\movemail.c \
359 $(EMACS_ROOT)\src\s\ms-w32.h \
360 $(EMACS_ROOT)\src\m\intel386.h \
361 $(EMACS_ROOT)\lib-src\..\src\config.h \
362 $(EMACS_ROOT)\nt\inc\sys\file.h \
363 $(EMACS_ROOT)\src\vmsproc.h \
364 $(EMACS_ROOT)\lib-src\..\src\syswait.h \
365 $(EMACS_ROOT)\nt\inc\pwd.h \
366 $(SRC)\ntlib.h
367 $(CC) $(CFLAGS) -DUSG -Fo$@ movemail.c
368
369 $(BLD)\ntlib.obj : \
370 $(SRC)\ntlib.c \
371 $(SRC)\ntlib.h \
372 $(EMACS_ROOT)\nt\inc\pwd.h
373
374 $(BLD)\pop.obj : \
375 $(SRC)\pop.c \
376 $(SRC)\pop.h \
377 $(SRC)\ntlib.h
378
379 $(BLD)\profile.obj : \
380 $(SRC)\profile.c \
381 $(EMACS_ROOT)\src\s\ms-w32.h \
382 $(EMACS_ROOT)\src\m\intel386.h \
383 $(EMACS_ROOT)\lib-src\..\src\config.h \
384 $(EMACS_ROOT)\src\vmstime.h \
385 $(EMACS_ROOT)\lib-src\..\src\systime.h
386
387 $(BLD)\qsort.obj : \
388 $(SRC)\qsort.c
389
390 $(BLD)\sorted-doc.obj : \
391 $(SRC)\sorted-doc.c
392
393 $(BLD)\tcp.obj : \
394 $(SRC)\tcp.c
395
396 $(BLD)\test-distrib.obj : \
397 $(SRC)\test-distrib.c
398
399 $(BLD)\timer.obj : \
400 $(SRC)\timer.c \
401 $(EMACS_ROOT)\src\s\ms-w32.h \
402 $(EMACS_ROOT)\src\m\intel386.h \
403 $(EMACS_ROOT)\lib-src\..\src\config.h
404
405 $(BLD)\yow.obj : \
406 $(SRC)\yow.c \
407 $(EMACS_ROOT)\lib-src\..\src\paths.h