OpenCores
URL https://opencores.org/ocsvn/or1k_old/or1k_old/trunk

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [insight/] [tk/] [win/] [makefile.vc] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 578 markom
# 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
# SCCS: @(#) makefile.vc 1.12 98/08/12 18:41:59
8
 
9
# Does not depend on the presence of any environment variables in
10
# order to compile tcl; all needed information is derived from
11
# location of the compiler directories.
12
 
13
#
14
# Project directories
15
#
16
# ROOT    = top of source tree
17
#
18
# TMPDIR  = location where .obj files should be stored during build
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
# TCLDIR = location of top of Tcl source heirarchy
26
#
27
 
28
ROOT            = ..
29
TOOLS32         = c:\progra~1\devstudio\vc
30
TOOLS32_rc      = c:\progra~1\devstudio\sharedide
31
TCLDIR          = ..\..\tcl8.0
32
 
33
# Set this to the appropriate value of /MACHINE: for your platform
34
MACHINE = IX86
35
 
36
# Set NODEBUG to 0 to compile with symbols
37
NODEBUG = 1
38
 
39
# uncomment the following two lines to compile with TCL_MEM_DEBUG
40
#DEBUGDEFINES   =-DTCL_MEM_DEBUG
41
 
42
######################################################################
43
# Do not modify below this line
44
######################################################################
45
 
46
TCLNAMEPREFIX = tcl
47
TKNAMEPREFIX = tk
48
WISHNAMEPREFIX = wish
49
VERSION = 80
50
 
51
BINROOT         = .
52
!IF "$(NODEBUG)" == "1"
53
TMPDIRNAME      = Release
54
DBGX            =
55
!ELSE
56
TMPDIRNAME      = Debug
57
DBGX            = d
58
!ENDIF
59
TMPDIR          = $(BINROOT)\$(TMPDIRNAME)
60
OUTDIRNAME      = $(TMPDIRNAME)
61
OUTDIR          = $(TMPDIR)
62
 
63
TCLLIB          = $(TCLNAMEPREFIX)$(VERSION)$(DBGX).lib
64
TCLPLUGINLIB    = $(TCLNAMEPREFIX)$(VERSION)p.lib
65
TKDLLNAME       = $(TKNAMEPREFIX)$(VERSION)$(DBGX).dll
66
TKDLL           = $(OUTDIR)\$(TKDLLNAME)
67
TKLIB           = $(OUTDIR)\$(TKNAMEPREFIX)$(VERSION)$(DBGX).lib
68
TKPLUGINDLLNAME = $(TKNAMEPREFIX)$(VERSION)p$(DBG).dll
69
TKPLUGINDLL     = $(OUTDIR)\$(TKPLUGINDLLNAME)
70
TKPLUGINLIB     = $(OUTDIR)\$(TKNAMEPREFIX)$(VERSION)p$(DBGX).lib
71
 
72
WISH            = $(OUTDIR)\$(WISHNAMEPREFIX)$(VERSION)$(DBGX).exe
73
WISHP           = $(OUTDIR)\$(WISHNAMEPREFIX)p$(VERSION)$(DBGX).exe
74
TKTEST          = $(OUTDIR)\$(TKNAMEPREFIX)test.exe
75
DUMPEXTS        = $(TMPDIR)\dumpexts.exe
76
 
77
WISHOBJS = \
78
        $(TMPDIR)\winMain.obj
79
 
80
TKTESTOBJS = \
81
        $(TMPDIR)\tkTest.obj \
82
        $(TMPDIR)\tkSquare.obj \
83
        $(TMPDIR)\testMain.obj
84
 
85
XLIBOBJS = \
86
        $(TMPDIR)\xcolors.obj \
87
        $(TMPDIR)\xdraw.obj \
88
        $(TMPDIR)\xgc.obj \
89
        $(TMPDIR)\ximage.obj \
90
        $(TMPDIR)\xutil.obj
91
 
92
TKOBJS = \
93
        $(TMPDIR)\tkConsole.obj \
94
        $(TMPDIR)\tkUnixMenubu.obj \
95
        $(TMPDIR)\tkUnixScale.obj \
96
        $(XLIBOBJS) \
97
        $(TMPDIR)\tkWin3d.obj \
98
        $(TMPDIR)\tkWin32Dll.obj \
99
        $(TMPDIR)\tkWinButton.obj \
100
        $(TMPDIR)\tkWinClipboard.obj \
101
        $(TMPDIR)\tkWinColor.obj \
102
        $(TMPDIR)\tkWinCursor.obj \
