-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathmingw.mk
86 lines (66 loc) · 2.33 KB
/
mingw.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
##### Top of the Tkhtml source tree - the directory with this file in it.
#
TOP = /home/dan/work/tkhtml/htmlwidget/
##### BUILD can be DEBUG or RELEASE.
#
# BUILD = DEBUG
BUILD = RELEASE
HV3_POLIPO = /home/dan/work/polipo/hv3_polipo.exe
##### Version of and path to the Tcl installation to use.
#
TCLVERSION = 85
TCL = /home/dan/work/tkhtml/mingwtcl/install
##### Flags passed to the C-compiler to link to Tcl.
#
# TCLLIB = -L$(TCL)/lib -ltclstub$(TCLVERSION) -ltkstub$(TCLVERSION)
TCLLIB = -L$(TCL)/lib -ltcl$(TCLVERSION) -ltk$(TCLVERSION) -ltclstub$(TCLVERSION) -ltkstub$(TCLVERSION)
##### Extra libraries used by Tcl on Linux. These flags are only required to
# staticly link Tcl into an executable
#
# TCLLIB_DEBUG += -L/usr/X11R6/lib/ -lX11 -ldl -lm
BCC = gcc
CC = i386-mingw32-gcc
CFLAGS_RELEASE = -O2 -DNDEBUG
CFLAGS_DEBUG = -g
CFLAGS = $(CFLAGS_$(BUILD))
CFLAGS += -DUSE_TCL_STUBS=1 -DUSE_TK_STUBS=1
##### The name of the shared library file to build.
#
SHARED_LIB_DEBUG = libTkhtml3g.dll
SHARED_LIB_RELEASE = libTkhtml3.dll
SHARED_LIB = $(SHARED_LIB_$(BUILD))
##### Command to build a shared library from a set of object files. The
# command executed will be:
#
# $(MKSHLIB) $(OBJS) $(TCLSTUBSLIB) -o $(SHARED_LIB)
#
MKSHLIB = $(CC) -shared
TCLSTUBSLIB = "/home/dan/work/tkhtml/mingwtcl/install/lib/libtclstub85.a"
TCLSTUBSLIB += "/home/dan/work/tkhtml/mingwtcl/install/lib/libtkstub85.a"
TCLSTUBSLIB += -LC:/Tcl/lib
##### Commands to run tclsh on the build platform (to generate C files
# to be passed to $(CC) from tcl scripts).
#
TCLSH = tclsh
##### Strip the shared library
#
STRIP = i386-mingw32-strip
MKSTARKIT = tclkit /home/dan/bin/sdx.kit wrap
STARKITRT = /home/dan/work/tclkit-win32.upx.exe
##### Javascript libaries - libgc.a and libsee.a
#
JS_SHARED_LIB = libTclsee.dll
JSLIB = $(HOME)/work/tkhtml/jswin/lib/libsee.a
JSLIB += $(HOME)/work/tkhtml/jswin/lib/libgc.a
JSFLAGS = -I$(HOME)/work/tkhtml/jswin/include
#
# End of configuration section.
###########################################################################
default: binaries
hv3-win32.exe: hv3_img.kit
cp $(STARKITRT) starkit_runtime
$(MKSTARKIT) hv3_img.bin -runtime ./starkit_runtime
mv hv3_img.bin hv3-win32.exe
chmod 644 hv3-win32.exe
###############################################################################
include $(TOP)/main.mk