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.63 97/08/13 13:33:32
|
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 |
|
|
# This file is CYGNUS LOCAL. It is a copy of makefile.vc from the
|
14 |
|
|
# standard tk distribution, modified to work with cygwin and an
|
15 |
|
|
# autoconf configure script. I have chosen to minimize the number of
|
16 |
|
|
# changes, so the comments continue to refer to Visual C++ and the
|
17 |
|
|
# like. This should make it easier to merge in a new version if that
|
18 |
|
|
# is necessary.
|
19 |
|
|
|
20 |
|
|
prefix = @prefix@
|
21 |
|
|
exec_prefix = @exec_prefix@
|
22 |
|
|
srcdir = @srcdir@
|
23 |
|
|
VPATH = $(srcdir):$(srcdir)/../xlib:$(srcdir)/../generic:$(srcdir)/../unix:$(srcdir)/../win/rc
|
24 |
|
|
libdir=@libdir@
|
25 |
|
|
bindir=@bindir@
|
26 |
|
|
includedir=@includedir@
|
27 |
|
|
mandir=@mandir@
|
28 |
|
|
datadir=@datadir@
|
29 |
|
|
host_alias=@host_alias@
|
30 |
|
|
|
31 |
|
|
INSTALL = @INSTALL@
|
32 |
|
|
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
33 |
|
|
INSTALL_DATA = @INSTALL_DATA@
|
34 |
|
|
|
35 |
|
|
CC = @CC@
|
36 |
|
|
CFLAGS = @CFLAGS@
|
37 |
|
|
NM = @NM@
|
38 |
|
|
AS = @AS@
|
39 |
|
|
LD = @LD@
|
40 |
|
|
DLLTOOL = @DLLTOOL@
|
41 |
|
|
WINDRES = @WINDRES@
|
42 |
|
|
|
43 |
|
|
OBJEXT=@OBJEXT@
|
44 |
|
|
|
45 |
|
|
DLL_LDFLAGS = @DLL_LDFLAGS@
|
46 |
|
|
DLL_LDLIBS = @DLL_LDLIBS@
|
47 |
|
|
|
48 |
|
|
# Current Tk version; used in various names.
|
49 |
|
|
|
50 |
|
|
DIRVERSION = @TK_VERSION@
|
51 |
|
|
|
52 |
|
|
# The following definition can be set to non-null for special systems
|
53 |
|
|
# like AFS with replication. It allows the pathnames used for installation
|
54 |
|
|
# to be different than those used for actually reference files at
|
55 |
|
|
# run-time. INSTALL_ROOT is prepended to $prefix and $exec_prefix
|
56 |
|
|
# when installing files.
|
57 |
|
|
INSTALL_ROOT =
|
58 |
|
|
|
59 |
|
|
# Directory from which applications will reference the library of Tcl
|
60 |
|
|
# scripts (note: you can set the TK_LIBRARY environment variable at
|
61 |
|
|
# run-time to override the compiled-in location):
|
62 |
|
|
TK_LIBRARY = $(datadir)/tk$(DIRVERSION)
|
63 |
|
|
|
64 |
|
|
# Path name to use when installing library scripts:
|
65 |
|
|
SCRIPT_INSTALL_DIR = $(INSTALL_ROOT)$(TK_LIBRARY)
|
66 |
|
|
|
67 |
|
|
# Directory in which to install the .a or .so binary for the Tk library:
|
68 |
|
|
LIB_INSTALL_DIR = $(INSTALL_ROOT)$(libdir)
|
69 |
|
|
|
70 |
|
|
# Directory in which to install the program wish:
|
71 |
|
|
BIN_INSTALL_DIR = $(INSTALL_ROOT)$(bindir)
|
72 |
|
|
|
73 |
|
|
# Directory in which to install the include file tk.h:
|
74 |
|
|
INCLUDE_INSTALL_DIR = $(INSTALL_ROOT)$(includedir)
|
75 |
|
|
|
76 |
|
|
# Directory in which to install the X11 header files. These files are
|
77 |
|
|
# not machine independent, so they should not go in includedir.
|
78 |
|
|
X11_INCLUDE_INSTALL_DIR = $(INSTALL_ROOT)$(includedir)/X11
|
79 |
|
|
|
80 |
|
|
DEMOPROGS = browse hello ixset rmt rolodex square tcolor timer widget
|
81 |
|
|
|
82 |
|
|
#
|
83 |
|
|
# Project directories
|
84 |
|
|
#
|
85 |
|
|
# ROOT = top of source tree
|
86 |
|
|
#
|
87 |
|
|
# TMPDIR = location where .obj files should be stored during build
|
88 |
|
|
#
|
89 |
|
|
# TOOLS32 = location of VC++ 32-bit development tools. Note that the
|
90 |
|
|
# VC++ 2.0 header files are broken, so you need to use the
|
91 |
|
|
# ones that come with the developer network CD's, or later
|
92 |
|
|
# versions of VC++.
|
93 |
|
|
#
|
94 |
|
|
# TCLDIR = location of top of Tcl source heirarchy
|
95 |
|
|
#
|
96 |
|
|
|
97 |
|
|
ROOT = $(srcdir)/..
|
98 |
|
|
TMPDIR = .
|
99 |
|
|
TOOLS32 = c:\msdev
|
100 |
|
|
TCLDIR = $(srcdir)/../../tcl
|
101 |
|
|
|
102 |
|
|
# Set this to the appropriate value of /MACHINE: for your platform
|
103 |
|
|
MACHINE = IX86
|
104 |
|
|
|
105 |
|
|
# Comment the following line to compile with symbols
|
106 |
|
|
NODEBUG=1
|
107 |
|
|
|
108 |
|
|
# uncomment the following two lines to compile with TCL_MEM_DEBUG
|
109 |
|
|
#DEBUGDEFINES =-DTCL_MEM_DEBUG
|
110 |
|
|
|
111 |
|
|
######################################################################
|
112 |
|
|
# Do not modify below this line
|
113 |
|
|
######################################################################
|
114 |
|
|
|
115 |
|
|
VERSION = 80
|
116 |
|
|
|
117 |
|
|
TCLDLL = cygtcl$(VERSION).dll
|
118 |
|
|
TCLLIB = libtcl$(VERSION).a
|
119 |
|
|
TCLPLUGINDLL = cygtcl$(VERSION)p.dll
|
120 |
|
|
TCLPLUGINLIB = libtcl$(VERSION)p.a
|
121 |
|
|
TKDLL = cygtk$(VERSION).dll
|
122 |
|
|
TKLIB = libtk$(VERSION).a
|
123 |
|
|
TKPLUGINDLL = cygtk$(VERSION)p.dll
|
124 |
|
|
TKPLUGINLIB = libtk$(VERSION)p.a
|
125 |
|
|
|
126 |
|
|
WISH = cygwish$(VERSION).exe
|
127 |
|
|
WISHP = cygwishp$(VERSION).exe
|
128 |
|
|
TKTEST = tktest.exe
|
129 |
|
|
DUMPEXTS = $(TMPDIR)/dumpexts.exe
|
130 |
|
|
|
131 |
|
|
WISHOBJS = \
|
132 |
|
|
$(TMPDIR)/tkConsole.$(OBJEXT) \
|
133 |
|
|
$(TMPDIR)/winMain.$(OBJEXT)
|
134 |
|
|
|
135 |
|
|
TKTESTOBJS = \
|
136 |
|
|
$(TMPDIR)/tkConsole.$(OBJEXT) \
|
137 |
|
|
$(TMPDIR)/tkTest.$(OBJEXT) \
|
138 |
|
|
$(TMPDIR)/tkSquare.$(OBJEXT) \
|
139 |
|
|
$(TMPDIR)/testMain.$(OBJEXT)
|
140 |
|
|
|
141 |
|
|
XLIBOBJS = \
|
142 |
|
|
$(TMPDIR)/xcolors.$(OBJEXT) \
|
143 |
|
|
$(TMPDIR)/xdraw.$(OBJEXT) \
|
144 |
|
|
$(TMPDIR)/xgc.$(OBJEXT) \
|
145 |
|
|
$(TMPDIR)/ximage.$(OBJEXT) \
|
146 |
|
|
$(TMPDIR)/xutil.$(OBJEXT)
|
147 |
|
|
|
148 |
|
|
TKOBJS = \
|
149 |
|
|
$(TMPDIR)/tkUnixMenubu.$(OBJEXT) \
|
150 |
|
|
$(TMPDIR)/tkUnixScale.$(OBJEXT) \
|
151 |
|
|
$(XLIBOBJS) \
|
152 |
|
|
$(TMPDIR)/tkWin3d.$(OBJEXT) \
|
153 |
|
|
$(TMPDIR)/tkWin32Dll.$(OBJEXT) \
|
154 |
|
|
$(TMPDIR)/tkWinButton.$(OBJEXT) \
|
155 |
|
|
$(TMPDIR)/tkWinClipboard.$(OBJEXT) \
|
156 |
|
|
$(TMPDIR)/tkWinColor.$(OBJEXT) \
|
157 |
|
|
$(TMPDIR)/tkWinCursor.$(OBJEXT) \
|
158 |
|
|
$(TMPDIR)/tkWinDialog.$(OBJEXT) \
|
159 |
|
|
$(TMPDIR)/tkWinDraw.$(OBJEXT) \
|
160 |
|
|
$(TMPDIR)/tkWinEmbed.$(OBJEXT) \
|
161 |
|
|
$(TMPDIR)/tkWinFont.$(OBJEXT) \
|
162 |
|
|
$(TMPDIR)/tkWinImage.$(OBJEXT) \
|
163 |
|
|
$(TMPDIR)/tkWinInit.$(OBJEXT) \
|
164 |
|
|
$(TMPDIR)/tkWinKey.$(OBJEXT) \
|
165 |
|
|
$(TMPDIR)/tkWinMenu.$(OBJEXT) \
|
166 |
|
|
$(TMPDIR)/tkWinPixmap.$(OBJEXT) \
|
167 |
|
|
$(TMPDIR)/tkWinPointer.$(OBJEXT) \
|
168 |
|
|
$(TMPDIR)/tkWinRegion.$(OBJEXT) \
|
169 |
|
|
$(TMPDIR)/tkWinScrlbr.$(OBJEXT) \
|
170 |
|
|
$(TMPDIR)/tkWinSend.$(OBJEXT) \
|
171 |
|
|
$(TMPDIR)/tkWinWindow.$(OBJEXT) \
|
172 |
|
|
$(TMPDIR)/tkWinWm.$(OBJEXT) \
|
173 |
|
|
$(TMPDIR)/tkWinX.$(OBJEXT) \
|
174 |
|
|
$(TMPDIR)/stubs.$(OBJEXT) \
|
175 |
|
|
$(TMPDIR)/tk3d.$(OBJEXT) \
|
176 |
|
|
$(TMPDIR)/tkArgv.$(OBJEXT) \
|
177 |
|
|
$(TMPDIR)/tkAtom.$(OBJEXT) \
|
178 |
|
|
$(TMPDIR)/tkBind.$(OBJEXT) \
|
179 |
|
|
$(TMPDIR)/tkBitmap.$(OBJEXT) \
|
180 |
|
|
$(TMPDIR)/tkButton.$(OBJEXT) \
|
181 |
|
|
$(TMPDIR)/tkCanvArc.$(OBJEXT) \
|
182 |
|
|
$(TMPDIR)/tkCanvBmap.$(OBJEXT) \
|
183 |
|
|
$(TMPDIR)/tkCanvImg.$(OBJEXT) \
|
184 |
|
|
$(TMPDIR)/tkCanvLine.$(OBJEXT) \
|
185 |
|
|
$(TMPDIR)/tkCanvPoly.$(OBJEXT) \
|
186 |
|
|
$(TMPDIR)/tkCanvPs.$(OBJEXT) \
|
187 |
|
|
$(TMPDIR)/tkCanvText.$(OBJEXT) \
|
188 |
|
|
$(TMPDIR)/tkCanvUtil.$(OBJEXT) \
|
189 |
|
|
$(TMPDIR)/tkCanvWind.$(OBJEXT) \
|
190 |
|
|
$(TMPDIR)/tkCanvas.$(OBJEXT) \
|
191 |
|
|
$(TMPDIR)/tkClipboard.$(OBJEXT) \
|
192 |
|
|
$(TMPDIR)/tkCmds.$(OBJEXT) \
|
193 |
|
|
$(TMPDIR)/tkColor.$(OBJEXT) \
|
194 |
|
|
$(TMPDIR)/tkConfig.$(OBJEXT) \
|
195 |
|
|
$(TMPDIR)/tkCursor.$(OBJEXT) \
|
196 |
|
|
$(TMPDIR)/tkEntry.$(OBJEXT) \
|
197 |
|
|
$(TMPDIR)/tkError.$(OBJEXT) \
|
198 |
|
|
$(TMPDIR)/tkEvent.$(OBJEXT) \
|
199 |
|
|
$(TMPDIR)/tkFileFilter.$(OBJEXT) \
|
200 |
|
|
$(TMPDIR)/tkFocus.$(OBJEXT) \
|
201 |
|
|
$(TMPDIR)/tkFont.$(OBJEXT) \
|
202 |
|
|
$(TMPDIR)/tkFrame.$(OBJEXT) \
|
203 |
|
|
$(TMPDIR)/tkGC.$(OBJEXT) \
|
204 |
|
|
$(TMPDIR)/tkGeometry.$(OBJEXT) \
|
205 |
|
|
$(TMPDIR)/tkGet.$(OBJEXT) \
|
206 |
|
|
$(TMPDIR)/tkGrab.$(OBJEXT) \
|
207 |
|
|
$(TMPDIR)/tkGrid.$(OBJEXT) \
|
208 |
|
|
$(TMPDIR)/tkImage.$(OBJEXT) \
|
209 |
|
|
$(TMPDIR)/tkImgBmap.$(OBJEXT) \
|
210 |
|
|
$(TMPDIR)/tkImgGIF.$(OBJEXT) \
|
211 |
|
|
$(TMPDIR)/tkImgPPM.$(OBJEXT) \
|
212 |
|
|
$(TMPDIR)/tkImgPhoto.$(OBJEXT) \
|
213 |
|
|
$(TMPDIR)/tkImgUtil.$(OBJEXT) \
|
214 |
|
|
$(TMPDIR)/tkListbox.$(OBJEXT) \
|
215 |
|
|
$(TMPDIR)/tkMacWinMenu.$(OBJEXT) \
|
216 |
|
|
$(TMPDIR)/tkMain.$(OBJEXT) \
|
217 |
|
|
$(TMPDIR)/tkMenu.$(OBJEXT) \
|
218 |
|
|
$(TMPDIR)/tkMenubutton.$(OBJEXT) \
|
219 |
|
|
$(TMPDIR)/tkMenuDraw.$(OBJEXT) \
|
220 |
|
|
$(TMPDIR)/tkMessage.$(OBJEXT) \
|
221 |
|
|
$(TMPDIR)/tkOption.$(OBJEXT) \
|
222 |
|
|
$(TMPDIR)/tkPack.$(OBJEXT) \
|
223 |
|
|
$(TMPDIR)/tkPlace.$(OBJEXT) \
|
224 |
|
|
$(TMPDIR)/tkPointer.$(OBJEXT) \
|
225 |
|
|
$(TMPDIR)/tkRectOval.$(OBJEXT) \
|
226 |
|
|
$(TMPDIR)/tkScale.$(OBJEXT) \
|
227 |
|
|
$(TMPDIR)/tkScrollbar.$(OBJEXT) \
|
228 |
|
|
$(TMPDIR)/tkSelect.$(OBJEXT) \
|
229 |
|
|
$(TMPDIR)/tkText.$(OBJEXT) \
|
230 |
|
|
$(TMPDIR)/tkTextBTree.$(OBJEXT) \
|
231 |
|
|
$(TMPDIR)/tkTextDisp.$(OBJEXT) \
|
232 |
|
|
$(TMPDIR)/tkTextImage.$(OBJEXT) \
|
233 |
|
|
$(TMPDIR)/tkTextIndex.$(OBJEXT) \
|
234 |
|
|
$(TMPDIR)/tkTextMark.$(OBJEXT) \
|
235 |
|
|
$(TMPDIR)/tkTextTag.$(OBJEXT) \
|
236 |
|
|
$(TMPDIR)/tkTextWind.$(OBJEXT) \
|
237 |
|
|
$(TMPDIR)/tkTrig.$(OBJEXT) \
|
238 |
|
|
$(TMPDIR)/tkUtil.$(OBJEXT) \
|
239 |
|
|
$(TMPDIR)/tkVisual.$(OBJEXT) \
|
240 |
|
|
$(TMPDIR)/tkWindow.$(OBJEXT)
|
241 |
|
|
|
242 |
|
|
cc32 = $(TOOLS32)\bin\cl.exe
|
243 |
|
|
link32 = $(TOOLS32)\bin\link.exe
|
244 |
|
|
rc32 = $(TOOLS32)\bin\rc.exe
|
245 |
|
|
include32 = -I$(TOOLS32)\include
|
246 |
|
|
|
247 |
|
|
WINDIR = $(ROOT)/win
|
248 |
|
|
GENERICDIR = $(ROOT)/generic
|
249 |
|
|
XLIBDIR = $(ROOT)/xlib
|
250 |
|
|
BITMAPDIR = $(ROOT)/bitmaps
|
251 |
|
|
TCLLIBDIR = ../../tcl/win
|
252 |
|
|
RCDIR = $(WINDIR)/rc
|
253 |
|
|
|
254 |
|
|
TK_INCLUDES = -I$(WINDIR) -I$(GENERICDIR) -I$(BITMAPDIR) -I$(XLIBDIR) \
|
255 |
|
|
-I$(TCLDIR)/generic
|
256 |
|
|
TK_DEFINES = $(DEBUGDEFINES)
|
257 |
|
|
|
258 |
|
|
TK_CFLAGS = $(cdebug) $(cflags) $(cvarsdll) \
|
259 |
|
|
$(TK_INCLUDES) $(TK_DEFINES) $(CFLAGS)
|
260 |
|
|
|
261 |
|
|
######################################################################
|
262 |
|
|
# Link flags
|
263 |
|
|
######################################################################
|
264 |
|
|
|
265 |
|
|
#!IFDEF NODEBUG
|
266 |
|
|
#ldebug = /RELEASE
|
267 |
|
|
#!ELSE
|
268 |
|
|
#ldebug = -debug:full -debugtype:cv
|
269 |
|
|
#!ENDIF
|
270 |
|
|
|
271 |
|
|
# declarations common to all linker options
|
272 |
|
|
# lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
|
273 |
|
|
|
274 |
|
|
# declarations for use on Intel i386, i486, and Pentium systems
|
275 |
|
|
#!IF "$(MACHINE)" == "IX86"
|
276 |
|
|
#DLLENTRY = @12
|
277 |
|
|
#lflags = $(lcommon) -align:0x1000 /MACHINE:$(MACHINE)
|
278 |
|
|
#!ELSE
|
279 |
|
|
#lflags = $(lcommon) /MACHINE:$(MACHINE)
|
280 |
|
|
#!ENDIF
|
281 |
|
|
|
282 |
|
|
ifeq ($(OBJEXT),obj)
|
283 |
|
|
|
284 |
|
|
lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
|
285 |
|
|
lflags = $(lcommon) -align:0x1000 /MACHINE:$(MACHINE)
|
286 |
|
|
conlflags = $(lflags) -subsystem:console -entry:mainCRTStartup
|
287 |
|
|
guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
|
288 |
|
|
dlllflags = $(lflags) -entry:_DllMainCRTStartup@12 -dll
|
289 |
|
|
|
290 |
|
|
else
|
291 |
|
|
|
292 |
|
|
conlflags = $(lflags) -Wl,--subsystem,console -mwindows
|
293 |
|
|
guilflags = $(lflags) -mwindows
|
294 |
|
|
dlllflags = $(lflags)
|
295 |
|
|
|
296 |
|
|
endif
|
297 |
|
|
|
298 |
|
|
#!IF "$(MACHINE)" == "PPC"
|
299 |
|
|
#libc = libc.lib
|
300 |
|
|
#libcdll = crtdll.lib
|
301 |
|
|
#!ELSE
|
302 |
|
|
#libc = libc.lib oldnames.lib
|
303 |
|
|
#libcdll = msvcrt.lib oldnames.lib
|
304 |
|
|
#!ENDIF
|
305 |
|
|
|
306 |
|
|
ifeq ($(OBJEXT),o)
|
307 |
|
|
|
308 |
|
|
baselibs = -lkernel32 $(optlibs) -ladvapi32
|
309 |
|
|
winlibs = $(baselibs) -luser32 -lgdi32 -lcomdlg32 -lwinspool
|
310 |
|
|
|
311 |
|
|
else
|
312 |
|
|
|
313 |
|
|
baselibs = kernel32.lib $(optlibs) advapi32.lib
|
314 |
|
|
winlibs = $(baselibs) user32.lib gdi32.lib comdlg32.lib winspool.lib
|
315 |
|
|
libcdll = msvcrt.lib oldnames.lib
|
316 |
|
|
|
317 |
|
|
endif
|
318 |
|
|
|
319 |
|
|
guilibs = $(libc) $(winlibs)
|
320 |
|
|
|
321 |
|
|
guilibsdll = $(libcdll) $(winlibs)
|
322 |
|
|
|
323 |
|
|
######################################################################
|
324 |
|
|
# Compile flags
|
325 |
|
|
######################################################################
|
326 |
|
|
|
327 |
|
|
#!IFDEF NODEBUG
|
328 |
|
|
#cdebug = -Ox
|
329 |
|
|
#!ELSE
|
330 |
|
|
#cdebug = -Z7 -Od -WX
|
331 |
|
|
#!ENDIF
|
332 |
|
|
|
333 |
|
|
# declarations common to all compiler options
|
334 |
|
|
#ccommon = -c -W3 -nologo -YX
|
335 |
|
|
|
336 |
|
|
#!IF "$(MACHINE)" == "IX86"
|
337 |
|
|
#cflags = $(ccommon) -D_X86_=1
|
338 |
|
|
#!ELSE
|
339 |
|
|
#!IF "$(MACHINE)" == "MIPS"
|
340 |
|
|
#cflags = $(ccommon) -D_MIPS_=1
|
341 |
|
|
#!ELSE
|
342 |
|
|
#!IF "$(MACHINE)" == "PPC"
|
343 |
|
|
#cflags = $(ccommon) -D_PPC_=1
|
344 |
|
|
#!ELSE
|
345 |
|
|
#!IF "$(MACHINE)" == "ALPHA"
|
346 |
|
|
#cflags = $(ccommon) -D_ALPHA_=1
|
347 |
|
|
#!ENDIF
|
348 |
|
|
#!ENDIF
|
349 |
|
|
#!ENDIF
|
350 |
|
|
#!ENDIF
|
351 |
|
|
|
352 |
|
|
cvars = -DWIN32 -D_WIN32
|
353 |
|
|
cvarsmt = $(cvars) -D_MT
|
354 |
|
|
cvarsdll = $(cvarsmt) -D_DLL
|
355 |
|
|
|
356 |
|
|
CON_CFLAGS = $(cdebug) $(cflags) $(cvars) $(include32) -DCONSOLE
|
357 |
|
|
|
358 |
|
|
######################################################################
|
359 |
|
|
# Project specific targets
|
360 |
|
|
######################################################################
|
361 |
|
|
|
362 |
|
|
all: $(TKDLL) $(TKLIB) $(WISH)
|
363 |
|
|
test: $(TKTEST)
|
364 |
|
|
plugin: $(TKPLUGINDLL) $(WISHP)
|
365 |
|
|
|
366 |
|
|
install: install-binaries install-libraries install-demos
|
367 |
|
|
|
368 |
|
|
install-binaries: $(TKDLL) $(TKLIB) $(WISH)
|
369 |
|
|
@for i in $(LIB_INSTALL_DIR) $(BIN_INSTALL_DIR) ; \
|
370 |
|
|
do \
|
371 |
|
|
if [ ! -d $$i ] ; then \
|
372 |
|
|
echo "Making directory $$i"; \
|
373 |
|
|
mkdir $$i; \
|
374 |
|
|
chmod 755 $$i; \
|
375 |
|
|
else true; \
|
376 |
|
|
fi; \
|
377 |
|
|
done;
|
378 |
|
|
@echo "Installing $(TKLIB)"
|
379 |
|
|
@$(INSTALL_DATA) $(TKLIB) $(LIB_INSTALL_DIR)/$(TKLIB)
|
380 |
|
|
@chmod 555 $(LIB_INSTALL_DIR)/$(TKLIB)
|
381 |
|
|
@echo "Installing wish"
|
382 |
|
|
@$(INSTALL_PROGRAM) $(WISH) $(BIN_INSTALL_DIR)/$(WISH)
|
383 |
|
|
@echo "Installing tkConfig.sh"
|
384 |
|
|
@$(INSTALL_DATA) ../unix/tkConfig.sh $(LIB_INSTALL_DIR)/tkConfig.sh
|
385 |
|
|
|
386 |
|
|
install-libraries:
|
387 |
|
|
@echo "Installing DLL"
|
388 |
|
|
@$(INSTALL_DATA) $(TKDLL) $(BIN_INSTALL_DIR)/$(TKDLL)
|
389 |
|
|
@for i in $(INSTALL_ROOT)@datadir@ $(INCLUDE_INSTALL_DIR) \
|
390 |
|
|
$(SCRIPT_INSTALL_DIR) $(INSTALL_ROOT)@exec_prefix@ \
|
391 |
|
|
$(INSTALL_ROOT)@exec_prefix@/@host_alias@ \
|
392 |
|
|
$(INSTALL_ROOT)@exec_prefix@/@host_alias@/include \
|
393 |
|
|
$(X11_INCLUDE_INSTALL_DIR) ; \
|
394 |
|
|
do \
|
395 |
|
|
if [ ! -d $$i ] ; then \
|
396 |
|
|
echo "Making directory $$i"; \
|
397 |
|
|
mkdir $$i; \
|
398 |
|
|
chmod 755 $$i; \
|
399 |
|
|
else true; \
|
400 |
|
|
fi; \
|
401 |
|
|
done;
|
402 |
|
|
@echo "Installing tk.h"
|
403 |
|
|
@$(INSTALL_DATA) $(GENERICDIR)/tk.h $(INCLUDE_INSTALL_DIR)/tk.h
|
404 |
|
|
for i in $(XLIBDIR)/X11/*.h; \
|
405 |
|
|
do \
|
406 |
|
|
echo "Installing $$i"; \
|
407 |
|
|
$(INSTALL_DATA) $$i $(X11_INCLUDE_INSTALL_DIR); \
|
408 |
|
|
done;
|
409 |
|
|
for i in $(ROOT)/library/*.tcl $(ROOT)/library/tclIndex $(ROOT)/library/prolog.ps $(ROOT)/unix/tkAppInit.c; \
|
410 |
|
|
do \
|
411 |
|
|
echo "Installing $$i"; \
|
412 |
|
|
$(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR); \
|
413 |
|
|
done;
|
414 |
|
|
|
415 |
|
|
install-minimal:
|
416 |
|
|
@echo "Installing DLL"
|
417 |
|
|
@$(INSTALL_DATA) $(TKDLL) $(BIN_INSTALL_DIR)/$(TKDLL)
|
418 |
|
|
@for i in $(INSTALL_ROOT)@datadir@ $(SCRIPT_INSTALL_DIR) ; \
|
419 |
|
|
do \
|
420 |
|
|
if [ ! -d $$i ] ; then \
|
421 |
|
|
echo "Making directory $$i"; \
|
422 |
|
|
mkdir $$i; \
|
423 |
|
|
chmod 755 $$i; \
|
424 |
|
|
else true; \
|
425 |
|
|
fi; \
|
426 |
|
|
done;
|
427 |
|
|
for i in $(ROOT)/library/*.tcl $(ROOT)/library/tclIndex $(ROOT)/library/prolog.ps; \
|
428 |
|
|
do \
|
429 |
|
|
echo "Installing $$i"; \
|
430 |
|
|
$(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR); \
|
431 |
|
|
done;
|
432 |
|
|
|
433 |
|
|
install-demos:
|
434 |
|
|
@for i in $(INSTALL_ROOT)@datadir@ $(SCRIPT_INSTALL_DIR) \
|
435 |
|
|
$(SCRIPT_INSTALL_DIR)/demos \
|
436 |
|
|
$(SCRIPT_INSTALL_DIR)/demos/images ; \
|
437 |
|
|
do \
|
438 |
|
|
if [ ! -d $$i ] ; then \
|
439 |
|
|
echo "Making directory $$i"; \
|
440 |
|
|
mkdir $$i; \
|
441 |
|
|
chmod 755 $$i; \
|
442 |
|
|
else true; \
|
443 |
|
|
fi; \
|
444 |
|
|
done;
|
445 |
|
|
@for i in $(ROOT)/library/demos/*; \
|
446 |
|
|
do \
|
447 |
|
|
if [ -f $$i ] ; then \
|
448 |
|
|
echo "Installing $$i"; \
|
449 |
|
|
sed -e '3 s|exec wish|exec $(WISH)|' \
|
450 |
|
|
$$i > $(SCRIPT_INSTALL_DIR)/demos/`basename $$i`; \
|
451 |
|
|
fi; \
|
452 |
|
|
done;
|
453 |
|
|
@for i in $(DEMOPROGS); \
|
454 |
|
|
do \
|
455 |
|
|
chmod 755 $(SCRIPT_INSTALL_DIR)/demos/$$i; \
|
456 |
|
|
done;
|
457 |
|
|
@for i in $(ROOT)/library/demos/images/*; \
|
458 |
|
|
do \
|
459 |
|
|
if [ -f $$i ] ; then \
|
460 |
|
|
echo "Installing $$i"; \
|
461 |
|
|
$(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR)/demos/images; \
|
462 |
|
|
fi; \
|
463 |
|
|
done;
|
464 |
|
|
|
465 |
|
|
ifeq ($(OBJEXT),o)
|
466 |
|
|
|
467 |
|
|
$(TKDLL): $(TKOBJS) tkres.$(OBJEXT) tkcyg.def
|
468 |
|
|
$(CC) -s $(DLL_LDFLAGS) -Wl,--base-file,tk.base -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
|
469 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --base-file tk.base --output-exp tk.exp
|
470 |
|
|
$(CC) -s $(DLL_LDFLAGS) -Wl,--base-file,tk.base tk.exp -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
|
471 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --base-file tk.base --output-exp tk.exp
|
472 |
|
|
$(CC) $(DLL_LDFLAGS) tk.exp -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
|
473 |
|
|
|
474 |
|
|
else
|
475 |
|
|
|
476 |
|
|
$(TKDLL): $(TKOBJS) tkres.$(OBJEXT) tkcyg.def
|
477 |
|
|
link $(ldebug) $(dlllflags) -def:tkcyg.def \
|
478 |
|
|
-out:$@ tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) \
|
479 |
|
|
$(guilibsdll) $(TKOBJS)
|
480 |
|
|
mv cygtk80.lib libtk80.a
|
481 |
|
|
endif
|
482 |
|
|
|
483 |
|
|
ifeq ($(OBJEXT),o)
|
484 |
|
|
|
485 |
|
|
$(TKLIB): $(TMPDIR)/tkcyg.def
|
486 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --output-lib $(TKLIB)
|
487 |
|
|
|
488 |
|
|
else
|
489 |
|
|
|
490 |
|
|
$(TKLIB): $(TKDLL)
|
491 |
|
|
|
492 |
|
|
endif
|
493 |
|
|
|
494 |
|
|
$(TKPLUGINLIB): $(TMPDIR)/plugin.def
|
495 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --output-lib $(TKPLUGINLIB)
|
496 |
|
|
|
497 |
|
|
$(TKPLUGINDLL): $(TKOBJS) tkres.$(OBJEXT) $(TMPDIR)/plugin.def
|
498 |
|
|
$(CC) $(DLL_LDFLAGS) -Wl,--base-file,tkplugin.base -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
|
499 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --base-file tkplugin.base --output-exp tk.exp
|
500 |
|
|
$(CC) $(DLL_LDFLAGS) -Wl,--base-file,tkplugin.base tk.exp -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
|
501 |
|
|
$(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --base-file tkplugin.base --output-exp tk.exp
|
502 |
|
|
$(CC) $(DLL_LDFLAGS) tk.exp -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
|
503 |
|
|
|
504 |
|
|
ifeq ($(OBJEXT),o)
|
505 |
|
|
|
506 |
|
|
$(WISH): $(WISHOBJS) wishres.$(OBJEXT) $(TKLIB)
|
507 |
|
|
$(CC) $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -o $@ \
|
508 |
|
|
$(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
|
509 |
|
|
|
510 |
|
|
else
|
511 |
|
|
|
512 |
|
|
$(WISH): $(WISHOBJS) wishres.$(OBJEXT) $(TKLIB)
|
513 |
|
|
link $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -OUT:$@ \
|
514 |
|
|
$(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
|
515 |
|
|
endif
|
516 |
|
|
|
517 |
|
|
$(WISHP): $(WISHOBJS) $(TKPLUGINLIB) wishres.$(OBJEXT)
|
518 |
|
|
$(CC) $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -o $@ \
|
519 |
|
|
$(TKPLUGINLIB) $(TCLLIBDIR)/$(TCLPLUGINLIB) $(guilibsdll)
|
520 |
|
|
|
521 |
|
|
$(TKTEST): $(TKTESTOBJS) wishres.$(OBJEXT) $(TKLIB)
|
522 |
|
|
$(CC) $(ldebug) $(guilflags) $(TKTESTOBJS) wishres.$(OBJEXT) -o $@ \
|
523 |
|
|
$(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
|
524 |
|
|
|
525 |
|
|
ifeq ($(OBJEXT),o)
|
526 |
|
|
tkcyg.def: $(TKOBJS)
|
527 |
|
|
echo 'EXPORTS' > tmp.def
|
528 |
|
|
for o in $(TKOBJS); do \
|
529 |
|
|
$(NM) --extern-only --defined-only $$o | sed -e 's/[^ ]* [^ ]* //' -e 's/^_//' | fgrep -v DllEntryPoint | fgrep -v DllMain | fgrep -v impure_ptr >> tmp.def; \
|
530 |
|
|
done
|
531 |
|
|
mv tmp.def $(TMPDIR)/tkcyg.def
|
532 |
|
|
|
533 |
|
|
plugin.def: $(TKOBJS)
|
534 |
|
|
echo 'EXPORTS' > tmp.def
|
535 |
|
|
for o in $(TKOBJS); do \
|
536 |
|
|
$(NM) --extern-only --defined-only $$o | sed -e 's/[^ ]* [^ ]* //' -e 's/^_//' | fgrep -v DllEntryPoint | fgrep -v DllMain | fgrep -v impure_ptr >> tmp.def; \
|
537 |
|
|
done
|
538 |
|
|
mv tmp.def $(TMPDIR)/plugin.def
|
539 |
|
|
|
540 |
|
|
else
|
541 |
|
|
|
542 |
|
|
# Source-Navigator need the extra Symbols.
|
543 |
|
|
|
544 |
|
|
tkcyg.def: $(TKOBJS) $(DUMPEXTS)
|
545 |
|
|
$(DUMPEXTS) -o tkcyg.def $(TKDLL) $(TKOBJS)
|
546 |
|
|
echo " tkWindowType" >> tkcyg.def
|
547 |
|
|
echo " tkArcType" >> tkcyg.def
|
548 |
|
|
echo " tkBitmapType" >> tkcyg.def
|
549 |
|
|
echo " tkOvalType" >> tkcyg.def
|
550 |
|
|
echo " tkImageType" >> tkcyg.def
|
551 |
|
|
echo " tkPolygonType" >> tkcyg.def
|
552 |
|
|
echo " tkLineType" >> tkcyg.def
|
553 |
|
|
echo " tkTextType" >> tkcyg.def
|
554 |
|
|
echo " tkRectangleType" >> tkcyg.def
|
555 |
|
|
echo " tkTextCharType" >> tkcyg.def
|
556 |
|
|
|
557 |
|
|
plugin.def: $(TKOBJS) $(DUMPEXTS)
|
558 |
|
|
$(DUMPEXTS) -o tkcyg.def $(TKDLL) $(TKOBJS)
|
559 |
|
|
|
560 |
|
|
|
561 |
|
|
$(DUMPEXTS): $(TCLDIR)/win/winDumpExts.c
|
562 |
|
|
$(CC) $(TCLDIR)/win/winDumpExts.c user32.lib -link -OUT:$(DUMPEXTS)
|
563 |
|
|
|
564 |
|
|
endif
|
565 |
|
|
|
566 |
|
|
#$(DUMPEXTS): $(TCLDIR)\win\winDumpExts.c
|
567 |
|
|
# $(cc32) $(CON_CFLAGS) -Fo$(TMPDIR)\ $?
|
568 |
|
|
# set LIB=$(TOOLS32)\lib
|
569 |
|
|
# $(link32) $(ldebug) $(conlflags) $(guilibs) -out:$@ \
|
570 |
|
|
# $(TMPDIR)\winDumpExts.$(OBJEXT)bj
|
571 |
|
|
|
572 |
|
|
#
|
573 |
|
|
# Special case object file targets
|
574 |
|
|
#
|
575 |
|
|
|
576 |
|
|
$(TMPDIR)/testMain.$(OBJEXT): $(ROOT)/win/winMain.c
|
577 |
|
|
$(CC) -c $(TK_CFLAGS) -DTK_TEST -o $@ $?
|
578 |
|
|
|
579 |
|
|
#
|
580 |
|
|
# Implicit rules
|
581 |
|
|
#
|
582 |
|
|
.SUFFIXES: .S .c .o .obj .s
|
583 |
|
|
.c.$(OBJEXT):
|
584 |
|
|
$(CC) -c $(TK_CFLAGS) $<
|
585 |
|
|
|
586 |
|
|
ifeq ($(OBJEXT),o)
|
587 |
|
|
|
588 |
|
|
tkres.$(OBJEXT): $(ROOT)/win/rc/tk.rc
|
589 |
|
|
$(WINDRES) --include $(ROOT)/win/rc --include $(ROOT)/generic --define VS_VERSION_INFO=1 $(ROOT)/win/rc/tk.rc tkres.$(OBJEXT)
|
590 |
|
|
|
591 |
|
|
wishres.$(OBJEXT): $(ROOT)/win/rc/wish.rc
|
592 |
|
|
$(WINDRES) --include $(ROOT)/win/rc --include $(ROOT)/generic --define VS_VERSION_INFO=1 $(ROOT)/win/rc/wish.rc wishres.$(OBJEXT)
|
593 |
|
|
|
594 |
|
|
else
|
595 |
|
|
|
596 |
|
|
tkres.$(OBJEXT): $(ROOT)/win/rc/tk.rc
|
597 |
|
|
rc -i$(ROOT)/win/rc -i$(ROOT)/generic -dVS_VERSION_INFO=1 -fotkres.$(OBJEXT) $(ROOT)/win/rc/tk.rc
|
598 |
|
|
|
599 |
|
|
wishres.$(OBJEXT): $(ROOT)/win/rc/wish.rc
|
600 |
|
|
rc -i$(ROOT)/win/rc -i$(ROOT)/generic -dVS_VERSION_INFO=1 -fowishres.$(OBJEXT) $(ROOT)/win/rc/wish.rc
|
601 |
|
|
|
602 |
|
|
endif
|
603 |
|
|
|
604 |
|
|
#{$(ROOT)\win\rc}.rc{$(TMPDIR)}.res:
|
605 |
|
|
# $(rc32) -fo $@ -r -i $(ROOT)\generic $<
|
606 |
|
|
|
607 |
|
|
clean:
|
608 |
|
|
rm -f *.exp *.a *.dll *.exe $(TMPDIR)/*.$(OBJEXT) *.res *.def
|
609 |
|
|
rm -f tk.base tkplugin.base
|
610 |
|
|
|
611 |
|
|
# dependencies
|
612 |
|
|
|
613 |
|
|
$(TMPDIR)/tk.res: \
|
614 |
|
|
$(RCDIR)/buttons.bmp \
|
615 |
|
|
$(RCDIR)/cursor*.cur \
|
616 |
|
|
$(RCDIR)/tk.ico
|
617 |
|
|
|
618 |
|
|
$(GENERICDIR)/default.h: $(WINDIR)/tkWinDefault.h
|
619 |
|
|
$(GENERICDIR)/tkButton.c: $(GENERICDIR)/default.h
|
620 |
|
|
$(GENERICDIR)/tkCanvas.c: $(GENERICDIR)/default.h
|
621 |
|
|
$(GENERICDIR)/tkEntry.c: $(GENERICDIR)/default.h
|
622 |
|
|
$(GENERICDIR)/tkFrame.c: $(GENERICDIR)/default.h
|
623 |
|
|
$(GENERICDIR)/tkListbox.c: $(GENERICDIR)/default.h
|
624 |
|
|
$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/default.h
|
625 |
|
|
$(GENERICDIR)/tkMenubutton.c: $(GENERICDIR)/default.h
|
626 |
|
|
$(GENERICDIR)/tkMessage.c: $(GENERICDIR)/default.h
|
627 |
|
|
$(GENERICDIR)/tkScale.c: $(GENERICDIR)/default.h
|
628 |
|
|
$(GENERICDIR)/tkScrollbar.c: $(GENERICDIR)/default.h
|
629 |
|
|
$(GENERICDIR)/tkText.c: $(GENERICDIR)/default.h
|
630 |
|
|
$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/default.h
|
631 |
|
|
$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/default.h
|
632 |
|
|
|
633 |
|
|
$(GENERICDIR)/tkText.c: $(GENERICDIR)/tkText.h
|
634 |
|
|
$(GENERICDIR)/tkTextBTree.c: $(GENERICDIR)/tkText.h
|
635 |
|
|
$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
|
636 |
|
|
$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
|
637 |
|
|
$(GENERICDIR)/tkTextImage.c: $(GENERICDIR)/tkText.h
|
638 |
|
|
$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/tkText.h
|
639 |
|
|
$(GENERICDIR)/tkTextMark.c: $(GENERICDIR)/tkText.h
|
640 |
|
|
$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/tkText.h
|
641 |
|
|
$(GENERICDIR)/tkTextWind.c: $(GENERICDIR)/tkText.h
|
642 |
|
|
|
643 |
|
|
$(GENERICDIR)/tkMacWinMenu.c: $(GENERICDIR)/tkMenu.h
|
644 |
|
|
$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/tkMenu.h
|
645 |
|
|
$(GENERICDIR)/tkMenuDraw.c: $(GENERICDIR)/tkMenu.h
|
646 |
|
|
$(WINDIR)/tkWinMenu.c: $(GENERICDIR)/tkMenu.h
|
647 |
|
|
|
648 |
|
|
Makefile: $(WINDIR)/Makefile.in config.status
|
649 |
|
|
$(SHELL) config.status
|
650 |
|
|
|
651 |
|
|
config.status: $(WINDIR)/configure
|
652 |
|
|
./config.status --recheck
|