103
        $(TMPDIR)\tkWinDialog.obj \
104
        $(TMPDIR)\tkWinDraw.obj \
105
        $(TMPDIR)\tkWinEmbed.obj \
106
        $(TMPDIR)\tkWinFont.obj \
107
        $(TMPDIR)\tkWinImage.obj \
108
        $(TMPDIR)\tkWinInit.obj \
109
        $(TMPDIR)\tkWinKey.obj \
110
        $(TMPDIR)\tkWinMenu.obj \
111
        $(TMPDIR)\tkWinPixmap.obj \
112
        $(TMPDIR)\tkWinPointer.obj \
113
        $(TMPDIR)\tkWinRegion.obj \
114
        $(TMPDIR)\tkWinScrlbr.obj \
115
        $(TMPDIR)\tkWinSend.obj \
116
        $(TMPDIR)\tkWinWindow.obj \
117
        $(TMPDIR)\tkWinWm.obj \
118
        $(TMPDIR)\tkWinX.obj \
119
        $(TMPDIR)\stubs.obj \
120
        $(TMPDIR)\tk3d.obj \
121
        $(TMPDIR)\tkArgv.obj \
122
        $(TMPDIR)\tkAtom.obj \
123
        $(TMPDIR)\tkBind.obj \
124
        $(TMPDIR)\tkBitmap.obj \
125
        $(TMPDIR)\tkButton.obj \
126
        $(TMPDIR)\tkCanvArc.obj \
127
        $(TMPDIR)\tkCanvBmap.obj \
128
        $(TMPDIR)\tkCanvImg.obj \
129
        $(TMPDIR)\tkCanvLine.obj \
130
        $(TMPDIR)\tkCanvPoly.obj \
131
        $(TMPDIR)\tkCanvPs.obj \
132
        $(TMPDIR)\tkCanvText.obj \
133
        $(TMPDIR)\tkCanvUtil.obj \
134
        $(TMPDIR)\tkCanvWind.obj \
135
        $(TMPDIR)\tkCanvas.obj \
136
        $(TMPDIR)\tkClipboard.obj \
137
        $(TMPDIR)\tkCmds.obj \
138
        $(TMPDIR)\tkColor.obj \
139
        $(TMPDIR)\tkConfig.obj \
140
        $(TMPDIR)\tkCursor.obj \
141
        $(TMPDIR)\tkEntry.obj \
142
        $(TMPDIR)\tkError.obj \
143
        $(TMPDIR)\tkEvent.obj \
144
        $(TMPDIR)\tkFileFilter.obj \
145
        $(TMPDIR)\tkFocus.obj \
146
        $(TMPDIR)\tkFont.obj \
147
        $(TMPDIR)\tkFrame.obj \
148
        $(TMPDIR)\tkGC.obj \
149
        $(TMPDIR)\tkGeometry.obj \
150
        $(TMPDIR)\tkGet.obj \
151
        $(TMPDIR)\tkGrab.obj \
152
        $(TMPDIR)\tkGrid.obj \
153
        $(TMPDIR)\tkImage.obj \
154
        $(TMPDIR)\tkImgBmap.obj \
155
        $(TMPDIR)\tkImgGIF.obj \
156
        $(TMPDIR)\tkImgPPM.obj \
157
        $(TMPDIR)\tkImgPhoto.obj \
158
        $(TMPDIR)\tkImgUtil.obj \
159
        $(TMPDIR)\tkListbox.obj \
160
        $(TMPDIR)\tkMacWinMenu.obj \
161
        $(TMPDIR)\tkMain.obj \
162
        $(TMPDIR)\tkMenu.obj \
163
        $(TMPDIR)\tkMenubutton.obj \
164
        $(TMPDIR)\tkMenuDraw.obj \
165
        $(TMPDIR)\tkMessage.obj \
166
        $(TMPDIR)\tkOption.obj \
167
        $(TMPDIR)\tkPack.obj \
168
        $(TMPDIR)\tkPlace.obj \
169
        $(TMPDIR)\tkPointer.obj \
170
        $(TMPDIR)\tkRectOval.obj \
171
        $(TMPDIR)\tkScale.obj \
172
        $(TMPDIR)\tkScrollbar.obj \
173
        $(TMPDIR)\tkSelect.obj \
174
        $(TMPDIR)\tkText.obj \
175
        $(TMPDIR)\tkTextBTree.obj \
176
        $(TMPDIR)\tkTextDisp.obj \
177
        $(TMPDIR)\tkTextImage.obj \
