]> git.saurik.com Git - wxWidgets.git/blame - tests/benchmarks/makefile.gcc
Make TOOLKIT variable constant in MSW makefiles.
[wxWidgets.git] / tests / benchmarks / makefile.gcc
CommitLineData
a7ebaf0d
KO
1# =========================================================================\r
2# This makefile was generated by\r
00eef16d 3# Bakefile 0.2.9 (http://www.bakefile.org)\r
a7ebaf0d
KO
4# Do not modify, all changes will be overwritten!\r
5# =========================================================================\r
6\r
7include ../../build/msw/config.gcc\r
8\r
9# -------------------------------------------------------------------------\r
10# Do not modify the rest of this file!\r
11# -------------------------------------------------------------------------\r
12\r
13### Variables: ###\r
14\r
15CPPDEPS = -MT$@ -MF$@.d -MD -MP\r
16WX_RELEASE_NODOT = 29\r
17COMPILER_PREFIX = gcc\r
18OBJS = \\r
14b682f7
VZ
19 $(COMPILER_PREFIX)$(COMPILER_VERSION)_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
20LIBDIRNAME = \
21 .\..\..\lib\$(COMPILER_PREFIX)$(COMPILER_VERSION)_$(LIBTYPE_SUFFIX)$(CFG)
a7ebaf0d
KO
22SETUPHDIR = \\r
23 $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)\r
7b363ab6
VZ
24BENCH_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) $(GCCFLAGS) \
25 -DHAVE_W32API_H -D__WX$(TOOLKIT)__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) \
26 $(__NDEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) \
27 $(__THREAD_DEFINE_p) $(__UNICODE_DEFINE_p) $(__MSLU_DEFINE_p) \
28 -I$(SETUPHDIR) -I.\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES) -W -Wall \
29 -I. $(__DLLFLAG_p) -DwxUSE_GUI=0 $(__RTTIFLAG) $(__EXCEPTIONSFLAG) \
30 -Wno-ctor-dtor-privacy $(CXXFLAGS_GTK_WINDOWS_GCC) $(CPPFLAGS) $(CXXFLAGS)
a7ebaf0d
KO
31BENCH_OBJECTS = \\r
32 $(OBJS)\bench_bench.o \\r
bf0f3b26 33 $(OBJS)\bench_datetime.o \\r
a7ebaf0d
KO
34 $(OBJS)\bench_htmlpars.o \\r
35 $(OBJS)\bench_htmltag.o \\r
36 $(OBJS)\bench_ipcclient.o \\r
f7f7b59a 37 $(OBJS)\bench_log.o \\r
a7ebaf0d
KO
38 $(OBJS)\bench_mbconv.o \\r
39 $(OBJS)\bench_strings.o \\r
40 $(OBJS)\bench_tls.o \\r
41 $(OBJS)\bench_printfbench.o\r
7b363ab6
VZ
42BENCH_GUI_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) \
43 $(GCCFLAGS) -DHAVE_W32API_H -D__WX$(TOOLKIT)__ $(__WXUNIV_DEFINE_p) \
44 $(__DEBUG_DEFINE_p) $(__NDEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) \
45 $(__RTTI_DEFINE_p) $(__THREAD_DEFINE_p) $(__UNICODE_DEFINE_p) \
46 $(__MSLU_DEFINE_p) -I$(SETUPHDIR) -I.\..\..\include \
47 $(____CAIRO_INCLUDEDIR_FILENAMES) -W -Wall -I. $(__DLLFLAG_p) \
48 -I.\..\..\samples -DNOPCH $(__RTTIFLAG) $(__EXCEPTIONSFLAG) \
49 -Wno-ctor-dtor-privacy $(CXXFLAGS_GTK_WINDOWS_GCC) $(CPPFLAGS) $(CXXFLAGS)
50BENCH_GUI_OBJECTS = \
51 $(OBJS)\bench_gui_sample_rc.o \
52 $(OBJS)\bench_gui_bench.o \
53 $(OBJS)\bench_gui_image.o
a7ebaf0d
KO
54\r
55### Conditionally set variables: ###\r
56\r
22a3b6e4
VZ
57ifeq ($(TOOLKIT),GTK)
58WIN32_TOOLKIT_LOWERCASE = gtk
59endif
60ifeq ($(TOOLKIT),MSW)
61WIN32_TOOLKIT_LOWERCASE = msw
62endif
a7ebaf0d
KO
63ifeq ($(GCC_VERSION),2.95)\r
64GCCFLAGS = -fvtable-thunks\r
65endif\r
66ifeq ($(USE_GUI),0)\r
67PORTNAME = base\r
68endif\r
69ifeq ($(USE_GUI),1)\r
22a3b6e4
VZ
70PORTNAME = $(WIN32_TOOLKIT_LOWERCASE)$(TOOLKIT_VERSION)
71endif
72ifeq ($(TOOLKIT),MAC)
73WXBASEPORT = _carbon
74endif
14b682f7
VZ
75ifeq ($(OFFICIAL_BUILD),1)
76COMPILER_VERSION = ERROR-COMPILER-VERSION-MUST-BE-SET-FOR-OFFICIAL-BUILD
22a3b6e4 77endif\r
a7ebaf0d
KO
78ifeq ($(BUILD),debug)\r
79WXDEBUGFLAG = d\r
80endif\r
81ifeq ($(UNICODE),1)\r
82WXUNICODEFLAG = u\r
83endif\r
84ifeq ($(WXUNIV),1)\r
85WXUNIVNAME = univ\r
86endif\r
87ifeq ($(SHARED),1)\r
88WXDLLFLAG = dll\r
89endif\r
90ifeq ($(SHARED),0)\r
91LIBTYPE_SUFFIX = lib\r
92endif\r
93ifeq ($(SHARED),1)\r
94LIBTYPE_SUFFIX = dll\r
95endif\r
96ifeq ($(MONOLITHIC),0)\r
97EXTRALIBS_FOR_BASE = \r
98endif\r
99ifeq ($(MONOLITHIC),1)\r
51ec29ea 100EXTRALIBS_FOR_BASE = \r
a7ebaf0d 101endif\r
22a3b6e4
VZ
102ifeq ($(TOOLKIT),GTK)
103CXXFLAGS_GTK_WINDOWS_GCC = -mms-bitfields
104endif
7b363ab6
VZ
105ifeq ($(TOOLKIT),GTK)
106ifeq ($(TOOLKIT_VERSION),2)
107LIB_GTK = gtk-win32-2.0.lib gdk-win32-2.0.lib pangocairo-1.0.lib \
108 gdk_pixbuf-2.0.lib cairo.lib pango-1.0.lib gobject-2.0.lib gthread-2.0.lib \
109 glib-2.0.lib
110endif
111endif
112ifeq ($(MONOLITHIC),0)
113__WXLIB_NET_p = \
114 -lwxbase$(WXBASEPORT)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_net
115endif
116ifeq ($(MONOLITHIC),1)
117__LIB_PNG_IF_MONO_p = $(__LIB_PNG_p)
118endif
119ifeq ($(USE_GUI),1)
120__bench_gui___depname = $(OBJS)\bench_gui.exe
121endif
122ifeq ($(WXUNIV),1)
123__WXUNIV_DEFINE_p_3 = --define __WXUNIVERSAL__
124endif
125ifeq ($(DEBUG_FLAG),0)
126__DEBUG_DEFINE_p_3 = --define wxDEBUG_LEVEL=0
127endif
128ifeq ($(BUILD),release)
129__NDEBUG_DEFINE_p_3 = --define NDEBUG
130endif
131ifeq ($(USE_EXCEPTIONS),0)
132__EXCEPTIONS_DEFINE_p_3 = --define wxNO_EXCEPTIONS
133endif
134ifeq ($(USE_RTTI),0)
135__RTTI_DEFINE_p_3 = --define wxNO_RTTI
136endif
137ifeq ($(USE_THREADS),0)
138__THREAD_DEFINE_p_3 = --define wxNO_THREADS
139endif
140ifeq ($(UNICODE),0)
141__UNICODE_DEFINE_p_3 = --define wxUSE_UNICODE=0
142endif
143ifeq ($(UNICODE),1)
144__UNICODE_DEFINE_p_3 = --define _UNICODE
145endif
146ifeq ($(MSLU),1)
147__MSLU_DEFINE_p_3 = --define wxUSE_UNICODE_MSLU=1
148endif
149ifeq ($(USE_CAIRO),1)
150__CAIRO_INCLUDEDIR_p_1 = --include-dir $(CAIRO_ROOT)/include/cairo
151endif
152ifeq ($(SHARED),1)
153__DLLFLAG_p_3 = --define WXUSINGDLL
154endif
155ifeq ($(MONOLITHIC),0)
156__WXLIB_CORE_p = \
157 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core
158endif
159ifeq ($(USE_GUI),1)
160__LIB_TIFF_p = -lwxtiff$(WXDEBUGFLAG)
161endif
162ifeq ($(USE_GUI),1)
163__LIB_JPEG_p = -lwxjpeg$(WXDEBUGFLAG)
164endif
a7ebaf0d 165ifeq ($(BUILD),debug)\r
7b363ab6 166__OPTIMIZEFLAG = -O0
a7ebaf0d
KO
167endif\r
168ifeq ($(BUILD),release)\r
7b363ab6 169__OPTIMIZEFLAG = -O2
a7ebaf0d
KO
170endif\r
171ifeq ($(USE_RTTI),0)\r
7b363ab6 172__RTTIFLAG = -fno-rtti
a7ebaf0d
KO
173endif\r
174ifeq ($(USE_RTTI),1)\r
7b363ab6 175__RTTIFLAG =
a7ebaf0d
KO
176endif\r
177ifeq ($(USE_EXCEPTIONS),0)\r
7b363ab6 178__EXCEPTIONSFLAG = -fno-exceptions
a7ebaf0d
KO
179endif\r
180ifeq ($(USE_EXCEPTIONS),1)\r
7b363ab6 181__EXCEPTIONSFLAG =
a7ebaf0d
KO
182endif\r
183ifeq ($(WXUNIV),1)\r
184__WXUNIV_DEFINE_p = -D__WXUNIVERSAL__\r
185endif\r
186ifeq ($(DEBUG_FLAG),0)\r
187__DEBUG_DEFINE_p = -DwxDEBUG_LEVEL=0\r
188endif\r
da8b1d4b
KO
189ifeq ($(BUILD),release)\r
190__NDEBUG_DEFINE_p = -DNDEBUG\r
191endif\r
a7ebaf0d
KO
192ifeq ($(USE_EXCEPTIONS),0)\r
193__EXCEPTIONS_DEFINE_p = -DwxNO_EXCEPTIONS\r
194endif\r
195ifeq ($(USE_RTTI),0)\r
196__RTTI_DEFINE_p = -DwxNO_RTTI\r
197endif\r
198ifeq ($(USE_THREADS),0)\r
199__THREAD_DEFINE_p = -DwxNO_THREADS\r
200endif\r
201ifeq ($(UNICODE),0)\r
202__UNICODE_DEFINE_p = -DwxUSE_UNICODE=0\r
203endif\r
204ifeq ($(UNICODE),1)\r
205__UNICODE_DEFINE_p = -D_UNICODE\r
206endif\r
207ifeq ($(MSLU),1)\r
208__MSLU_DEFINE_p = -DwxUSE_UNICODE_MSLU=1\r
209endif\r
f82b7036 210ifeq ($(USE_CAIRO),1)\r
7b363ab6 211____CAIRO_INCLUDEDIR_FILENAMES = -I$(CAIRO_ROOT)\include\cairo
f82b7036 212endif\r
a7ebaf0d
KO
213ifeq ($(SHARED),1)\r
214__DLLFLAG_p = -DWXUSINGDLL\r
215endif\r
216ifeq ($(MONOLITHIC),0)\r
a7ebaf0d 217__WXLIB_BASE_p = \\r
22a3b6e4 218 -lwxbase$(WXBASEPORT)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
a7ebaf0d
KO
219endif\r
220ifeq ($(MONOLITHIC),1)\r
221__WXLIB_MONO_p = \\r
222 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)\r
223endif\r
57c74474
VZ
224ifeq ($(USE_GUI),1)\r
225__LIB_PNG_p = -lwxpng$(WXDEBUGFLAG)\r
226endif\r
a7ebaf0d
KO
227ifeq ($(MSLU),1)\r
228__UNICOWS_LIB_p = -lunicows\r
229endif\r
f82b7036
KO
230ifeq ($(USE_CAIRO),1)\r
231__CAIRO_LIB_p = -lcairo\r
232endif\r
233ifeq ($(USE_CAIRO),1)\r
7b363ab6 234____CAIRO_LIBDIR_FILENAMES = -L$(CAIRO_ROOT)\lib
f82b7036 235endif\r
a7ebaf0d
KO
236ifeq ($(BUILD),debug)\r
237ifeq ($(DEBUG_INFO),default)\r
238__DEBUGINFO = -g\r
239endif\r
240endif\r
241ifeq ($(BUILD),release)\r
242ifeq ($(DEBUG_INFO),default)\r
243__DEBUGINFO = \r
244endif\r
245endif\r
246ifeq ($(DEBUG_INFO),0)\r
247__DEBUGINFO = \r
248endif\r
249ifeq ($(DEBUG_INFO),1)\r
250__DEBUGINFO = -g\r
251endif\r
252ifeq ($(USE_THREADS),0)\r
253__THREADSFLAG = \r
254endif\r
255ifeq ($(USE_THREADS),1)\r
256__THREADSFLAG = -mthreads\r
257endif\r
258\r
259\r
260all: $(OBJS)\r
261$(OBJS):\r
262 -if not exist $(OBJS) mkdir $(OBJS)\r
263\r
264### Targets: ###\r
265\r
7b363ab6 266all: $(OBJS)\bench.exe data $(__bench_gui___depname) data-image
a7ebaf0d
KO
267\r
268clean: \r
269 -if exist $(OBJS)\*.o del $(OBJS)\*.o\r
270 -if exist $(OBJS)\*.d del $(OBJS)\*.d\r
271 -if exist $(OBJS)\bench.exe del $(OBJS)\bench.exe\r
7b363ab6 272 -if exist $(OBJS)\bench_gui.exe del $(OBJS)\bench_gui.exe
a7ebaf0d
KO
273\r
274$(OBJS)\bench.exe: $(BENCH_OBJECTS)\r
7b363ab6 275 $(CXX) -o $@ $(BENCH_OBJECTS) $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) $(____CAIRO_LIBDIR_FILENAMES) $(LDFLAGS) $(__WXLIB_NET_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_PNG_IF_MONO_p) -lwxzlib$(WXDEBUGFLAG) -lwxregex$(WXUNICODEFLAG)$(WXDEBUGFLAG) -lwxexpat$(WXDEBUGFLAG) $(EXTRALIBS_FOR_BASE) $(__UNICOWS_LIB_p) $(__CAIRO_LIB_p) -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32 -lwininet
a7ebaf0d
KO
276\r
277data: \r
278 if not exist $(OBJS) mkdir $(OBJS)\r
279 for %%f in (htmltest.html) do if not exist $(OBJS)\%%f copy .\%%f $(OBJS)\r
280\r
7b363ab6
VZ
281ifeq ($(USE_GUI),1)
282$(OBJS)\bench_gui.exe: $(BENCH_GUI_OBJECTS) $(OBJS)\bench_gui_sample_rc.o
283 $(CXX) -o $@ $(BENCH_GUI_OBJECTS) $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) $(____CAIRO_LIBDIR_FILENAMES) $(LDFLAGS) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) $(LIB_GTK) -lwxzlib$(WXDEBUGFLAG) -lwxregex$(WXUNICODEFLAG)$(WXDEBUGFLAG) -lwxexpat$(WXDEBUGFLAG) $(EXTRALIBS_FOR_BASE) $(__UNICOWS_LIB_p) $(__CAIRO_LIB_p) -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32 -lwininet
284endif
285
286data-image:
287 if not exist $(OBJS) mkdir $(OBJS)
288 for %%f in (../../samples/image/horse.bmp ../../samples/image/horse.jpg ../../samples/image/horse.png ../../samples/image/horse.tif) do if not exist $(OBJS)\%%f copy .\%%f $(OBJS)
289
a7ebaf0d
KO
290$(OBJS)\bench_bench.o: ./bench.cpp\r
291 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
292\r
bf0f3b26
VZ
293$(OBJS)\bench_datetime.o: ./datetime.cpp\r
294 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
295\r
a7ebaf0d
KO
296$(OBJS)\bench_htmlpars.o: ./htmlparser/htmlpars.cpp\r
297 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
298\r
299$(OBJS)\bench_htmltag.o: ./htmlparser/htmltag.cpp\r
300 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
301\r
302$(OBJS)\bench_ipcclient.o: ./ipcclient.cpp\r
303 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
304\r
f7f7b59a
VZ
305$(OBJS)\bench_log.o: ./log.cpp\r
306 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
307\r
a7ebaf0d
KO
308$(OBJS)\bench_mbconv.o: ./mbconv.cpp\r
309 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
310\r
311$(OBJS)\bench_strings.o: ./strings.cpp\r
312 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
313\r
314$(OBJS)\bench_tls.o: ./tls.cpp\r
315 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
316\r
317$(OBJS)\bench_printfbench.o: ./printfbench.cpp\r
318 $(CXX) -c -o $@ $(BENCH_CXXFLAGS) $(CPPDEPS) $<\r
319\r
7b363ab6
VZ
320$(OBJS)\bench_gui_sample_rc.o: ./../../samples/sample.rc
321 windres --use-temp-file -i$< -o$@ --define __WX$(TOOLKIT)__ $(__WXUNIV_DEFINE_p_3) $(__DEBUG_DEFINE_p_3) $(__NDEBUG_DEFINE_p_3) $(__EXCEPTIONS_DEFINE_p_3) $(__RTTI_DEFINE_p_3) $(__THREAD_DEFINE_p_3) $(__UNICODE_DEFINE_p_3) $(__MSLU_DEFINE_p_3) --include-dir $(SETUPHDIR) --include-dir ./../../include $(__CAIRO_INCLUDEDIR_p_1) --include-dir . $(__DLLFLAG_p_3) --include-dir ./../../samples --define NOPCH
322
323$(OBJS)\bench_gui_bench.o: ./bench.cpp
324 $(CXX) -c -o $@ $(BENCH_GUI_CXXFLAGS) $(CPPDEPS) $<
325
326$(OBJS)\bench_gui_image.o: ./image.cpp
327 $(CXX) -c -o $@ $(BENCH_GUI_CXXFLAGS) $(CPPDEPS) $<
328
329.PHONY: all clean data data-image
a7ebaf0d
KO
330\r
331\r
332SHELL := $(COMSPEC)\r
333\r
334# Dependencies tracking:\r
335-include $(OBJS)/*.d\r