]> git.saurik.com Git - wxWidgets.git/blame - src/makeb32.env
Doc corrections
[wxWidgets.git] / src / makeb32.env
CommitLineData
2bda0e17
KB
1# Common settings for Borland 32-bit compilation (makefile.b32 files)
2
3b50432a
GT
3!if "$(RM)" == ""
4RM= erase
5!endif
6
2bda0e17 7WXDIR = $(WXWIN)
8c3288a7 8CFG = $(WXDIR)\src\msw\wxw32
4deae7a0 9
6b6fc9b0
VZ
10BCCDIR=$(MAKEDIR)\..
11
12!if "$(BCCDIR)" == "\.."
13!error Your Borland compiler does not define MAKEDIR. Pleasedefine the BCCDIR variable in makeb32.env line 10, e.g. BCCDIR=d:\bc4
14!endif
15
4deae7a0
VZ
16ARCHINCDIR=$(WXDIR)\lib\msw
17ARCHSETUPH=$(ARCHINCDIR)\wx\setup.h
2b5f62a0
VZ
18#see below for SETUPSRCDIR
19
4deae7a0 20
b2cf617c
JS
21# Using a config file isn't compatible across all BC++ versions
22# LNKCFG=$(WXDIR)\src\msw\bclnk32.cfg
2bda0e17 23WXLIBDIR = $(WXDIR)\lib
b14391d1 24WXLIBDIR2 = $(WXDIR)\contrib\lib
3b50432a 25WXINC = $(WXDIR)\include;$(WXDIR)\contrib\include;$(WXDIR)\src\iodbc;$(WXDIR)\src\regex;
34138703 26WIN95FLAG = -D__WIN95__ -D__WINDOWS__
cbf65655 27RFLAGS = -i$(WXDIR)\include;$(WXDIR)\src
2bda0e17 28
8e97b17b
VZ
29# This should be changed to tlink32 if ilink32 is not available.
30# Ilink32 is available on BC++ 5.02 and above, and all
31# versions of C++ Builder.
32!ifndef LINK
a6e2b3a8 33LINK=ilink32
b2cf617c 34#LINK=tlink32
8e97b17b 35!endif
c3b177ae 36
2bda0e17
KB
37!ifndef FINAL
38FINAL=0
39!endif
40
8c3288a7
CE
41!ifndef WXMAKINGDLL
42WXMAKINGDLL=0
43!endif
44
cc77c86d 45!if "$(FINAL)" == "1"
2bda0e17 46OPT = -O2
40e1a9c0 47DEBUG_FLAGS = -DUSE_DEFINE
cc77c86d
CE
48LINKDEBUGFLAGS=
49!else
50OPT = -Od
51DEBUG_FLAGS= -v -DWXDEBUG=1 -D__WXDEBUG__ -DUSE_DEFINE
52LINKDEBUGFLAGS=/v
2bda0e17 53!endif
2bda0e17 54
8c3288a7
CE
55# allow to use debugger but no wxDebugging functions
56!if "$(FINAL)" == "hybrid"
57OPT = -Od
58DEBUG_FLAGS= -v
59LINKDEBUGFLAGS=/v
60!endif
61
c740f496
GL
62!ifndef DLL
63DLL=0
64!endif
65
66# Target WXMAKINGDLL WXUSINGDLL WXBUILDDLL
67# wxWin DLL 1 0 1
68# wxWin STATIC 0 0 0
69# App use wxWin DLL 0 1 0
70# DLL use wxWin DLL 0 1 1
71# DLL use wxWin STATIC 0 0 1
72#
73
cc77c86d
CE
74# Determine the library name depending on the options, to allow
75# multiple versions to coexist.
76# Note that the clean target will only delete the appropriate .lib for the current
77# options and all the obj files, and note that you must delete the obj files if you
78# change the options so that they are compiled using the correct ones.
79
80!if "$(WXMAKINGDLL)" == "1" || "$(WXUSINGDLL)" == "1"
81WXLIBNAME=wx32
82!else
83WXLIBNAME=wx32
84!endif
85
2b5f62a0
VZ
86## Use this if you want to use the UNIV controls set rather than the native ones
87## make -f makefile.b32 WXUSINGUNIV=1
88!if "$(WXUSINGUNIV)" == "1"
89USE_UNIV="UNIV"
90CFG=$(CFG)v
91WXLIBNAME=$(WXLIBNAME)v
92ARCHINCDIR=$(ARCHINCDIR)v
93SETUPSRCDIR=$(WXDIR)\include\wx\univ
94PORT=__WXUNIVERSAL__
95!else
96USE_UNIV=""
97PORT=__WXMSW__
98SETUPSRCDIR=$(WXDIR)\include\wx\msw
99!endif
c740f496 100
8c3288a7
CE
101#not sure what to do with unicode builds - we need to define something ?
102#!if "$(UNICODE)" == "1"
103#WXLIBNAME=$(WXLIBNAME)u
104#!endif
105
106
107#a hybrid , does not set __WXDEBUG__ but sets -v (see above)
108!if "$(FINAL)" == "hybrid"
cc77c86d 109WXLIBNAME=$(WXLIBNAME)h
8c3288a7
CE
110CFG=$(CFG)h
111!endif
112
113!if "$(FINAL)" == "0"
cc77c86d 114WXLIBNAME=$(WXLIBNAME)d
8c3288a7 115CFG=$(CFG)d
cc77c86d
CE
116!endif
117
118!if "$(wxUSE_GUI)" == "0"
119WXLIBNAME=$(WXLIBNAME)b
8c3288a7 120CFG=$(CFG)b
cc77c86d
CE
121CPPFLAGS=-DwxUSE_GUI=0
122!endif
123
8c3288a7
CE
124!if "$(WXMAKINGDLL)" != "1" && "$(WXUSINGDLL)" != "1"
125WXLIBNAME=$(WXLIBNAME)s
126!endif
127
cc77c86d
CE
128!if "$(WXMAKINGDLL)" == "1" || "$(WXUSINGDLL)" == "1"
129INCEXT=dll$(INCEXT)
130!endif
c740f496 131
cc77c86d
CE
132!ifndef WXLIBDIR
133WXLIBDIR=$(WXDIR)\lib
134!endif
135
136WXLIB=$(WXLIBDIR)\$(WXLIBNAME).lib
137WXDLL=$(WXLIBDIR)\$(WXLIBNAME).dll
138
139!if "$(WXMAKINGDLL)" == "1"
140DLL_FLAGS= -DWXMAKINGDLL=1 -D_RTLDLL
141!else
c740f496
GL
142
143!if "$(WXUSINGDLL)" == "1"
f6bcfd97 144DLL_FLAGS= -DWXUSINGDLL=1 -D_RTLDLL
c740f496
GL
145!else
146DLL_FLAGS=
c740f496
GL
147!endif
148
149!endif
150
151!if "$(WXBUILDDLL)" == "1"
741f371c 152LINK_FLAGS= /Tpd /c $(EXTRALINKFLAGS)
c740f496
GL
153!endif
154
8c3288a7 155CFG=$(CFG).cfg
e438abe5 156CPPFLAGS=$(CPPFLAGS) $(DLL_FLAGS) @$(CFG) $(EXTRACPPFLAGS)
c740f496 157
2bda0e17
KB
158DUMMY=dummy
159
160SRCSUFF = cpp
161OBJSUFF = obj
162
c09f2879
VZ
163WAITFLAG = /w
164
2bda0e17 165.$(SRCSUFF).obj:
cc77c86d 166 bcc32 $(CPPFLAGS) -c {$< }
2bda0e17
KB
167
168.c.obj:
cc77c86d 169 bcc32 $(CPPFLAGS) -P- -c {$< }