178
        $(TMPDIR)\tkTextIndex.obj \
179
        $(TMPDIR)\tkTextMark.obj \
180
        $(TMPDIR)\tkTextTag.obj \
181
        $(TMPDIR)\tkTextWind.obj \
182
        $(TMPDIR)\tkTrig.obj \
183
        $(TMPDIR)\tkUtil.obj \
184
        $(TMPDIR)\tkVisual.obj \
185
        $(TMPDIR)\tkWindow.obj
186
 
187
cc32            = $(TOOLS32)\bin\cl.exe
188
link32          = $(TOOLS32)\bin\link.exe
189
rc32            = $(TOOLS32_rc)\bin\rc.exe
190
include32       = -I$(TOOLS32)\include
191
 
192
WINDIR          = $(ROOT)\win
193
GENERICDIR      = $(ROOT)\generic
194
XLIBDIR         = $(ROOT)\xlib
195
BITMAPDIR       = $(ROOT)\bitmaps
196
TCLLIBDIR       = $(TCLDIR)\win\$(OUTDIRNAME)
197
RCDIR           = $(WINDIR)\rc
198
 
199
TK_INCLUDES     = -I$(WINDIR) -I$(GENERICDIR) -I$(BITMAPDIR) -I$(XLIBDIR) \
200
                        -I$(TCLDIR)\generic
201
TK_DEFINES      = $(DEBUGDEFINES)
202
 
203
TK_CFLAGS       = $(cdebug) $(cflags) $(cvarsdll) $(include32) \
204
                        $(TK_INCLUDES) $(TK_DEFINES)
205
 
206
######################################################################
207
# Link flags
208
######################################################################
209
 
210
!IF "$(NODEBUG)" == "1"
211
ldebug = /RELEASE
212
!ELSE
213
ldebug = -debug:full -debugtype:cv
214
!ENDIF
215
 
216
# declarations common to all linker options
217
lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
218
 
219
# declarations for use on Intel i386, i486, and Pentium systems
220
!IF "$(MACHINE)" == "IX86"
221
DLLENTRY = @12
222
lflags   = $(lcommon) -align:0x1000 /MACHINE:$(MACHINE)
223
!ELSE
224
lflags   = $(lcommon) /MACHINE:$(MACHINE)
225
!ENDIF
226
 
227
conlflags = $(lflags) -subsystem:console -entry:mainCRTStartup
228
guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
229
dlllflags = $(lflags) -entry:_DllMainCRTStartup$(DLLENTRY) -dll
230
 
231
!IF "$(MACHINE)" == "PPC"
232
libc = libc.lib
233
libcdll = crtdll.lib
234
!ELSE
235
libc = libc.lib oldnames.lib
236
libcdll = msvcrt.lib oldnames.lib
237
!ENDIF
238
 
239
baselibs   = kernel32.lib $(optlibs) advapi32.lib
240
winlibs    = $(baselibs) user32.lib gdi32.lib comdlg32.lib winspool.lib
241
guilibs    = $(libc) $(winlibs)
242
 
243
guilibsdll = $(libcdll) $(winlibs)
244
 
245
######################################################################
246
# Compile flags
247
######################################################################
248
 
249
!IF "$(NODEBUG)" == "1"
250
!IF "$(MACHINE)" == "ALPHA"
251
# MSVC on Alpha doesn't understand -Ot
252
cdebug = -O2i -Gs -GD
253
!ELSE
254
cdebug = -Oti -Gs -GD
255
!ENDIF
256
!ELSE
257
cdebug = -Z7 -Od -WX
258
!ENDIF
259
 
260
# declarations common to all compiler options
261
ccommon = -c -W3 -nologo -Fp$(TMPDIR)\ -YX
262
 
263
!IF "$(MACHINE)" == "IX86"
264
cflags = $(ccommon) -D_X86_=1
265
!ELSE
266
!IF "$(MACHINE)" == "MIPS"
267
cflags = $(ccommon) -D_MIPS_=1
268
!ELSE
269
!IF "$(MACHINE)" == "PPC"
270
cflags = $(ccommon) -D_PPC_=1
271
!ELSE
272
!IF "$(MACHINE)" == "ALPHA"
273
cflags = $(ccommon) -D_ALPHA_=1
274
!ENDIF
275
!ENDIF
276
!ENDIF
277
!ENDIF
278
 
279
cvars      = -DWIN32 -D_WIN32
280
cvarsmt    = $(cvars) -D_MT
281
cvarsdll   = $(cvarsmt) -D_DLL
282
 
