]> git.saurik.com Git - wxWidgets.git/blame_incremental - src/makeb32.env
display compilation warning under Mac OS X/Darwin for missing poll
[wxWidgets.git] / src / makeb32.env
... / ...
CommitLineData
1# Common settings for Borland 32-bit compilation (makefile.b32 files)
2
3!if "$(RM)" == ""
4RM= erase
5!endif
6
7WXDIR = $(WXWIN)
8CFG = $(WXDIR)\src\msw\wxw32
9
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
16ARCHINCDIR=$(WXDIR)\lib\msw
17ARCHSETUPH=$(ARCHINCDIR)\wx\setup.h
18
19# Using a config file isn't compatible across all BC++ versions
20# LNKCFG=$(WXDIR)\src\msw\bclnk32.cfg
21WXLIBDIR = $(WXDIR)\lib
22WXLIBDIR2 = $(WXDIR)\contrib\lib
23WXINC = $(WXDIR)\include;$(WXDIR)\contrib\include;$(WXDIR)\src\iodbc;$(WXDIR)\src\regex;
24WIN95FLAG = -D__WIN95__ -D__WINDOWS__
25RFLAGS = -i$(WXDIR)\include;$(WXDIR)\src
26
27# This should be changed to tlink32 if ilink32 is not available.
28# Ilink32 is available on BC++ 5.02 and above, and all
29# versions of C++ Builder.
30!ifndef LINK
31LINK=ilink32
32#LINK=tlink32
33!endif
34
35!ifndef FINAL
36FINAL=0
37!endif
38
39!ifndef WXMAKINGDLL
40WXMAKINGDLL=0
41!endif
42
43!if "$(FINAL)" == "1"
44OPT = -O2
45DEBUG_FLAGS = -DUSE_DEFINE
46LINKDEBUGFLAGS=
47!else
48OPT = -Od
49DEBUG_FLAGS= -v -DWXDEBUG=1 -D__WXDEBUG__ -DUSE_DEFINE
50LINKDEBUGFLAGS=/v
51!endif
52
53# allow to use debugger but no wxDebugging functions
54!if "$(FINAL)" == "hybrid"
55OPT = -Od
56DEBUG_FLAGS= -v
57LINKDEBUGFLAGS=/v
58!endif
59
60!ifndef DLL
61DLL=0
62!endif
63
64# Target WXMAKINGDLL WXUSINGDLL WXBUILDDLL
65# wxWin DLL 1 0 1
66# wxWin STATIC 0 0 0
67# App use wxWin DLL 0 1 0
68# DLL use wxWin DLL 0 1 1
69# DLL use wxWin STATIC 0 0 1
70#
71
72# Determine the library name depending on the options, to allow
73# multiple versions to coexist.
74# Note that the clean target will only delete the appropriate .lib for the current
75# options and all the obj files, and note that you must delete the obj files if you
76# change the options so that they are compiled using the correct ones.
77
78!if "$(WXMAKINGDLL)" == "1" || "$(WXUSINGDLL)" == "1"
79WXLIBNAME=wx32
80!else
81WXLIBNAME=wx32
82!endif
83
84
85#not sure what to do with unicode builds - we need to define something ?
86#!if "$(UNICODE)" == "1"
87#WXLIBNAME=$(WXLIBNAME)u
88#!endif
89
90
91#a hybrid , does not set __WXDEBUG__ but sets -v (see above)
92!if "$(FINAL)" == "hybrid"
93WXLIBNAME=$(WXLIBNAME)h
94CFG=$(CFG)h
95!endif
96
97!if "$(FINAL)" == "0"
98WXLIBNAME=$(WXLIBNAME)d
99CFG=$(CFG)d
100!endif
101
102!if "$(wxUSE_GUI)" == "0"
103WXLIBNAME=$(WXLIBNAME)b
104CFG=$(CFG)b
105CPPFLAGS=-DwxUSE_GUI=0
106!endif
107
108!if "$(WXMAKINGDLL)" != "1" && "$(WXUSINGDLL)" != "1"
109WXLIBNAME=$(WXLIBNAME)s
110!endif
111
112!if "$(WXMAKINGDLL)" == "1" || "$(WXUSINGDLL)" == "1"
113INCEXT=dll$(INCEXT)
114!endif
115
116!ifndef WXLIBDIR
117WXLIBDIR=$(WXDIR)\lib
118!endif
119
120WXLIB=$(WXLIBDIR)\$(WXLIBNAME).lib
121WXDLL=$(WXLIBDIR)\$(WXLIBNAME).dll
122
123!if "$(WXMAKINGDLL)" == "1"
124DLL_FLAGS= -DWXMAKINGDLL=1 -D_RTLDLL
125!else
126
127!if "$(WXUSINGDLL)" == "1"
128DLL_FLAGS= -DWXUSINGDLL=1 -D_RTLDLL
129!else
130DLL_FLAGS=
131!endif
132
133!endif
134
135!if "$(WXBUILDDLL)" == "1"
136LINK_FLAGS= /Tpd /c $(EXTRALINKFLAGS)
137!endif
138
139CFG=$(CFG).cfg
140CPPFLAGS=$(CPPFLAGS) $(DLL_FLAGS) $(EXTRACPPFLAGS) @$(CFG)
141
142DUMMY=dummy
143
144SRCSUFF = cpp
145OBJSUFF = obj
146
147WAITFLAG = /w
148
149.$(SRCSUFF).obj:
150 bcc32 $(CPPFLAGS) -c {$< }
151
152.c.obj:
153 bcc32 $(CPPFLAGS) -P- -c {$< }