OSDN Git Service

3fc7e2cca66b7fc9ffd3ce8c7bbf89153ec70862
[pf3gnuchains/sourceware.git] / tcl / win / makefile.vc
1 # Visual C++ 2.x and 4.0 makefile
2 #
3 # See the file "license.terms" for information on usage and redistribution
4 # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
5
6 # Copyright (c) 1995-1996 Sun Microsystems, Inc.
7 # Copyright (c) 1998-1999 by Scriptics Corporation.
8 #
9 # RCS: @(#) $Id$
10
11 # Does not depend on the presence of any environment variables in
12 # order to compile tcl; all needed information is derived from 
13 # location of the compiler directories.
14
15 #
16 # Project directories
17 #
18 # ROOT    = top of source tree
19 #
20 # TOOLS32 = location of VC++ 32-bit development tools. Note that the
21 #           VC++ 2.0 header files are broken, so you need to use the
22 #           ones that come with the developer network CD's, or later
23 #           versions of VC++.
24 #
25 # INSTALLDIR = where the install- targets should copy the binaries and
26 #           support files
27 #
28
29 # Set this to the appropriate value of /MACHINE: for your platform
30 MACHINE         = IX86
31
32 ROOT            = ..
33 INSTALLDIR      = c:\Progra~1\Tcl
34
35 !IF "$(MACHINE)" == "IA64"
36 TOOLS32         = c:\ia64sdk17
37 TOOLS32_rc      = c:\ia64sdk17
38 !ELSE
39 TOOLS32         = c:\Progra~1\devstudio\vc
40 TOOLS32_rc      = c:\Progra~1\devstudio\sharedide
41 !ENDIF
42
43 # Uncomment the following line to compile with thread support
44 #THREADDEFINES = -DTCL_THREADS=1
45
46 # Set NODEBUG to 0 to compile with symbols
47 NODEBUG = 1
48
49 # The following defines can be used to control the amount of debugging
50 # code that is added to the compilation.
51 #
52 #       -DTCL_MEM_DEBUG         Enables the debugging memory allocator.
53 #       -DTCL_COMPILE_DEBUG     Enables byte compilation logging.
54 #       -DTCL_COMPILE_STATS     Enables byte compilation statistics gathering.
55 #       -DUSE_TCLALLOC=0        Disables the Tcl memory allocator in favor
56 #                               of the native malloc implementation.  This is
57 #                               needed when using Purify.
58 #
59 #DEBUGDEFINES = -DTCL_MEM_DEBUG -DTCL_COMPILE_DEBUG -DTCL_COMPILE_STATS
60 #DEBUGDEFINES = -DUSE_TCLALLOC=0
61
62 ######################################################################
63 # Do not modify below this line
64 ######################################################################
65
66 NAMEPREFIX = tcl
67 STUBPREFIX = $(NAMEPREFIX)stub
68 DOTVERSION = 8.3
69 VERSION = 83
70
71 BINROOT         = .
72 !IF "$(NODEBUG)" == "1"
73 TMPDIRNAME      = Release
74 DBGX            =
75 !ELSE
76 TMPDIRNAME      = Debug
77 DBGX            = d
78 !ENDIF
79 TMPDIR          = $(BINROOT)\$(TMPDIRNAME)
80 OUTDIRNAME      = $(TMPDIRNAME)
81 OUTDIR          = $(TMPDIR)
82
83 TCLLIB          = $(OUTDIR)\$(NAMEPREFIX)$(VERSION)$(DBGX).lib
84 TCLDLLNAME      = $(NAMEPREFIX)$(VERSION)$(DBGX).dll
85 TCLDLL          = $(OUTDIR)\$(TCLDLLNAME)
86
87 TCLSTUBLIBNAME  = $(STUBPREFIX)$(VERSION)$(DBGX).lib
88 TCLSTUBLIB      = $(OUTDIR)\$(TCLSTUBLIBNAME)
89
90 TCLPLUGINLIB    = $(OUTDIR)\$(NAMEPREFIX)$(VERSION)p$(DBGX).lib
91 TCLPLUGINDLLNAME= $(NAMEPREFIX)$(VERSION)p$(DBGX).dll
92 TCLPLUGINDLL    = $(OUTDIR)\$(TCLPLUGINDLLNAME)
93 TCLSH           = $(OUTDIR)\$(NAMEPREFIX)sh$(VERSION)$(DBGX).exe
94 TCLSHP          = $(OUTDIR)\$(NAMEPREFIX)shp$(VERSION)$(DBGX).exe
95 TCLPIPEDLLNAME  = $(NAMEPREFIX)pip$(VERSION)$(DBGX).dll
96 TCLPIPEDLL      = $(OUTDIR)\$(TCLPIPEDLLNAME)
97 TCLREGDLLNAME   = $(NAMEPREFIX)reg$(VERSION)$(DBGX).dll
98 TCLREGDLL       = $(OUTDIR)\$(TCLREGDLLNAME)
99 TCLDDEDLLNAME   = $(NAMEPREFIX)dde$(VERSION)$(DBGX).dll
100 TCLDDEDLL       = $(OUTDIR)\$(TCLDDEDLLNAME)
101 TCLTEST         = $(OUTDIR)\$(NAMEPREFIX)test.exe
102 CAT32           = $(TMPDIR)\cat32.exe
103 RMDIR           = .\rmd.bat
104 MKDIR           = .\mkd.bat
105 RM              = del
106
107 LIB_INSTALL_DIR = $(INSTALLDIR)\lib
108 BIN_INSTALL_DIR = $(INSTALLDIR)\bin
109 SCRIPT_INSTALL_DIR      = $(INSTALLDIR)\lib\tcl$(DOTVERSION)
110 INCLUDE_INSTALL_DIR     = $(INSTALLDIR)\include
111
112 TCLSHOBJS = \
113         $(TMPDIR)\tclAppInit.obj
114
115 TCLTESTOBJS = \
116         $(TMPDIR)\tclTest.obj \
117         $(TMPDIR)\tclTestObj.obj \
118         $(TMPDIR)\tclTestProcBodyObj.obj \
119         $(TMPDIR)\tclThreadTest.obj \
120         $(TMPDIR)\tclWinTest.obj \
121         $(TMPDIR)\testMain.obj
122
123 TCLOBJS = \
124         $(TMPDIR)\regcomp.obj \
125         $(TMPDIR)\regexec.obj \
126         $(TMPDIR)\regfree.obj \
127         $(TMPDIR)\regerror.obj \
128         $(TMPDIR)\strftime.obj \
129         $(TMPDIR)\tclAlloc.obj \
130         $(TMPDIR)\tclAsync.obj \
131         $(TMPDIR)\tclBasic.obj \
132         $(TMPDIR)\tclBinary.obj \
133         $(TMPDIR)\tclCkalloc.obj \
134         $(TMPDIR)\tclClock.obj \
135         $(TMPDIR)\tclCmdAH.obj \
136         $(TMPDIR)\tclCmdIL.obj \
137         $(TMPDIR)\tclCmdMZ.obj \
138         $(TMPDIR)\tclCompCmds.obj \
139         $(TMPDIR)\tclCompExpr.obj \
140         $(TMPDIR)\tclCompile.obj \
141         $(TMPDIR)\tclDate.obj \
142         $(TMPDIR)\tclEncoding.obj \
143         $(TMPDIR)\tclEnv.obj \
144         $(TMPDIR)\tclEvent.obj \
145         $(TMPDIR)\tclExecute.obj \
146         $(TMPDIR)\tclFCmd.obj \
147         $(TMPDIR)\tclFileName.obj \
148         $(TMPDIR)\tclGet.obj \
149         $(TMPDIR)\tclHash.obj \
150         $(TMPDIR)\tclHistory.obj \
151         $(TMPDIR)\tclIndexObj.obj \
152         $(TMPDIR)\tclInterp.obj \
153         $(TMPDIR)\tclIO.obj \
154         $(TMPDIR)\tclIOCmd.obj \
155         $(TMPDIR)\tclIOGT.obj \
156         $(TMPDIR)\tclIOSock.obj \
157         $(TMPDIR)\tclIOUtil.obj \
158         $(TMPDIR)\tclLink.obj \
159         $(TMPDIR)\tclLiteral.obj \
160         $(TMPDIR)\tclListObj.obj \
161         $(TMPDIR)\tclLoad.obj \
162         $(TMPDIR)\tclMain.obj \
163         $(TMPDIR)\tclNamesp.obj \
164         $(TMPDIR)\tclNotify.obj \
165         $(TMPDIR)\tclObj.obj \
166         $(TMPDIR)\tclPanic.obj \
167         $(TMPDIR)\tclParse.obj \
168         $(TMPDIR)\tclParseExpr.obj \
169         $(TMPDIR)\tclPipe.obj \
170         $(TMPDIR)\tclPkg.obj \
171         $(TMPDIR)\tclPosixStr.obj \
172         $(TMPDIR)\tclPreserve.obj \
173         $(TMPDIR)\tclProc.obj \
174         $(TMPDIR)\tclRegexp.obj \
175         $(TMPDIR)\tclResolve.obj \
176         $(TMPDIR)\tclResult.obj \
177         $(TMPDIR)\tclScan.obj \
178         $(TMPDIR)\tclStringObj.obj \
179         $(TMPDIR)\tclStubInit.obj \
180         $(TMPDIR)\tclStubLib.obj \
181         $(TMPDIR)\tclThread.obj \
182         $(TMPDIR)\tclTimer.obj \
183         $(TMPDIR)\tclUtf.obj \
184         $(TMPDIR)\tclUtil.obj \
185         $(TMPDIR)\tclVar.obj \
186         $(TMPDIR)\tclWin32Dll.obj \
187         $(TMPDIR)\tclWinChan.obj \
188         $(TMPDIR)\tclWinConsole.obj \
189         $(TMPDIR)\tclWinSerial.obj \
190         $(TMPDIR)\tclWinError.obj \
191         $(TMPDIR)\tclWinFCmd.obj \
192         $(TMPDIR)\tclWinFile.obj \
193         $(TMPDIR)\tclWinInit.obj \
194         $(TMPDIR)\tclWinLoad.obj \
195         $(TMPDIR)\tclWinMtherr.obj \
196         $(TMPDIR)\tclWinNotify.obj \
197         $(TMPDIR)\tclWinPipe.obj \
198         $(TMPDIR)\tclWinSock.obj \
199         $(TMPDIR)\tclWinThrd.obj \
200         $(TMPDIR)\tclWinTime.obj 
201
202 TCLSTUBOBJS = $(TMPDIR)\tclStubLib.obj \
203
204 cc32            = "$(TOOLS32)\bin\cl.exe"
205 link32          = "$(TOOLS32)\bin\link.exe"
206 rc32            = "$(TOOLS32_rc)\bin\rc.exe"
207 include32       = -I"$(TOOLS32)\include"
208 libpath32       = /LIBPATH:"$(TOOLS32)\lib"
209 lib32           = "$(TOOLS32)\bin\lib.exe"
210
211 WINDIR          = $(ROOT)\win
212 GENERICDIR      = $(ROOT)\generic
213
214 TCL_INCLUDES    = -I"$(WINDIR)" -I"$(GENERICDIR)"
215 TCL_DEFINES     = $(DEBUGDEFINES) $(THREADDEFINES)
216
217 ######################################################################
218 # Compile flags
219 ######################################################################
220
221 !IF "$(NODEBUG)" == "1"
222 # This cranks the optimization level to maximize speed
223 cdebug = -O2 -Gs -GD
224 !ELSE
225 !IF "$(MACHINE)" == "IA64"
226 cdebug = -Od -Zi
227 !ELSE
228 cdebug = -Z7 -Od -WX
229 !ENDIF
230 !ENDIF
231
232 # declarations common to all compiler options
233 cflags = -c -W3 -nologo -Fp$(TMPDIR)\ -YX
234 cvarsdll = -MD$(DBGX)
235
236 TCL_CFLAGS      = $(cdebug) $(cflags) $(cvarsdll) $(include32) \
237                         $(TCL_INCLUDES) $(TCL_DEFINES)
238 CON_CFLAGS      = $(cdebug) $(cflags) $(include32) -DCONSOLE
239
240 ######################################################################
241 # Link flags
242 ######################################################################
243
244 !IF "$(NODEBUG)" == "1"
245 ldebug  = /RELEASE
246 !ELSE
247 ldebug  = -debug:full -debugtype:cv
248 !ENDIF
249
250 # declarations common to all linker options
251 lflags  = /NODEFAULTLIB /NOLOGO /MACHINE:$(MACHINE) $(libpath32)
252
253 # declarations for use on Intel i386, i486, and Pentium systems
254 !IF "$(MACHINE)" == "IX86"
255 DLLENTRY = @12
256 dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll
257 !ELSE
258 !IF "$(MACHINE)" == "IA64"
259 DLLENTRY = @12
260 dlllflags = $(lflags) -dll
261 !ELSE
262 dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll
263 !ENDIF
264 !ENDIF
265
266 conlflags = $(lflags) -subsystem:console -entry:mainCRTStartup
267 guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
268
269 !IF "$(MACHINE)" == "PPC"
270 libc = libc$(DBGX).lib
271 libcdll = crtdll$(DBGX).lib
272 !ELSE
273 libc = libc$(DBGX).lib oldnames.lib
274 libcdll = msvcrt$(DBGX).lib oldnames.lib
275 !ENDIF
276
277 baselibs   = kernel32.lib $(optlibs) advapi32.lib user32.lib
278 winlibs    = $(baselibs) gdi32.lib comdlg32.lib winspool.lib
279
280 guilibs    = $(libc) $(winlibs)
281 conlibs    = $(libc) $(baselibs)
282 guilibsdll = $(libcdll) $(winlibs)
283 conlibsdll = $(libcdll) $(baselibs)
284
285 ######################################################################
286 # Project specific targets
287 ######################################################################
288
289 release:    setup $(TCLSH) dlls
290 dlls:       setup $(TCLPIPEDLL) $(TCLREGDLL) $(TCLDDEDLL)
291 all:        setup $(TCLSH) dlls $(CAT32) 
292 tcltest:    setup $(TCLTEST) dlls $(CAT32)
293 plugin:     setup $(TCLPLUGINDLL) $(TCLSHP)
294 install:    install-binaries install-libraries
295 test:       setup $(TCLTEST) dlls $(CAT32)
296         set TCL_LIBRARY=$(ROOT)/library
297         $(TCLTEST) $(ROOT)/tests/all.tcl
298
299 setup:
300         @$(MKDIR) $(TMPDIR)
301         @$(MKDIR) $(OUTDIR)
302
303 $(TCLLIB): $(TCLDLL)
304
305 $(TCLDLL): $(TCLOBJS) $(TMPDIR)\tcl.res
306         $(link32) $(ldebug) $(dlllflags) \
307                 -out:$@ $(TMPDIR)\tcl.res $(guilibsdll) @<<
308 $(TCLOBJS)
309 <<
310
311 $(TCLSTUBLIB): $(TCLSTUBOBJS)
312         $(lib32) /out:$@ $(TCLSTUBOBJS)
313
314 $(TCLPLUGINLIB): $(TCLPLUGINDLL)
315
316 $(TCLPLUGINDLL): $(TCLOBJS) $(TMPDIR)\tcl.res
317         $(link32) $(ldebug) $(dlllflags) \
318                 -out:$@ $(TMPDIR)\tcl.res $(guilibsdll) @<<
319 $(TCLOBJS)
320 <<
321
322 $(TCLSH): $(TCLSHOBJS) $(TCLLIB) $(TMPDIR)\tclsh.res
323         $(link32) $(ldebug) $(conlflags) $(TMPDIR)\tclsh.res -stack:2300000 \
324                 -out:$@ $(conlibsdll) $(TCLLIB) $(TCLSHOBJS) 
325
326 $(TCLSHP): $(TCLSHOBJS) $(TCLPLUGINLIB) $(TMPDIR)\tclsh.res
327         $(link32) $(ldebug) $(conlflags) $(TMPDIR)\tclsh.res -stack:2300000 \
328                 -out:$@ $(conlibsdll) $(TCLPLUGINLIB) $(TCLSHOBJS) 
329
330 $(TCLTEST): $(TCLTESTOBJS) $(TCLLIB) $(TMPDIR)\tclsh.res
331         $(link32) $(ldebug) $(conlflags) $(TMPDIR)\tclsh.res -stack:2300000 \
332                  -out:$@ $(conlibsdll) $(TCLLIB) $(TCLTESTOBJS)
333
334 $(TCLPIPEDLL): $(WINDIR)\stub16.c
335         $(cc32) $(CON_CFLAGS) -Fo$(TMPDIR)\ $(WINDIR)\stub16.c
336         $(link32) $(ldebug) $(conlflags) -out:$@ $(TMPDIR)\stub16.obj $(guilibs)
337
338 $(TCLDDEDLL): $(TMPDIR)\tclWinDde.obj $(TCLSTUBLIB)
339         $(link32) $(ldebug) $(dlllflags) -out:$@ $(TMPDIR)\tclWinDde.obj \
340                 $(conlibsdll) $(TCLSTUBLIB)
341
342 $(TCLREGDLL): $(TMPDIR)\tclWinReg.obj $(TCLSTUBLIB)
343         $(link32) $(ldebug) $(dlllflags) -out:$@ $(TMPDIR)\tclWinReg.obj \
344                 $(conlibsdll) $(TCLSTUBLIB)
345
346 $(CAT32): $(WINDIR)\cat.c
347         $(cc32) $(CON_CFLAGS) -Fo$(TMPDIR)\ $?
348         $(link32) $(conlflags) -out:$@ -stack:16384 $(TMPDIR)\cat.obj $(conlibs)
349
350 install-binaries: $(TCLSH)
351         $(MKDIR) "$(BIN_INSTALL_DIR)"
352         $(MKDIR) "$(LIB_INSTALL_DIR)"
353         @echo installing $(TCLDLLNAME)
354         @copy "$(TCLDLL)" "$(BIN_INSTALL_DIR)"
355         @copy "$(TCLLIB)" "$(LIB_INSTALL_DIR)"
356         @echo installing "$(TCLSH)"
357         @copy "$(TCLSH)" "$(BIN_INSTALL_DIR)"
358         @echo installing $(TCLPIPEDLLNAME)
359         @copy "$(TCLPIPEDLL)" "$(BIN_INSTALL_DIR)"
360         @echo installing $(TCLSTUBLIBNAME)
361         @copy "$(TCLSTUBLIB)" "$(LIB_INSTALL_DIR)"
362
363 install-libraries:
364         -@$(MKDIR) "$(LIB_INSTALL_DIR)"
365         -@$(MKDIR) "$(INCLUDE_INSTALL_DIR)"
366         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)"
367         @echo installing http1.0
368         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\http1.0"
369         -@copy "$(ROOT)\library\http1.0\http.tcl"     "$(SCRIPT_INSTALL_DIR)\http1.0"
370         -@copy "$(ROOT)\library\http1.0\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\http1.0"
371         @echo installing http2.3
372         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\http2.3"
373         -@copy "$(ROOT)\library\http2.3\http.tcl"     "$(SCRIPT_INSTALL_DIR)\http2.3"
374         -@copy "$(ROOT)\library\http2.3\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\http2.3"
375         @echo installing opt0.4
376         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\opt0.4"
377         -@copy "$(ROOT)\library\opt0.4\optparse.tcl" "$(SCRIPT_INSTALL_DIR)\opt0.4"
378         -@copy "$(ROOT)\library\opt0.4\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\opt0.4"
379         @echo installing msgcat1.0
380         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\msgcat1.0"
381         -@copy "$(ROOT)\library\msgcat1.0\msgcat.tcl"   "$(SCRIPT_INSTALL_DIR)\msgcat1.0"
382         -@copy "$(ROOT)\library\msgcat1.0\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\msgcat1.0"
383         @echo installing $(TCLDDEDLLNAME)
384         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\dde1.1"
385         -@copy "$(TCLDDEDLL)" "$(SCRIPT_INSTALL_DIR)\dde1.1"
386         -@copy "$(ROOT)\library\dde1.1\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\dde1.1"
387         @echo installing $(TCLREGDLLNAME)
388         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\reg1.0"
389         -@copy "$(TCLREGDLL)" "$(SCRIPT_INSTALL_DIR)\reg1.0"
390         -@copy "$(ROOT)\library\reg1.0\pkgIndex.tcl" "$(SCRIPT_INSTALL_DIR)\reg1.0"
391         @echo installing encoding files
392         -@$(MKDIR) "$(SCRIPT_INSTALL_DIR)\encoding"
393         -@copy "$(ROOT)\library\encoding\*.enc" "$(SCRIPT_INSTALL_DIR)\encoding"
394         @echo installing library files
395         -@copy "$(GENERICDIR)\tcl.h"         "$(INCLUDE_INSTALL_DIR)"
396         -@copy "$(GENERICDIR)\tclDecls.h"    "$(INCLUDE_INSTALL_DIR)"
397         -@copy "$(ROOT)\library\history.tcl" "$(SCRIPT_INSTALL_DIR)"
398         -@copy "$(ROOT)\library\init.tcl"    "$(SCRIPT_INSTALL_DIR)"
399         -@copy "$(ROOT)\library\ldAout.tcl"  "$(SCRIPT_INSTALL_DIR)"
400         -@copy "$(ROOT)\library\parray.tcl"  "$(SCRIPT_INSTALL_DIR)"
401         -@copy "$(ROOT)\library\safe.tcl"    "$(SCRIPT_INSTALL_DIR)"
402         -@copy "$(ROOT)\library\tclIndex"    "$(SCRIPT_INSTALL_DIR)"
403         -@copy "$(ROOT)\library\package.tcl" "$(SCRIPT_INSTALL_DIR)"
404         -@copy "$(ROOT)\library\word.tcl"    "$(SCRIPT_INSTALL_DIR)"
405         -@copy "$(ROOT)\library\auto.tcl"    "$(SCRIPT_INSTALL_DIR)"
406
407 #
408 # Regenerate the stubs files.
409 #
410
411 genstubs:
412         tclsh$(VERSION) $(ROOT)\tools\genStubs.tcl $(GENERICDIR) \
413                 $(GENERICDIR)\tcl.decls $(GENERICDIR)\tclInt.decls
414
415 #
416 # Regenerate the windows help files.
417 #
418
419 TCLTOOLS        = $(ROOT)/tools
420 MAN2TCL         = $(TCLTOOLS)/man2tcl
421 TCLRTF          = $(TCLTOOLS)/tcl.rtf
422 TCLHPJ          = $(TCLTOOLS)/tcl.hpj
423 MAN2HELP        = $(TCLTOOLS)/man2help.tcl
424 HCRTF           = $(TOOLS32)/bin/hcrtf.exe
425
426 winhelp: $(TCLRTF)
427         cd $(TCLTOOLS)
428         start /wait $(HCRTF) -xn $(TCLHPJ)
429
430 $(MAN2TCL).exe: $(MAN2TCL).obj 
431         cd $(TCLTOOLS)
432         $(cc32) /nologo /G4 /ML /O2 $(MAN2TCL).c
433
434 $(TCLRTF): $(MAN2TCL).exe $(TCLSH)
435         cd $(TCLTOOLS)
436         ..\win\$(TCLSH) $(MAN2HELP) $(NAMEPREFIX) $(VERSION) $(ROOT)/doc ../../tk$(DOTVERSION)/doc
437
438 #
439 # Special case object file targets
440 #
441
442 $(TMPDIR)\tclWinInit.obj: $(WINDIR)\tclWinInit.c
443         $(cc32) -DBUILD_tcl $(TCL_CFLAGS) $(EXTFLAGS) -Fo$(TMPDIR)\ $?
444
445 $(TMPDIR)\testMain.obj: $(WINDIR)\tclAppInit.c
446         $(cc32) $(TCL_CFLAGS) -DTCL_TEST -Fo$(TMPDIR)\testMain.obj $?
447
448 $(TMPDIR)\tclTest.obj: $(GENERICDIR)\tclTest.c
449         $(cc32) $(TCL_CFLAGS) -Fo$@ $?
450
451 $(TMPDIR)\tclTestObj.obj: $(GENERICDIR)\tclTestObj.c
452         $(cc32) $(TCL_CFLAGS) -Fo$@ $?
453
454 $(TMPDIR)\tclWinTest.obj: $(WINDIR)\tclWinTest.c
455         $(cc32) $(TCL_CFLAGS) -Fo$@ $?
456
457 $(TMPDIR)\tclAppInit.obj : $(WINDIR)\tclAppInit.c
458         $(cc32) $(TCL_CFLAGS) -Fo$@ $?
459
460 # The following objects should be built using the stub interfaces
461
462 $(TMPDIR)\tclWinReg.obj : $(WINDIR)\tclWinReg.c
463         $(cc32) $(TCL_CFLAGS) -DUSE_TCL_STUBS -Fo$@ $?
464
465 $(TMPDIR)\tclWinDde.obj : $(WINDIR)\tclWinDde.c
466         $(cc32) $(TCL_CFLAGS) -DUSE_TCL_STUBS -Fo$@ $?
467
468 # The following objects are part of the stub library and should not
469 # be built as DLL objects but none of the symbols should be exported
470
471 $(TMPDIR)\tclStubLib.obj : $(GENERICDIR)\tclStubLib.c
472         $(cc32) $(TCL_CFLAGS) -DSTATIC_BUILD -Fo$@ $?
473
474
475 # Dedependency rules
476
477 $(GENERICDIR)\regcomp.c: \
478         $(GENERICDIR)\regguts.h \
479         $(GENERICDIR)\regc_lex.c \
480         $(GENERICDIR)\regc_color.c \
481         $(GENERICDIR)\regc_nfa.c \
482         $(GENERICDIR)\regc_cvec.c \
483         $(GENERICDIR)\regc_locale.c
484 $(GENERICDIR)\regcustom.h: \
485         $(GENERICDIR)\tclInt.h \
486         $(GENERICDIR)\tclPort.h \
487         $(GENERICDIR)\regex.h
488 $(GENERICDIR)\regexec.c: \
489         $(GENERICDIR)\rege_dfa.c \
490         $(GENERICDIR)\regguts.h
491 $(GENERICDIR)\regerror.c: $(GENERICDIR)\regguts.h
492 $(GENERICDIR)\regfree.c: $(GENERICDIR)\regguts.h
493 $(GENERICDIR)\regfronts.c: $(GENERICDIR)\regguts.h
494 $(GENERICDIR)\regguts.h: $(GENERICDIR)\regcustom.h
495
496 #
497 # Implicit rules
498 #
499
500 {$(WINDIR)}.c{$(TMPDIR)}.obj:
501     $(cc32) -DBUILD_tcl $(TCL_CFLAGS) -Fo$(TMPDIR)\ $<
502
503 {$(GENERICDIR)}.c{$(TMPDIR)}.obj:
504     $(cc32) -DBUILD_tcl $(TCL_CFLAGS) -Fo$(TMPDIR)\ $<
505
506 {$(ROOT)\compat}.c{$(TMPDIR)}.obj:
507     $(cc32) -DBUILD_tcl $(TCL_CFLAGS) -Fo$(TMPDIR)\ $<
508
509 {$(WINDIR)}.rc{$(TMPDIR)}.res:
510         $(rc32) -fo $@ -r -i $(GENERICDIR) -i $(WINDIR) -D__WIN32__ \
511                 $(TCL_DEFINES) $<
512
513 clean:
514         -@$(RM) $(OUTDIR)\*.exp 
515         -@$(RM) $(OUTDIR)\*.lib 
516         -@$(RM) $(OUTDIR)\*.dll 
517         -@$(RM) $(OUTDIR)\*.exe
518         -@$(RM) $(OUTDIR)\*.pdb
519         -@$(RM) $(TMPDIR)\*.pch
520         -@$(RM) $(TMPDIR)\*.obj
521         -@$(RM) $(TMPDIR)\*.res
522         -@$(RM) $(TMPDIR)\*.exe
523         -@$(RMDIR) $(OUTDIR)
524         -@$(RMDIR) $(TMPDIR)
525
526
527