283
!IF "$(NODEBUG)" == "1"
284
cvarsdll   = $(cvars) -MD
285
!ELSE
286
cvarsdll   = $(cvars) -MDd
287
!ENDIF
288
 
289
CON_CFLAGS      = $(cdebug) $(cflags) $(cvars) $(include32) -DCONSOLE
290
 
291
######################################################################
292
# Project specific targets
293
######################################################################
294
 
295
all:    setup $(WISH)
296
test:   setup $(TKTEST)
297
plugin: setup $(TKPLUGINDLL) $(WISHP)
298
 
299
setup:
300
        @mkd $(TMPDIR)
301
        @mkd $(OUTDIR)
302
 
303
$(TKLIB): $(TKDLL)
304
 
305
$(TKDLL): $(TKOBJS) $(TMPDIR)\tk.res $(TMPDIR)\tk.def
306
        set LIB=$(TOOLS32)\lib
307
       $(link32) $(ldebug) $(dlllflags) -def:$(TMPDIR)\tk.def \
308
                -out:$@ $(TMPDIR)\tk.res $(TCLLIBDIR)\$(TCLLIB) \
309
                $(guilibsdll) @<<
310
                        $(TKOBJS)
311
<<
312
 
313
$(TKPLUGINLIB): $(TKPLUGINDLL)
314
 
315
$(TKPLUGINDLL): $(TKOBJS) $(TMPDIR)\tk.res $(TMPDIR)\plugin.def
316
        set LIB=$(TOOLS32)\lib
317
        $(link32) $(ldebug) $(dlllflags) -def:$(TMPDIR)\plugin.def \
318
                -out:$@ $(TMPDIR)\tk.res $(TCLLIBDIR)\$(TCLPLUGINLIB) \
319
                $(guilibsdll) @<<
320
                        $(TKOBJS)
321
<<
322
 
323
$(WISH): $(WISHOBJS) $(TKLIB) $(TMPDIR)\wish.res
324
        set LIB=$(TOOLS32)\lib
325
        $(link32) $(ldebug) $(guilflags) $(TMPDIR)\wish.res -out:$@ \
326
                $(guilibsdll) $(TCLLIBDIR)\$(TCLLIB) $(TKLIB) $(WISHOBJS)
327
 
328
$(WISHP): $(WISHOBJS) $(TKPLUGINLIB) $(TMPDIR)\wish.res
329
        set LIB=$(TOOLS32)\lib
330
        $(link32) $(ldebug) $(guilflags) $(TMPDIR)\wish.res -out:$@ \
331
                $(guilibsdll) $(TCLLIBDIR)\$(TCLPLUGINLIB) \
332
                $(TKPLUGINLIB) $(WISHOBJS)
333
 
334
$(TKTEST): $(TKTESTOBJS) $(TKLIB) $(TMPDIR)\wish.res
335
        set LIB=$(TOOLS32)\lib
336
        $(link32) $(ldebug) $(guilflags) $(TMPDIR)\wish.res -out:$@ \
337
                $(guilibsdll) $(TCLLIBDIR)\$(TCLLIB) $(TKLIB) $(TKTESTOBJS)
338
 
339
$(TMPDIR)\tk.def: $(DUMPEXTS) $(TKOBJS)
340
        $(DUMPEXTS) -o $@ $(TKDLLNAME) @<<
341
                $(TKOBJS)
342
<<
343
 
344
$(TMPDIR)\plugin.def: $(DUMPEXTS) $(TKOBJS)
345
        $(DUMPEXTS) -o $@ $(TKPLUGINDLLNAME) @<<
346
                $(TKOBJS)
347
<<
348
 
349
$(DUMPEXTS): $(TCLDIR)\win\winDumpExts.c
350
        $(cc32) $(CON_CFLAGS) -Fo$(TMPDIR)\ $?
351
        set LIB=$(TOOLS32)\lib
352
        $(link32) $(ldebug) $(conlflags) $(guilibs) -out:$@ \
353
                $(TMPDIR)\winDumpExts.obj
354
 
355
#
356
# Special case object file targets
357
#
358
 
359
$(TMPDIR)\testMain.obj: $(ROOT)\win\winMain.c
360
        $(cc32) $(TK_CFLAGS) -DSTATIC_BUILD -DTK_TEST -Fo$@ $?
361
 
362
$(TMPDIR)\tkTest.obj: $(ROOT)\generic\tkTest.c
363
        $(cc32) $(TK_CFLAGS) -DSTATIC_BUILD -Fo$@ $?
