1 #!################################################################################
3 #! Purpose: tmake template file from which makefile.unx.in is generated by running
4 #! tmake -t unx wxwin.pro -o makefile.unx.in
5 #! Author: Vadim Zeitlin, Robert Roebling, Julian Smart
8 #!################################################################################
11 #! include the code which parses filelist.txt file and initializes
12 #! %wxCommon, %wxGeneric, %wxHtml, %wxUnix and %wxGTK hashes.
13 IncludeTemplate("filelist.t");
15 #! now transform these hashes into $project tags
16 foreach $file (sort keys %wxGeneric) {
17 next if $wxGeneric{$file} =~ /\bR\b/;
19 $file =~ s/cp?p?$/\o/;
20 $project{"WXGTK_GENERICOBJS"} .= "src/generic/" . $file . " "
23 #! now transform these hashes into $project tags
24 foreach $file (sort keys %wxGeneric) {
25 next if $wxCommon{$file} =~ /\bX\b/;
27 $file =~ s/cp?p?$/\o/;
28 $project{"WXMOTIF_GENERICOBJS"} .= "src/generic/" . $file . " "
31 foreach $file (sort keys %wxCommon) {
32 next if $wxCommon{$file} =~ /\bR\b/;
34 $file =~ s/cp?p?$/\o/;
35 $project{"WXGTK_COMMONOBJS"} .= "src/common/" . $file . " "
38 foreach $file (sort keys %wxCommon) {
39 next if $wxCommon{$file} =~ /\bX\b/;
41 $file =~ s/cp?p?$/\o/;
42 $project{"WXMOTIF_COMMONOBJS"} .= "src/common/" . $file . " "
45 foreach $file (sort keys %wxGTK) {
46 $file =~ s/cp?p?$/\o/;
47 $project{"WXGTK_GUIOBJS"} .= "src/gtk/" . $file . " "
50 foreach $file (sort keys %wxMOTIF) {
51 $file =~ s/cp?p?$/\o/;
52 $project{"WXMOTIF_GUIOBJS"} .= "src/motif/" . $file . " "
55 foreach $file (sort keys %wxHTML) {
56 $file =~ s/cp?p?$/\o/;
57 $project{"WXHTMLOBJS"} .= "src/html/" . $file . " "
60 foreach $file (sort keys %wxUNIX) {
61 $file =~ s/cp?p?$/\o/;
62 $project{"WXUNIXOBJS"} .= "src/unix/" . $file . " "
65 foreach $file (sort keys %wxWXINCLUDE) {
66 $project{"WX_HEADERS"} .= $file . " "
69 foreach $file (sort keys %wxGENERICINCLUDE) {
70 $project{"WXGENERIC_HEADERS"} .= "generic/" . $file . " "
73 foreach $file (sort keys %wxMOTIFINCLUDE) {
74 $project{"WXMOTIF_HEADERS"} .= "motif/" . $file . " "
77 foreach $file (sort keys %wxGTKINCLUDE) {
78 $project{"WXGTK_HEADERS"} .= "gtk/" . $file . " "
81 foreach $file (sort keys %wxHTMLINCLUDE) {
82 $project{"WXHTML_HEADERS"} .= "html/" . $file . " "
85 foreach $file (sort keys %wxUNIXINCLUDE) {
86 $project{"WXUNIX_HEADERS"} .= "unix/" . $file . " "
89 foreach $file (sort keys %wxPROTOCOLINCLUDE) {
90 $project{"WXPROTOCOL_HEADERS"} .= "protocol/" . $file . " "
94 # This file was automatically generated by tmake at #$ Now()
95 # DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE UNX.T!
99 # Author: Julian Smart, Robert Roebling, Vadim Zeitlin
102 # Copyright:(c) 1993, AIAI, University of Edinburgh,
103 # Copyright:(c) 1999, Vadim Zeitlin
104 # Copyright:(c) 1999, Robert Roebling
106 # Makefile for libwx_gtk.a, libwx_motif.a and libwx_msw.a
108 ###################################################################
110 include ./src/make.env
112 ############## override make.env for PIC ##########################
114 # Clears all default suffixes
115 .SUFFIXES: .o .cpp .c .cxx
118 $(CCC) -c $(CFLAGS) $(PICFLAGS) -o $@ $<
121 $(CC) -c $(CPPFLAGS) $(PICFLAGS) -o $@ $<
124 $(CC) -c $(CPPFLAGS) $(PICFLAGS) -o $@ $<
126 ########################### Paths #################################
130 VPATH = :@top_srcdir@
132 top_srcdir = @top_srcdir@
134 exec_prefix = @exec_prefix@
138 libexecdir = @libexecdir@
140 sysconfdir = @sysconfdir@
141 sharedstatedir = @sharedstatedir@
142 localstatedir = @localstatedir@
146 includedir = @includedir@
147 oldincludedir = /usr/include
151 pkgdatadir = $(datadir)/@PACKAGE@
152 pkglibdir = $(libdir)/@PACKAGE@
153 pkgincludedir = $(includedir)/@PACKAGE@
158 INSTALL_PROGRAM = @INSTALL_PROGRAM@
159 INSTALL_DATA = @INSTALL_DATA@
160 INSTALL_SCRIPT = @INSTALL_SCRIPT@
161 transform = @program_transform_name@
169 build_alias = @build_alias@
170 build_triplet = @build@
171 host_alias = @host_alias@
172 host_triplet = @host@
173 target_alias = @target_alias@
174 target_triplet = @target@
176 ############################# Dirs #################################
178 WXDIR = $(top_srcdir)
180 # Subordinate library possibilities
182 GENDIR = $(WXDIR)/src/generic
183 COMMDIR = $(WXDIR)/src/common
184 HTMLDIR = $(WXDIR)/src/html
185 UNIXDIR = $(WXDIR)/src/unix
186 PNGDIR = $(WXDIR)/src/png
187 JPEGDIR = $(WXDIR)/src/jpeg
188 ZLIBDIR = $(WXDIR)/src/zlib
189 GTKDIR = $(WXDIR)/src/gtk
190 MOTIFDIR = $(WXDIR)/src/motif
191 INCDIR = $(WXDIR)/include
193 DOCDIR = $(WXDIR)/docs
195 ############################## Files ##################################
198 #$ ExpandList("WX_HEADERS");
201 #$ ExpandList("WXGTK_HEADERS");
204 #$ ExpandList("WXMOTIF_HEADERS");
207 #$ ExpandList("WXUNIX_HEADERS");
210 #$ ExpandList("WXGENERIC_HEADERS");
213 #$ ExpandList("WXPROTOCOL_HEADERS");
216 #$ ExpandList("WXHTML_HEADERS");
219 #$ ExpandList("WXGTK_GENERICOBJS");
223 #$ ExpandList("WXGTK_COMMONOBJS");
226 #$ ExpandList("WXGTK_GUIOBJS");
228 MOTIF_GENERICOBJS = \
229 #$ ExpandList("WXMOTIF_GENERICOBJS");
233 #$ ExpandList("WXMOTIF_COMMONOBJS");
236 src/motif/xmcombo/xmcombo.o \
237 #$ ExpandList("WXMOTIF_GUIOBJS");
240 #$ ExpandList("WXHTMLOBJS");
243 #$ ExpandList("WXUNIXOBJS");
247 src/zlib/compress.o \
255 src/zlib/infblock.o \
256 src/zlib/inftrees.o \
257 src/zlib/infcodes.o \
284 src/jpeg/jmemnobs.o \
285 src/jpeg/jcapimin.o \
286 src/jpeg/jcapistd.o \
289 src/jpeg/jdatadst.o \
291 src/jpeg/jcmaster.o \
292 src/jpeg/jcmarker.o \
293 src/jpeg/jcmainct.o \
294 src/jpeg/jcprepct.o \
295 src/jpeg/jccoefct.o \
297 src/jpeg/jcsample.o \
300 src/jpeg/jcdctmgr.o \
301 src/jpeg/jfdctfst.o \
302 src/jpeg/jfdctflt.o \
303 src/jpeg/jfdctint.o \
304 src/jpeg/jdapimin.o \
305 src/jpeg/jdapistd.o \
307 src/jpeg/jdatasrc.o \
308 src/jpeg/jdmaster.o \
310 src/jpeg/jdmarker.o \
313 src/jpeg/jdmainct.o \
314 src/jpeg/jdcoefct.o \
315 src/jpeg/jdpostct.o \
316 src/jpeg/jddctmgr.o \
317 src/jpeg/jidctfst.o \
318 src/jpeg/jidctflt.o \
319 src/jpeg/jidctint.o \
320 src/jpeg/jidctred.o \
321 src/jpeg/jdsample.o \
328 OBJECTS = $(@GUIOBJS@) $(@COMMONOBJS@) $(@GENERICOBJS@) $(HTMLOBJS) $(UNIXOBJS) \
329 $(JPEGOBJS) $(PNGOBJS) $(ZLIBOBJS)
331 HEADERS = $(@GUIHEADERS@) $(HTML_HEADERS) $(UNIX_HEADERS) $(PROTOCOL_HEADERS) \
332 $(GENERIC_HEADERS) $(WX_HEADERS)
334 REQUIRED_DIRS = ./lib ./src ./src/common ./src/gtk ./src/motif \
335 ./src/generic ./src/unix ./src/motif/xmombo ./src/html \
336 ./src/zlib ./src/jpeg ./src/png
338 all: $(REQUIRED_DIRS) $(OBJECTS) @WX_TARGET_LIBRARY@ @WX_CREATE_LINKS@
340 $(REQUIRED_DIRS): $(WXDIR)/include/wx/defs.h $(WXDIR)/include/wx/object.h $(WXDIR)/include/wx/setup.h
341 @if test ! -d ./lib; then mkdir ./lib; fi
342 @if test ! -d ./src; then mkdir ./src; fi
343 @if test ! -d ./src/common; then mkdir ./src/common; fi
344 @if test ! -d ./src/gtk; then mkdir ./src/gtk; fi
345 @if test ! -d ./src/motif; then mkdir ./src/motif; fi
346 @if test ! -d ./src/motif/xmcombo; then mkdir ./src/motif/xmcombo; fi
347 @if test ! -d ./src/generic; then mkdir ./src/generic; fi
348 @if test ! -d ./src/unix; then mkdir ./src/unix; fi
349 @if test ! -d ./src/html; then mkdir ./src/html; fi
350 @if test ! -d ./src/png; then mkdir ./src/png; fi
351 @if test ! -d ./src/jpeg; then mkdir ./src/jpeg; fi
352 @if test ! -d ./src/zlib; then mkdir ./src/zlib; fi
354 @WX_LIBRARY_NAME_STATIC@: $(OBJECTS)
355 $(AR) $(AROPTIONS) ./lib/$@ $(OBJECTS)
358 @WX_LIBRARY_NAME_SHARED@: $(OBJECTS)
359 $(SHARED_LD) ./lib/$@ $(OBJECTS) $(EXTRALIBS)
361 CREATE_LINKS: $(OBJECTS)
362 @if test -e ./lib/@WX_LIBRARY_LINK1@; then rm -f ./lib/@WX_LIBRARY_LINK1@; fi
363 @if test -e ./lib/@WX_LIBRARY_LINK2@; then rm -f ./lib/@WX_LIBRARY_LINK2@; fi
364 @if test -e ./lib/@WX_LIBRARY_LINK3@; then rm -f ./lib/@WX_LIBRARY_LINK3@; fi
365 $(LN_S) @WX_TARGET_LIBRARY@ ./lib/@WX_LIBRARY_LINK1@
366 $(LN_S) @WX_TARGET_LIBRARY@ ./lib/@WX_LIBRARY_LINK2@
367 $(LN_S) @WX_TARGET_LIBRARY@ ./lib/@WX_LIBRARY_LINK3@
369 $(OBJECTS): $(WXDIR)/include/wx/defs.h $(WXDIR)/include/wx/object.h $(WXDIR)/include/wx/setup.h
371 parser.o: parser.c lexer.c
372 $(CCLEX) -c $(CFLAGS) -o $@ parser.c
374 parser.c: $(COMMDIR)/parser.y lexer.c
375 $(YACC) $(COMMDIR)/parser.y
376 @sed -e "s;$(COMMDIR)/y.tab.c;parser.y;g" < y.tab.c | \
377 sed -e "s/BUFSIZ/5000/g" | \
378 sed -e "s/YYLMAX 200/YYLMAX 5000/g" | \
379 sed -e "s/yy/PROIO_yy/g" | \
380 sed -e "s/input/PROIO_input/g" | \
381 sed -e "s/unput/PROIO_unput/g" > parser.c
384 lexer.c: $(COMMDIR)/lexer.l
385 $(LEX) $(COMMDIR)/lexer.l
386 @sed -e "s;$(COMMDIR)/lex.yy.c;lexer.l;g" < lex.yy.c | \
387 sed -e "s/yy/PROIO_yy/g" | \
388 sed -e "s/input/PROIO_input/g" | \
389 sed -e "s/unput/PROIO_unput/g" > lexer.c
393 @if test ! -e ./samples/dialog/dialog.cpp; \
394 then cp -f -r $(WXDIR)/samples .; \
397 install: $(top_builddir)/lib/@WX_TARGET_LIBRARY@ $(top_builddir)/wx-config $(top_builddir)/setup.h
399 $(INSTALL_SCRIPT) $(top_builddir)/wx-config $(bindir)/wx-config
400 $(INSTALL_PROGRAM) $(top_builddir)/lib/@WX_TARGET_LIBRARY@ $(libdir)/@WX_TARGET_LIBRARY@
402 @if test ! -d $(libdir)/wx; then mkdir $(libdir)/wx; fi
403 @if test ! -d $(libdir)/wx/include; then mkdir $(libdir)/wx/include; fi
404 @if test ! -d $(libdir)/wx/include/wx; then mkdir $(libdir)/wx/include/wx; fi
405 @if test ! -d $(libdir)/wx/include/wx/@TOOLKIT_DIR@; then mkdir $(libdir)/wx/include/wx/@TOOLKIT_DIR@; fi
406 $(INSTALL_DATA) $(top_builddir)/setup.h $(libdir)/wx/include/wx/@TOOLKIT_DIR@
408 @if test ! -d $(includedir)/wx; then mkdir $(includedir)/wx; fi
409 @if test ! -d $(includedir)/wx/gtk; then mkdir $(includedir)/wx/gtk; fi
410 @if test ! -d $(includedir)/wx/motif; then mkdir $(includedir)/wx/motif; fi
411 @if test ! -d $(includedir)/wx/html; then mkdir $(includedir)/wx/html; fi
412 @if test ! -d $(includedir)/wx/protocol; then mkdir $(includedir)/wx/protocol; fi
413 @if test ! -d $(includedir)/wx/unix; then mkdir $(includedir)/wx/unix; fi
414 @if test ! -d $(includedir)/wx/generic; then mkdir $(includedir)/wx/generic; fi
415 @list='$(HEADERS)'; for p in $$list; do \
416 echo '$(INSTALL_DATA) $(top_srcdir)/include/wx/$$p $(includedir)/wx/$$p;' \
417 $(INSTALL_DATA) $(top_srcdir)/include/wx/$$p $(includedir)/wx/$$p; \
421 rm -f $(bindir)/wx-config
422 rm -f $(libdir)/@WX_TARGET_LIBRARY@
423 rm -f -r -d $(libdir)/wx
424 rm -f -r -d $(includedir)/wx
429 rm -f ./src/motif/*.o
431 rm -f ./src/common/*.o
433 rm -f ./src/generic/*.o