]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # File: makefile.twn | |
3 | # Author: Julian Smart | |
4 | # Created: 1993 | |
5 | # Updated: | |
6 | # | |
7 | # Makefile for libwx.a, tagetting TWIN32 | |
8 | ||
9 | # Replace this with your own path if necessary | |
10 | WXDIR = ../.. | |
11 | ||
12 | # All common UNIX compiler flags and options are now in | |
13 | # this central makefile. | |
14 | include $(WXDIR)/src/maketwin.env | |
15 | ||
16 | # IMPORTANT: if you want to link in subsidiary libraries, | |
17 | # required for some optional parts of wxWindows, you must | |
18 | # set EXTRATARGETS and EXTRAOBJS to match the settings in wx_setup.h. | |
19 | # Having done this, you won't have to worry about linking them | |
20 | # into each application. | |
21 | # | |
22 | # Here's the full list. | |
23 | # prologio: Required if using the wxWindows resource facility | |
24 | # USE_WX_RESOURCES should be 1 | |
25 | # xmgauge: Gauge class (required for Motif only) | |
26 | # USE_GAUGE should be 1 | |
27 | # xpm: XPM pixmap support | |
28 | # USE_XPM_IN_X should be 1 | |
29 | # wxstring: string class | |
30 | # USE_GNU_WXSTRING should be 1 | |
31 | # | |
32 | # Unfortunately, 'ar' doesn't like combining objects and libraries, | |
33 | # so we must identify all the objects from the subordinate libraries. Yuck! | |
34 | XPMSRC=../../contrib/wxxpm/objects$(GUISUFFIX) | |
35 | XPMOBJS=$(XPMSRC)/crbuffri.$(OBJSUFF) $(XPMSRC)/crbuffrp.$(OBJSUFF) $(XPMSRC)/crdatfri.$(OBJSUFF) $(XPMSRC)/crdatfrp.$(OBJSUFF)\ | |
36 | $(XPMSRC)/create.$(OBJSUFF) $(XPMSRC)/crifrbuf.$(OBJSUFF) $(XPMSRC)/crifrdat.$(OBJSUFF) $(XPMSRC)/crpfrbuf.$(OBJSUFF) $(XPMSRC)/crpfrdat.$(OBJSUFF)\ | |
37 | $(XPMSRC)/data.$(OBJSUFF) $(XPMSRC)/hashtab.$(OBJSUFF) $(XPMSRC)/misc.$(OBJSUFF) $(XPMSRC)/parse.$(OBJSUFF) $(XPMSRC)/rdftodat.$(OBJSUFF)\ | |
38 | $(XPMSRC)/rdftoi.$(OBJSUFF) $(XPMSRC)/rdftop.$(OBJSUFF) $(XPMSRC)/rgb.$(OBJSUFF) $(XPMSRC)/scan.$(OBJSUFF) $(XPMSRC)/simx.$(OBJSUFF)\ | |
39 | $(XPMSRC)/wrffrdat.$(OBJSUFF) $(XPMSRC)/wrffri.$(OBJSUFF) $(XPMSRC)/wrffrp.$(OBJSUFF) | |
40 | ||
41 | # Subordinate library possibilities | |
42 | ||
43 | EXTRAOBJS= | |
44 | ||
45 | GENDIR=../generic | |
46 | COMMDIR=../common | |
47 | XPMDIR=../xpm | |
48 | OLEDIR=ole | |
49 | MSWDIR=. | |
50 | ||
51 | GENERICOBJDIR=../generic/$(OBJDIR) | |
52 | COMMOBJDIR=../common/$(OBJDIR) | |
53 | OLEOBJDIR=ole/$(OBJDIR) | |
54 | MSWDIR=$(OBJDIR) | |
55 | ||
56 | DOCDIR = $(WXDIR)\docs | |
57 | ||
58 | GENERICOBJS= \ | |
59 | $(GENDIR)/choicdgg.$(OBJSUFF) \ | |
60 | $(GENDIR)/dirdlgg.$(OBJSUFF) \ | |
61 | $(GENDIR)/gridg.$(OBJSUFF) \ | |
62 | $(GENDIR)/laywin.$(OBJSUFF) \ | |
63 | $(GENDIR)/panelg.$(OBJSUFF) \ | |
64 | $(GENDIR)/progdlgg.$(OBJSUFF) \ | |
65 | $(GENDIR)/prop.$(OBJSUFF) \ | |
66 | $(GENDIR)/propform.$(OBJSUFF) \ | |
67 | $(GENDIR)/proplist.$(OBJSUFF) \ | |
68 | $(GENDIR)/sashwin.$(OBJSUFF) \ | |
69 | $(GENDIR)/scrolwin.$(OBJSUFF) \ | |
70 | $(GENDIR)/splitter.$(OBJSUFF) \ | |
71 | $(GENDIR)/statusbr.$(OBJSUFF) \ | |
72 | $(GENDIR)/tabg.$(OBJSUFF) \ | |
73 | $(GENDIR)/textdlgg.$(OBJSUFF) | |
74 | ||
75 | # $(GENDIR)/colrdlgg.$(OBJSUFF) \ | |
76 | # $(GENDIR)/fontdlgg.$(OBJSUFF) \ | |
77 | # $(GENDIR)/prntdlgg.$(OBJSUFF) \ | |
78 | # $(GENDIR)/printps.$(OBJSUFF) \ | |
79 | # $(GENDIR)/msgdlgg.$(OBJSUFF) \ | |
80 | ||
81 | COMMONOBJS = \ | |
82 | $(COMMDIR)/config.$(OBJSUFF) \ | |
83 | $(COMMDIR)/cmndata.$(OBJSUFF) \ | |
84 | $(COMMDIR)/dcbase.$(OBJSUFF) \ | |
85 | $(COMMDIR)/docview.$(OBJSUFF) \ | |
86 | $(COMMDIR)/docmdi.$(OBJSUFF) \ | |
87 | $(COMMDIR)/dynarray.$(OBJSUFF) \ | |
88 | $(COMMDIR)/event.$(OBJSUFF) \ | |
89 | $(COMMDIR)/file.$(OBJSUFF) \ | |
90 | $(COMMDIR)/fileconf.$(OBJSUFF) \ | |
91 | $(COMMDIR)/filefn.$(OBJSUFF) \ | |
92 | $(COMMDIR)/framecmn.$(OBJSUFF) \ | |
93 | $(COMMDIR)/gdicmn.$(OBJSUFF) \ | |
94 | $(COMMDIR)/helpbase.$(OBJSUFF) \ | |
95 | $(COMMDIR)/image.$(OBJSUFF) \ | |
96 | $(COMMDIR)/imagbmp.$(OBJSUFF) \ | |
97 | $(COMMDIR)/imagpng.$(OBJSUFF) \ | |
98 | $(COMMDIR)/imagjpeg.$(OBJSUFF) \ | |
99 | $(COMMDIR)/intl.$(OBJSUFF) \ | |
100 | $(COMMDIR)/ipcbase.$(OBJSUFF) \ | |
101 | $(COMMDIR)/layout.$(OBJSUFF) \ | |
102 | $(COMMDIR)/log.$(OBJSUFF) \ | |
103 | $(COMMDIR)/memory.$(OBJSUFF) \ | |
104 | $(COMMDIR)/module.$(OBJSUFF) \ | |
105 | $(COMMDIR)/mimetype.$(OBJSUFF) \ | |
106 | $(COMMDIR)/object.$(OBJSUFF) \ | |
107 | $(COMMDIR)/odbc.$(OBJSUFF) \ | |
108 | $(COMMDIR)/process.$(OBJSUFF) \ | |
109 | $(COMMDIR)/prntbase.$(OBJSUFF) \ | |
110 | $(COMMDIR)/resource.$(OBJSUFF) \ | |
111 | $(COMMDIR)/tbarbase.$(OBJSUFF) \ | |
112 | $(COMMDIR)/tbarsmpl.$(OBJSUFF) \ | |
113 | $(COMMDIR)/textfile.$(OBJSUFF) \ | |
114 | $(COMMDIR)/timercmn.$(OBJSUFF) \ | |
115 | $(COMMDIR)/utilscmn.$(OBJSUFF) \ | |
116 | $(COMMDIR)/validate.$(OBJSUFF) \ | |
117 | $(COMMDIR)/valgen.$(OBJSUFF) \ | |
118 | $(COMMDIR)/valtext.$(OBJSUFF) \ | |
119 | $(COMMDIR)/date.$(OBJSUFF) \ | |
120 | $(COMMDIR)/wxexpr.$(OBJSUFF) \ | |
121 | $(COMMDIR)/hash.$(OBJSUFF) \ | |
122 | $(COMMDIR)/list.$(OBJSUFF) \ | |
123 | $(COMMDIR)/variant.$(OBJSUFF) \ | |
124 | $(COMMDIR)/paper.$(OBJSUFF) \ | |
125 | $(COMMDIR)/string.$(OBJSUFF) \ | |
126 | $(COMMDIR)/time.$(OBJSUFF) \ | |
127 | $(COMMDIR)/tokenzr.$(OBJSUFF) \ | |
128 | $(COMMDIR)/y_tab.$(OBJSUFF) \ | |
129 | $(COMMDIR)/stream.$(OBJSUFF) \ | |
130 | $(COMMDIR)/wfstream.$(OBJSUFF) \ | |
131 | $(COMMDIR)/mstream.$(OBJSUFF) \ | |
132 | $(COMMDIR)/zstream.$(OBJSUFF) \ | |
133 | $(COMMDIR)/datstrm.$(OBJSUFF) \ | |
134 | $(COMMDIR)/objstrm.$(OBJSUFF) \ | |
135 | $(COMMDIR)/extended.$(OBJSUFF) \ | |
136 | $(COMMDIR)/wincmn.$(OBJSUFF) | |
137 | ||
138 | # NOTE: if the socket-related files fail with a syntax error in Sockets.h, | |
139 | # remove the files (probably all GnuWin32 releases < b20). Cygwin b20 is OK, | |
140 | # Mingw32 may still have problems. | |
141 | # $(COMMDIR)/socket.$(OBJSUFF) \ | |
142 | # $(COMMDIR)/sckaddr.$(OBJSUFF) \ | |
143 | # $(COMMDIR)/sckfile.$(OBJSUFF) \ | |
144 | # $(COMMDIR)/sckipc.$(OBJSUFF) \ | |
145 | # $(COMMDIR)/sckstrm.$(OBJSUFF) \ | |
146 | # $(COMMDIR)/protocol.$(OBJSUFF) \ | |
147 | # $(COMMDIR)/http.$(OBJSUFF) \ | |
148 | # $(COMMDIR)/ftp.$(OBJSUFF) \ | |
149 | # $(COMMDIR)/url.$(OBJSUFF) \ | |
150 | ||
151 | MSWOBJS = \ | |
152 | accel.$(OBJSUFF) \ | |
153 | app.$(OBJSUFF) \ | |
154 | bitmap.$(OBJSUFF) \ | |
155 | bmpbuttn.$(OBJSUFF) \ | |
156 | brush.$(OBJSUFF) \ | |
157 | button.$(OBJSUFF) \ | |
158 | checkbox.$(OBJSUFF) \ | |
159 | checklst.$(OBJSUFF) \ | |
160 | caret.$(OBJSUFF) \ | |
161 | choice.$(OBJSUFF) \ | |
162 | clipbrd.$(OBJSUFF) \ | |
163 | colordlg.$(OBJSUFF) \ | |
164 | colour.$(OBJSUFF) \ | |
165 | combobox.$(OBJSUFF) \ | |
166 | control.$(OBJSUFF) \ | |
167 | curico.$(OBJSUFF) \ | |
168 | cursor.$(OBJSUFF) \ | |
169 | data.$(OBJSUFF) \ | |
170 | dc.$(OBJSUFF) \ | |
171 | dcmemory.$(OBJSUFF) \ | |
172 | dcclient.$(OBJSUFF) \ | |
173 | dcprint.$(OBJSUFF) \ | |
174 | dcscreen.$(OBJSUFF) \ | |
175 | dde.$(OBJSUFF) \ | |
176 | dialog.$(OBJSUFF) \ | |
177 | dib.$(OBJSUFF) \ | |
178 | filedlg.$(OBJSUFF) \ | |
179 | font.$(OBJSUFF) \ | |
180 | fontdlg.$(OBJSUFF) \ | |
181 | frame.$(OBJSUFF) \ | |
182 | gaugemsw.$(OBJSUFF) \ | |
183 | gauge95.$(OBJSUFF) \ | |
184 | gdiobj.$(OBJSUFF) \ | |
185 | helpwin.$(OBJSUFF) \ | |
186 | icon.$(OBJSUFF) \ | |
187 | imaglist.$(OBJSUFF) \ | |
188 | joystick.$(OBJSUFF) \ | |
189 | listbox.$(OBJSUFF) \ | |
190 | listctrl.$(OBJSUFF) \ | |
191 | main.$(OBJSUFF) \ | |
192 | mdi.$(OBJSUFF) \ | |
193 | menu.$(OBJSUFF) \ | |
194 | menuitem.$(OBJSUFF) \ | |
195 | metafile.$(OBJSUFF) \ | |
196 | minifram.$(OBJSUFF) \ | |
197 | msgdlg.$(OBJSUFF) \ | |
198 | nativdlg.$(OBJSUFF) \ | |
199 | notebook.$(OBJSUFF) \ | |
200 | ownerdrw.$(OBJSUFF) \ | |
201 | palette.$(OBJSUFF) \ | |
202 | pen.$(OBJSUFF) \ | |
203 | penwin.$(OBJSUFF) \ | |
204 | printdlg.$(OBJSUFF) \ | |
205 | printwin.$(OBJSUFF) \ | |
206 | radiobox.$(OBJSUFF) \ | |
207 | radiobut.$(OBJSUFF) \ | |
208 | region.$(OBJSUFF) \ | |
209 | registry.$(OBJSUFF) \ | |
210 | regconf.$(OBJSUFF) \ | |
211 | scrolbar.$(OBJSUFF) \ | |
212 | settings.$(OBJSUFF) \ | |
213 | slidrmsw.$(OBJSUFF) \ | |
214 | slider95.$(OBJSUFF) \ | |
215 | spinbutt.$(OBJSUFF) \ | |
216 | statbmp.$(OBJSUFF) \ | |
217 | statbox.$(OBJSUFF) \ | |
218 | statbr95.$(OBJSUFF) \ | |
219 | stattext.$(OBJSUFF) \ | |
220 | tabctrl.$(OBJSUFF) \ | |
221 | taskbar.$(OBJSUFF) \ | |
222 | tbar95.$(OBJSUFF) \ | |
223 | tbarmsw.$(OBJSUFF) \ | |
224 | textctrl.$(OBJSUFF) \ | |
225 | thread.$(OBJSUFF) \ | |
226 | timer.$(OBJSUFF) \ | |
227 | tooltip.$(OBJSUFF) \ | |
228 | treectrl.$(OBJSUFF) \ | |
229 | utils.$(OBJSUFF) \ | |
230 | utilsexc.$(OBJSUFF) \ | |
231 | wave.$(OBJSUFF) \ | |
232 | window.$(OBJSUFF) \ | |
233 | xpmhand.$(OBJSUFF) | |
234 | ||
235 | # Native wxDirDlg can't be compiled due to GnuWin32/OLE limitations | |
236 | # dirdlg.$(OBJSUFF) \ | |
237 | ||
238 | # OLE not supported yet by GnuWin32 | |
239 | # $(OLEDIR)/droptgt.$(OBJSUFF) \ | |
240 | # $(OLEDIR)/dropsrc.$(OBJSUFF) \ | |
241 | # $(OLEDIR)/dataobj.$(OBJSUFF) \ | |
242 | # $(OLEDIR)/oleutils.$(OBJSUFF) \ | |
243 | # $(OLEDIR)/uuid.$(OBJSUFF) \ | |
244 | # $(OLEDIR)/automtn.$(OBJSUFF) | |
245 | ||
246 | XPMOBJECTS = $(XPMDIR)/crbuffri.o\ | |
247 | $(XPMDIR)/crdatfri.o\ | |
248 | $(XPMDIR)/create.o $(XPMDIR)/crifrbuf.o\ | |
249 | $(XPMDIR)/crifrdat.o\ | |
250 | $(XPMDIR)/data.o\ | |
251 | $(XPMDIR)/hashtab.o $(XPMDIR)/misc.o\ | |
252 | $(XPMDIR)/parse.o $(XPMDIR)/rdftodat.o\ | |
253 | $(XPMDIR)/rdftoi.o\ | |
254 | $(XPMDIR)/rgb.o $(XPMDIR)/scan.o\ | |
255 | $(XPMDIR)/simx.o $(XPMDIR)/wrffrdat.o\ | |
256 | $(XPMDIR)/wrffrp.o $(XPMDIR)/wrffri.o | |
257 | ||
258 | OBJECTS = $(MSWOBJS) $(COMMONOBJS) $(GENERICOBJS) # $(XPMOBJECTS) | |
259 | ||
260 | all: $(OBJECTS) $(WXLIB) | |
261 | ||
262 | base: | |
263 | cd $(WXDIR)/src/common; $(MAKE) -f makefile.g95 GUI=$(GUI) GUISUFFIX=$(GUISUFFIX) CC=$(CC)\ | |
264 | OPTIONS='$(OPTIONS)' DEBUG='$(DEBUG)' DEBUGFLAGS='$(DEBUGFLAGS)' WARN='$(WARN)' XLIB='$(XLIB)' XINCLUDE='$(XINCLUDE)' | |
265 | ||
266 | ||
267 | $(WXLIB): $(OBJECTS) $(EXTRAOBJS) | |
268 | ar $(AROPTIONS) $@ $(EXTRAOBJS) $(OBJECTS) | |
269 | $(RANLIB) $@ | |
270 | ||
271 | #$(MSWOBJDIR): | |
272 | # mkdir $(OBJDIR) | |
273 | ||
274 | #$(COMMOBJDIR): | |
275 | # mkdir $(COMMDIR)/$(OBJDIR) | |
276 | ||
277 | #$(GENERICOBJDIR): | |
278 | # mkdir $(GENDIR)/$(OBJDIR) | |
279 | ||
280 | $(OBJECTS): $(WXINC)/wx/defs.h $(WXINC)/wx/object.h $(WXINC)/wx/setup.h | |
281 | ||
282 | $(COMMDIR)/y_tab.$(OBJSUFF): $(COMMDIR)/y_tab.c $(COMMDIR)/lex_yy.c | |
283 | $(CCLEX) -c $(CPPFLAGS) -o $@ $(COMMDIR)/y_tab.c | |
284 | ||
285 | # Replace lex with flex if you run into compilation | |
286 | # problems with lex_yy.c. See also note about LEX_SCANNER | |
287 | # above. | |
288 | $(COMMDIR)/lex_yy.c: $(COMMDIR)/lexer.l | |
289 | $(LEX) $(COMMDIR)/lexer.l | |
290 | mv lex.yy.c $(COMMDIR)/lex_yy.c | |
291 | ||
292 | # The following may be required for FLEX | |
293 | # $(LEX) -o$(COMMDIR)/lex_yy.c $(COMMDIR)/lexer.l | |
294 | ||
295 | # sed -e "s/BUFSIZ/5000/g" < lex.yy.c | \ | |
296 | # sed -e "s/yyoutput(c)/void yyoutput(c)/g" | \ | |
297 | # sed -e "s/YYLMAX 200/YYLMAX 5000/g" > lex_yy.c | |
298 | # rm -f lex.yy.c | |
299 | ||
300 | # Replace yacc with bison if you run into compilation | |
301 | # problems with y_tab.c. | |
302 | ||
303 | #$(COMMDIR)/y_tab.c: $(COMMDIR)/parser.y | |
304 | # $(YACC) -o $(COMMDIR)/y_tab.c $(COMMDIR)/parser.y | |
305 | ||
306 | # If you use e.g. gcc on Unix, uncomment these lines | |
307 | # and comment out the above. | |
308 | ||
309 | $(COMMDIR)/y_tab.c: $(COMMDIR)/parser.y | |
310 | $(YACC) $(COMMDIR)/parser.y | |
311 | mv y.tab.c $(COMMDIR)/y_tab.c | |
312 | ||
313 | # Extra targets | |
314 | rcparser: | |
315 | cd $(WXDIR)/utils/rcparser/src; $(MAKE) -f makefile.g95 | |
316 | cd $(WXDIR)/src/msw | |
317 | ||
318 | clean_rcp: | |
319 | cd $(WXDIR)/utils/rcparser/src; $(MAKE) -f makefile.g95 clean | |
320 | cd $(WXDIR)/src/msw | |
321 | ||
322 | clean: | |
323 | rm -f $(OBJECTS) $(EXTRAOBJS) ../common/y_tab.c ../common/lex_yy.c $(WXDIR)/lib/libwx$(GUISUFFIX).a core | |
324 | ||
325 | cleanall: clean | |
326 |