364
 
365
$(TMPDIR)\tkSquare.obj: $(ROOT)\generic\tkSquare.c
366
        $(cc32) $(TK_CFLAGS) -Fo$@ $?
367
 
368
$(TMPDIR)\winMain.obj: $(ROOT)\win\winMain.c
369
        $(cc32) $(TK_CFLAGS) -DSTATIC_BUILD -Fo$@ $?
370
 
371
#
372
# Implicit rules
373
#
374
 
375
{$(XLIBDIR)}.c{$(TMPDIR)}.obj:
376
        $(cc32) -DDLL_BUILD -DBUILD_tk $(TK_CFLAGS) -Fo$(TMPDIR)\ $<
377
 
378
{$(GENERICDIR)}.c{$(TMPDIR)}.obj:
379
        $(cc32) -DDLL_BUILD -DBUILD_tk $(TK_CFLAGS) -Fo$(TMPDIR)\ $<
380
 
381
{$(WINDIR)}.c{$(TMPDIR)}.obj:
382
        $(cc32) -DDLL_BUILD -DBUILD_tk $(TK_CFLAGS) -Fo$(TMPDIR)\ $<
383
 
384
{$(ROOT)\unix}.c{$(TMPDIR)}.obj:
385
        $(cc32) -DDLL_BUILD -DBUILD_tk $(TK_CFLAGS) -Fo$(TMPDIR)\ $<
386
 
387
{$(RCDIR)}.rc{$(TMPDIR)}.res:
388
        $(rc32) -fo $@ -r -i $(GENERICDIR) $<
389
 
390
clean:
391
        -@del $(OUTDIR)\*.exp
392
        -@del $(OUTDIR)\*.lib
393
        -@del $(OUTDIR)\*.dll
394
        -@del $(OUTDIR)\*.exe
395
        -@del $(OUTDIR)\*.pdb
396
        -@del $(TMPDIR)\*.pch
397
        -@del $(TMPDIR)\*.obj
398
        -@del $(TMPDIR)\*.res
399
        -@del $(TMPDIR)\*.def
400
        -@del $(TMPDIR)\*.exe
401
        -@rmd $(OUTDIR)
402
        -@rmd $(TMPDIR)
403
 
404
# dependencies
405
 
406
$(TMPDIR)\tk.res: \
407
    $(RCDIR)\buttons.bmp \
408
    $(RCDIR)\cursor*.cur \
409
    $(RCDIR)\tk.ico
410
 
411
$(GENERICDIR)/default.h: $(WINDIR)/tkWinDefault.h
412
$(GENERICDIR)/tkButton.c: $(GENERICDIR)/default.h
413
$(GENERICDIR)/tkCanvas.c: $(GENERICDIR)/default.h
414
$(GENERICDIR)/tkEntry.c: $(GENERICDIR)/default.h
415
$(GENERICDIR)/tkFrame.c: $(GENERICDIR)/default.h
416
$(GENERICDIR)/tkListbox.c: $(GENERICDIR)/default.h
417
$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/default.h
418
$(GENERICDIR)/tkMenubutton.c: $(GENERICDIR)/default.h
419
$(GENERICDIR)/tkMessage.c: $(GENERICDIR)/default.h
420
$(GENERICDIR)/tkScale.c: $(GENERICDIR)/default.h
421
$(GENERICDIR)/tkScrollbar.c: $(GENERICDIR)/default.h
422
$(GENERICDIR)/tkText.c: $(GENERICDIR)/default.h
423
$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/default.h
424
$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/default.h
425
 
426
$(GENERICDIR)/tkText.c: $(GENERICDIR)/tkText.h
427
$(GENERICDIR)/tkTextBTree.c: $(GENERICDIR)/tkText.h
428
$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
429
$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
430
$(GENERICDIR)/tkTextImage.c: $(GENERICDIR)/tkText.h
431
$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/tkText.h
432
$(GENERICDIR)/tkTextMark.c: $(GENERICDIR)/tkText.h
433
$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/tkText.h
434
$(GENERICDIR)/tkTextWind.c: $(GENERICDIR)/tkText.h
435
 
436
$(GENERICDIR)/tkMacWinMenu.c: $(GENERICDIR)/tkMenu.h
437
$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/tkMenu.h
438
$(GENERICDIR)/tkMenuDraw.c: $(GENERICDIR)/tkMenu.h
439
$(WINDIR)/tkWinMenu.c: $(GENERICDIR)/tkMenu.h
440
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.