]> git.saurik.com Git - wxWidgets.git/blame_incremental - samples/render/makefile.gcc
fixes for Metrowerks command line compiler (avoid redefining stuff already defined...
[wxWidgets.git] / samples / render / makefile.gcc
... / ...
CommitLineData
1# =========================================================================
2# This makefile was generated by
3# Bakefile 0.1.4 (http://bakefile.sourceforge.net)
4# Do not modify, all changes will be overwritten!
5# =========================================================================
6
7include ../../build/msw/config.gcc
8
9# -------------------------------------------------------------------------
10# Do not modify the rest of this file!
11# -------------------------------------------------------------------------
12
13### Variables: ###
14
15WX_RELEASE_NODOT = 25
16WX_VERSION_NODOT = $(WX_RELEASE_NODOT)2
17OBJS = \
18 gcc_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
19SETUPHDIR = \
20 $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)
21RENDER_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(GCCFLAGS) -DHAVE_W32API_H \
22 -D__WXMSW__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) $(__UNICODE_DEFINE_p) \
23 -I.\..\..\include -I$(SETUPHDIR) -Wall -I. $(__DLLFLAG_p) -I.\..\..\samples \
24 -DNOPCH $(__EXCEPTIONSFLAG) $(__EXCEPTIONSFLAG_0) $(CPPFLAGS) $(CXXFLAGS)
25RENDER_OBJECTS = \
26 $(OBJS)\render_sample_rc.o \
27 $(OBJS)\render_render.o
28RENDDLL_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(GCCFLAGS) -DHAVE_W32API_H \
29 -D__WXMSW__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) $(__UNICODE_DEFINE_p) \
30 -I.\..\..\include -I$(SETUPHDIR) -Wall -DWXUSINGDLL $(__EXCEPTIONSFLAG) \
31 $(__EXCEPTIONSFLAG_0) $(CPPFLAGS) $(CXXFLAGS)
32RENDDLL_OBJECTS = \
33 $(OBJS)\renddll_renddll.o
34
35### Conditionally set variables: ###
36
37ifeq ($(GCC_VERSION),2.95)
38GCCFLAGS = -fvtable-thunks
39endif
40ifeq ($(USE_GUI),0)
41PORTNAME = base
42endif
43ifeq ($(USE_GUI),1)
44PORTNAME = msw
45endif
46ifeq ($(BUILD),debug)
47ifeq ($(DEBUG_FLAG),default)
48WXDEBUGFLAG = d
49endif
50endif
51ifeq ($(DEBUG_FLAG),1)
52WXDEBUGFLAG = d
53endif
54ifeq ($(UNICODE),1)
55WXUNICODEFLAG = u
56endif
57ifeq ($(WXUNIV),1)
58WXUNIVNAME = univ
59endif
60ifeq ($(SHARED),1)
61WXDLLFLAG = dll
62endif
63ifeq ($(BUILD),debug)
64ifeq ($(UNICODE),0)
65PLUGINSUFFIX = d
66endif
67endif
68ifeq ($(BUILD),debug)
69ifeq ($(UNICODE),1)
70PLUGINSUFFIX = ud
71endif
72endif
73ifeq ($(BUILD),release)
74ifeq ($(UNICODE),0)
75PLUGINSUFFIX =
76endif
77endif
78ifeq ($(BUILD),release)
79ifeq ($(UNICODE),1)
80PLUGINSUFFIX = u
81endif
82endif
83ifeq ($(WXUNIV),1)
84__WXUNIV_DEFINE_p_1 = --define __WXUNIVERSAL__
85endif
86ifeq ($(BUILD),debug)
87ifeq ($(DEBUG_FLAG),default)
88__DEBUG_DEFINE_p_1 = --define __WXDEBUG__
89endif
90endif
91ifeq ($(DEBUG_FLAG),1)
92__DEBUG_DEFINE_p_1 = --define __WXDEBUG__
93endif
94ifeq ($(UNICODE),1)
95__UNICODE_DEFINE_p_1 = --define _UNICODE
96endif
97ifeq ($(SHARED),1)
98__DLLFLAG_p = -DWXUSINGDLL
99endif
100ifeq ($(SHARED),1)
101__DLLFLAG_p_1 = --define WXUSINGDLL
102endif
103ifeq ($(SHARED),1)
104__renddll___depname = \
105 $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(PLUGINSUFFIX)$(WX_VERSION_NODOT)_gcc.dll
106endif
107ifeq ($(BUILD),debug)
108__OPTIMIZEFLAG = -O0
109endif
110ifeq ($(BUILD),release)
111__OPTIMIZEFLAG = -O2
112endif
113ifeq ($(USE_EXCEPTIONS),0)
114__EXCEPTIONSFLAG = -fno-rtti
115endif
116ifeq ($(USE_EXCEPTIONS),1)
117__EXCEPTIONSFLAG =
118endif
119ifeq ($(USE_EXCEPTIONS),0)
120__EXCEPTIONSFLAG_0 = -fno-exceptions
121endif
122ifeq ($(USE_EXCEPTIONS),1)
123__EXCEPTIONSFLAG_0 =
124endif
125ifeq ($(WXUNIV),1)
126__WXUNIV_DEFINE_p = -D__WXUNIVERSAL__
127endif
128ifeq ($(BUILD),debug)
129ifeq ($(DEBUG_FLAG),default)
130__DEBUG_DEFINE_p = -D__WXDEBUG__
131endif
132endif
133ifeq ($(DEBUG_FLAG),1)
134__DEBUG_DEFINE_p = -D__WXDEBUG__
135endif
136ifeq ($(UNICODE),1)
137__UNICODE_DEFINE_p = -D_UNICODE
138endif
139ifeq ($(SHARED),0)
140LIBDIRNAME = .\..\..\lib\gcc_lib$(CFG)
141endif
142ifeq ($(SHARED),1)
143LIBDIRNAME = .\..\..\lib\gcc_dll$(CFG)
144endif
145ifeq ($(MONOLITHIC),0)
146__WXLIB_CORE_p = \
147 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core
148endif
149ifeq ($(MONOLITHIC),0)
150__WXLIB_BASE_p = \
151 -lwxbase$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
152endif
153ifeq ($(MONOLITHIC),1)
154__WXLIB_MONO_p = \
155 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
156endif
157ifeq ($(USE_GUI),1)
158__LIB_TIFF_p = -lwxtiff$(WXDEBUGFLAG)$(WX_RELEASE_NODOT)
159endif
160ifeq ($(USE_GUI),1)
161__LIB_JPEG_p = -lwxjpeg$(WXDEBUGFLAG)$(WX_RELEASE_NODOT)
162endif
163ifeq ($(USE_GUI),1)
164__LIB_PNG_p = -lwxpng$(WXDEBUGFLAG)$(WX_RELEASE_NODOT)
165endif
166ifeq ($(MSLU),1)
167__UNICOWS_LIB_p = -lunicows
168endif
169ifeq ($(BUILD),debug)
170ifeq ($(DEBUG_INFO),default)
171__DEBUGINFO = -g
172endif
173endif
174ifeq ($(BUILD),release)
175ifeq ($(DEBUG_INFO),default)
176__DEBUGINFO =
177endif
178endif
179ifeq ($(DEBUG_INFO),0)
180__DEBUGINFO =
181endif
182ifeq ($(DEBUG_INFO),1)
183__DEBUGINFO = -g
184endif
185
186
187all: $(OBJS)
188$(OBJS):
189 -if not exist $(OBJS) mkdir $(OBJS)
190
191### Targets: ###
192
193all: $(OBJS)\render.exe $(__renddll___depname)
194
195clean:
196 -if exist $(OBJS)\*.o del $(OBJS)\*.o
197 -if exist $(OBJS)\render.exe del $(OBJS)\render.exe
198 -if exist $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(PLUGINSUFFIX)$(WX_VERSION_NODOT)_gcc.dll del $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(PLUGINSUFFIX)$(WX_VERSION_NODOT)_gcc.dll
199
200$(OBJS)\render.exe: $(RENDER_OBJECTS) $(OBJS)\render_sample_rc.o
201 $(CXX) -o $@ $(RENDER_OBJECTS) $(LDFLAGS) $(__DEBUGINFO) -mthreads -L$(LIBDIRNAME) -Wl,--subsystem,windows -mwindows $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) -lwxzlib$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) -lwxregex$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) -lwxexpat$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) $(__UNICOWS_LIB_p) -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32 -lodbc32
202
203ifeq ($(SHARED),1)
204$(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(PLUGINSUFFIX)$(WX_VERSION_NODOT)_gcc.dll: $(RENDDLL_OBJECTS)
205 $(CXX) -shared -o $@ $(RENDDLL_OBJECTS) $(LDFLAGS) $(__DEBUGINFO) -mthreads -L$(LIBDIRNAME) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) -lwxzlib$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) -lwxregex$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) -lwxexpat$(WXDEBUGFLAG)$(WX_RELEASE_NODOT) $(__UNICOWS_LIB_p) -lkernel32 -luser32 -lgdi32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lwsock32 -lodbc32
206endif
207
208$(OBJS)\render_sample_rc.o: ./../../samples/sample.rc
209 windres --use-temp-file -i$< -o$@ --define __WXMSW__ $(__WXUNIV_DEFINE_p_1) $(__DEBUG_DEFINE_p_1) $(__UNICODE_DEFINE_p_1) --include-dir ./../../include --include-dir $(SETUPHDIR) --include-dir . $(__DLLFLAG_p_1) --include-dir ./../../samples
210
211$(OBJS)\render_render.o: ./render.cpp
212 $(CXX) -c -o $@ $(RENDER_CXXFLAGS) $<
213
214$(OBJS)\renddll_renddll.o: ./renddll.cpp
215 $(CXX) -c -o $@ $(RENDDLL_CXXFLAGS) $<
216
217.PHONY: all clean