7 # Makefile for libwx.a, tagetting TWIN32
9 # Replace this with your own path if necessary
12 # All common UNIX compiler flags and options are now in
13 # this central makefile.
14 include $(WXDIR)/src/maketwin.env
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.
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
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)
41 # Subordinate library possibilities
51 GENERICOBJDIR=../generic/$(OBJDIR)
52 COMMOBJDIR=../common/$(OBJDIR)
53 OLEOBJDIR=ole/$(OBJDIR)
56 DOCDIR = $(WXDIR)\docs
59 $(GENDIR)/choicdgg.$(OBJSUFF) \
60 $(GENDIR)/dirdlgg.$(OBJSUFF) \
61 $(GENDIR)/gridg.$(OBJSUFF) \
62 $(GENDIR)/laywin.$(OBJSUFF) \
63 $(GENDIR)/panelg.$(OBJSUFF) \
64 $(GENDIR)/prop.$(OBJSUFF) \
65 $(GENDIR)/propform.$(OBJSUFF) \
66 $(GENDIR)/proplist.$(OBJSUFF) \
67 $(GENDIR)/sashwin.$(OBJSUFF) \
68 $(GENDIR)/scrolwin.$(OBJSUFF) \
69 $(GENDIR)/splitter.$(OBJSUFF) \
70 $(GENDIR)/statusbr.$(OBJSUFF) \
71 $(GENDIR)/tabg.$(OBJSUFF) \
72 $(GENDIR)/textdlgg.$(OBJSUFF)
74 # $(GENDIR)/colrdlgg.$(OBJSUFF) \
75 # $(GENDIR)/fontdlgg.$(OBJSUFF) \
76 # $(GENDIR)/prntdlgg.$(OBJSUFF) \
77 # $(GENDIR)/printps.$(OBJSUFF) \
78 # $(GENDIR)/msgdlgg.$(OBJSUFF) \
81 $(COMMDIR)/config.$(OBJSUFF) \
82 $(COMMDIR)/cmndata.$(OBJSUFF) \
83 $(COMMDIR)/docview.$(OBJSUFF) \
84 $(COMMDIR)/docmdi.$(OBJSUFF) \
85 $(COMMDIR)/dynarray.$(OBJSUFF) \
86 $(COMMDIR)/event.$(OBJSUFF) \
87 $(COMMDIR)/file.$(OBJSUFF) \
88 $(COMMDIR)/fileconf.$(OBJSUFF) \
89 $(COMMDIR)/filefn.$(OBJSUFF) \
90 $(COMMDIR)/framecmn.$(OBJSUFF) \
91 $(COMMDIR)/gdicmn.$(OBJSUFF) \
92 $(COMMDIR)/helpbase.$(OBJSUFF) \
93 $(COMMDIR)/image.$(OBJSUFF) \
94 $(COMMDIR)/intl.$(OBJSUFF) \
95 $(COMMDIR)/ipcbase.$(OBJSUFF) \
96 $(COMMDIR)/layout.$(OBJSUFF) \
97 $(COMMDIR)/log.$(OBJSUFF) \
98 $(COMMDIR)/memory.$(OBJSUFF) \
99 $(COMMDIR)/module.$(OBJSUFF) \
100 $(COMMDIR)/mimetype.$(OBJSUFF) \
101 $(COMMDIR)/object.$(OBJSUFF) \
102 $(COMMDIR)/odbc.$(OBJSUFF) \
103 $(COMMDIR)/process.$(OBJSUFF) \
104 $(COMMDIR)/prntbase.$(OBJSUFF) \
105 $(COMMDIR)/resource.$(OBJSUFF) \
106 $(COMMDIR)/tbarbase.$(OBJSUFF) \
107 $(COMMDIR)/tbarsmpl.$(OBJSUFF) \
108 $(COMMDIR)/textfile.$(OBJSUFF) \
109 $(COMMDIR)/timercmn.$(OBJSUFF) \
110 $(COMMDIR)/utilscmn.$(OBJSUFF) \
111 $(COMMDIR)/validate.$(OBJSUFF) \
112 $(COMMDIR)/valgen.$(OBJSUFF) \
113 $(COMMDIR)/valtext.$(OBJSUFF) \
114 $(COMMDIR)/date.$(OBJSUFF) \
115 $(COMMDIR)/wxexpr.$(OBJSUFF) \
116 $(COMMDIR)/hash.$(OBJSUFF) \
117 $(COMMDIR)/list.$(OBJSUFF) \
118 $(COMMDIR)/variant.$(OBJSUFF) \
119 $(COMMDIR)/string.$(OBJSUFF) \
120 $(COMMDIR)/time.$(OBJSUFF) \
121 $(COMMDIR)/tokenzr.$(OBJSUFF) \
122 $(COMMDIR)/y_tab.$(OBJSUFF) \
123 $(COMMDIR)/stream.$(OBJSUFF) \
124 $(COMMDIR)/wfstream.$(OBJSUFF) \
125 $(COMMDIR)/mstream.$(OBJSUFF) \
126 $(COMMDIR)/zstream.$(OBJSUFF) \
127 $(COMMDIR)/datstrm.$(OBJSUFF) \
128 $(COMMDIR)/objstrm.$(OBJSUFF) \
129 $(COMMDIR)/extended.$(OBJSUFF) \
130 $(COMMDIR)/wincmn.$(OBJSUFF)
132 # NOTE: if the socket-related files fail with a syntax error in Sockets.h,
133 # remove the files (probably all GnuWin32 releases < b20). Cygwin b20 is OK,
134 # Mingw32 may still have problems.
135 # $(COMMDIR)/socket.$(OBJSUFF) \
136 # $(COMMDIR)/sckaddr.$(OBJSUFF) \
137 # $(COMMDIR)/sckfile.$(OBJSUFF) \
138 # $(COMMDIR)/sckipc.$(OBJSUFF) \
139 # $(COMMDIR)/sckstrm.$(OBJSUFF) \
140 # $(COMMDIR)/protocol.$(OBJSUFF) \
141 # $(COMMDIR)/http.$(OBJSUFF) \
142 # $(COMMDIR)/ftp.$(OBJSUFF) \
143 # $(COMMDIR)/url.$(OBJSUFF) \
149 bmpbuttn.$(OBJSUFF) \
152 checkbox.$(OBJSUFF) \
153 checklst.$(OBJSUFF) \
156 colordlg.$(OBJSUFF) \
158 combobox.$(OBJSUFF) \
164 dcmemory.$(OBJSUFF) \
165 dcclient.$(OBJSUFF) \
167 dcscreen.$(OBJSUFF) \
175 gaugemsw.$(OBJSUFF) \
180 imaglist.$(OBJSUFF) \
181 joystick.$(OBJSUFF) \
183 listctrl.$(OBJSUFF) \
187 menuitem.$(OBJSUFF) \
188 metafile.$(OBJSUFF) \
189 minifram.$(OBJSUFF) \
191 nativdlg.$(OBJSUFF) \
192 notebook.$(OBJSUFF) \
193 ownerdrw.$(OBJSUFF) \
197 printdlg.$(OBJSUFF) \
198 printwin.$(OBJSUFF) \
199 radiobox.$(OBJSUFF) \
200 radiobut.$(OBJSUFF) \
202 registry.$(OBJSUFF) \
204 scrolbar.$(OBJSUFF) \
205 settings.$(OBJSUFF) \
206 slidrmsw.$(OBJSUFF) \
207 slider95.$(OBJSUFF) \
208 spinbutt.$(OBJSUFF) \
211 statbr95.$(OBJSUFF) \
212 stattext.$(OBJSUFF) \
217 textctrl.$(OBJSUFF) \
221 treectrl.$(OBJSUFF) \
223 utilsexc.$(OBJSUFF) \
228 # Native wxDirDlg can't be compiled due to GnuWin32/OLE limitations
229 # dirdlg.$(OBJSUFF) \
231 # OLE not supported yet by GnuWin32
232 # $(OLEDIR)/droptgt.$(OBJSUFF) \
233 # $(OLEDIR)/dropsrc.$(OBJSUFF) \
234 # $(OLEDIR)/dataobj.$(OBJSUFF) \
235 # $(OLEDIR)/oleutils.$(OBJSUFF) \
236 # $(OLEDIR)/uuid.$(OBJSUFF) \
237 # $(OLEDIR)/automtn.$(OBJSUFF)
239 XPMOBJECTS = $(XPMDIR)/crbuffri.o\
240 $(XPMDIR)/crdatfri.o\
241 $(XPMDIR)/create.o $(XPMDIR)/crifrbuf.o\
242 $(XPMDIR)/crifrdat.o\
244 $(XPMDIR)/hashtab.o $(XPMDIR)/misc.o\
245 $(XPMDIR)/parse.o $(XPMDIR)/rdftodat.o\
247 $(XPMDIR)/rgb.o $(XPMDIR)/scan.o\
248 $(XPMDIR)/simx.o $(XPMDIR)/wrffrdat.o\
249 $(XPMDIR)/wrffrp.o $(XPMDIR)/wrffri.o
251 OBJECTS = $(MSWOBJS) $(COMMONOBJS) $(GENERICOBJS) # $(XPMOBJECTS)
253 all: $(OBJECTS) $(WXLIB)
256 cd $(WXDIR)/src/common; $(MAKE) -f makefile.g95 GUI=$(GUI) GUISUFFIX=$(GUISUFFIX) CC=$(CC)\
257 OPTIONS='$(OPTIONS)' DEBUG='$(DEBUG)' DEBUGFLAGS='$(DEBUGFLAGS)' WARN='$(WARN)' XLIB='$(XLIB)' XINCLUDE='$(XINCLUDE)'
260 $(WXLIB): $(OBJECTS) $(EXTRAOBJS)
261 ar $(AROPTIONS) $@ $(EXTRAOBJS) $(OBJECTS)
268 # mkdir $(COMMDIR)/$(OBJDIR)
271 # mkdir $(GENDIR)/$(OBJDIR)
273 $(OBJECTS): $(WXINC)/wx/defs.h $(WXINC)/wx/object.h $(WXINC)/wx/setup.h
275 $(COMMDIR)/y_tab.$(OBJSUFF): $(COMMDIR)/y_tab.c $(COMMDIR)/lex_yy.c
276 $(CCLEX) -c $(CPPFLAGS) -o $@ $(COMMDIR)/y_tab.c
278 # Replace lex with flex if you run into compilation
279 # problems with lex_yy.c. See also note about LEX_SCANNER
281 $(COMMDIR)/lex_yy.c: $(COMMDIR)/lexer.l
282 $(LEX) $(COMMDIR)/lexer.l
283 mv lex.yy.c $(COMMDIR)/lex_yy.c
285 # The following may be required for FLEX
286 # $(LEX) -o$(COMMDIR)/lex_yy.c $(COMMDIR)/lexer.l
288 # sed -e "s/BUFSIZ/5000/g" < lex.yy.c | \
289 # sed -e "s/yyoutput(c)/void yyoutput(c)/g" | \
290 # sed -e "s/YYLMAX 200/YYLMAX 5000/g" > lex_yy.c
293 # Replace yacc with bison if you run into compilation
294 # problems with y_tab.c.
296 #$(COMMDIR)/y_tab.c: $(COMMDIR)/parser.y
297 # $(YACC) -o $(COMMDIR)/y_tab.c $(COMMDIR)/parser.y
299 # If you use e.g. gcc on Unix, uncomment these lines
300 # and comment out the above.
302 $(COMMDIR)/y_tab.c: $(COMMDIR)/parser.y
303 $(YACC) $(COMMDIR)/parser.y
304 mv y.tab.c $(COMMDIR)/y_tab.c
308 cd $(WXDIR)/utils/rcparser/src; $(MAKE) -f makefile.g95
312 cd $(WXDIR)/utils/rcparser/src; $(MAKE) -f makefile.g95 clean
316 rm -f $(OBJECTS) $(EXTRAOBJS) ../common/y_tab.c ../common/lex_yy.c $(WXDIR)/lib/libwx$(GUISUFFIX).a core