]> git.saurik.com Git - wxWidgets.git/blob - samples/render/makefile.gcc
Avoid CRT deprecation warnings for MSVC build using makefiles too.
[wxWidgets.git] / samples / render / makefile.gcc
1 # =========================================================================
2 # This makefile was generated by
3 # Bakefile 0.2.9 (http://www.bakefile.org)
4 # Do not modify, all changes will be overwritten!
5 # =========================================================================
6
7 include ../../build/msw/config.gcc
8
9 # -------------------------------------------------------------------------
10 # Do not modify the rest of this file!
11 # -------------------------------------------------------------------------
12
13 ### Variables: ###
14
15 CPPDEPS = -MT$@ -MF$@.d -MD -MP
16 WX_RELEASE_NODOT = 29
17 WX_VERSION_NODOT = $(WX_RELEASE_NODOT)4
18 COMPILER_PREFIX = gcc
19 OBJS = \
20 $(COMPILER_PREFIX)_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
21 LIBDIRNAME = .\..\..\lib\$(COMPILER_PREFIX)_$(LIBTYPE_SUFFIX)$(CFG)
22 SETUPHDIR = \
23 $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)
24 RENDER_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) $(GCCFLAGS) \
25 -DHAVE_W32API_H -D__WXMSW__ $(__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) -I.\..\..\samples -DNOPCH $(__RTTIFLAG) \
30 $(__EXCEPTIONSFLAG) -Wno-ctor-dtor-privacy $(CPPFLAGS) $(CXXFLAGS)
31 RENDER_OBJECTS = \
32 $(OBJS)\render_sample_rc.o \
33 $(OBJS)\render_render.o
34 RENDDLL_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) \
35 $(GCCFLAGS) -DHAVE_W32API_H -D__WXMSW__ $(__WXUNIV_DEFINE_p) \
36 $(__DEBUG_DEFINE_p) $(__NDEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) \
37 $(__RTTI_DEFINE_p) $(__THREAD_DEFINE_p) $(__UNICODE_DEFINE_p) \
38 $(__MSLU_DEFINE_p) -I$(SETUPHDIR) -I.\..\..\include \
39 $(____CAIRO_INCLUDEDIR_FILENAMES) -W -Wall -DWXUSINGDLL $(__RTTIFLAG) \
40 $(__EXCEPTIONSFLAG) -Wno-ctor-dtor-privacy $(CPPFLAGS) $(CXXFLAGS)
41 RENDDLL_OBJECTS = \
42 $(OBJS)\renddll_renddll.o
43
44 ### Conditionally set variables: ###
45
46 ifeq ($(GCC_VERSION),2.95)
47 GCCFLAGS = -fvtable-thunks
48 endif
49 ifeq ($(USE_GUI),0)
50 PORTNAME = base
51 endif
52 ifeq ($(USE_GUI),1)
53 PORTNAME = msw
54 endif
55 ifeq ($(BUILD),debug)
56 WXDEBUGFLAG = d
57 endif
58 ifeq ($(UNICODE),1)
59 WXUNICODEFLAG = u
60 endif
61 ifeq ($(WXUNIV),1)
62 WXUNIVNAME = univ
63 endif
64 ifeq ($(SHARED),1)
65 WXDLLFLAG = dll
66 endif
67 ifeq ($(SHARED),0)
68 LIBTYPE_SUFFIX = lib
69 endif
70 ifeq ($(SHARED),1)
71 LIBTYPE_SUFFIX = dll
72 endif
73 ifeq ($(MONOLITHIC),0)
74 EXTRALIBS_FOR_BASE =
75 endif
76 ifeq ($(MONOLITHIC),1)
77 EXTRALIBS_FOR_BASE =
78 endif
79 ifeq ($(WXUNIV),1)
80 __WXUNIV_DEFINE_p_1 = --define __WXUNIVERSAL__
81 endif
82 ifeq ($(DEBUG_FLAG),0)
83 __DEBUG_DEFINE_p_1 = --define wxDEBUG_LEVEL=0
84 endif
85 ifeq ($(BUILD),release)
86 __NDEBUG_DEFINE_p_1 = --define NDEBUG
87 endif
88 ifeq ($(USE_EXCEPTIONS),0)
89 __EXCEPTIONS_DEFINE_p_1 = --define wxNO_EXCEPTIONS
90 endif
91 ifeq ($(USE_RTTI),0)
92 __RTTI_DEFINE_p_1 = --define wxNO_RTTI
93 endif
94 ifeq ($(USE_THREADS),0)
95 __THREAD_DEFINE_p_1 = --define wxNO_THREADS
96 endif
97 ifeq ($(UNICODE),0)
98 __UNICODE_DEFINE_p_1 = --define wxUSE_UNICODE=0
99 endif
100 ifeq ($(UNICODE),1)
101 __UNICODE_DEFINE_p_1 = --define _UNICODE
102 endif
103 ifeq ($(MSLU),1)
104 __MSLU_DEFINE_p_1 = --define wxUSE_UNICODE_MSLU=1
105 endif
106 ifeq ($(USE_CAIRO),1)
107 __CAIRO_INCLUDEDIR_p = --include-dir $(CAIRO_ROOT)/include/cairo
108 endif
109 ifeq ($(SHARED),1)
110 __DLLFLAG_p = -DWXUSINGDLL
111 endif
112 ifeq ($(SHARED),1)
113 __DLLFLAG_p_1 = --define WXUSINGDLL
114 endif
115 ifeq ($(SHARED),1)
116 __renddll___depname = \
117 $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_VERSION_NODOT)_gcc.dll
118 endif
119 ifeq ($(BUILD),debug)
120 __OPTIMIZEFLAG = -O0
121 endif
122 ifeq ($(BUILD),release)
123 __OPTIMIZEFLAG = -O2
124 endif
125 ifeq ($(USE_RTTI),0)
126 __RTTIFLAG = -fno-rtti
127 endif
128 ifeq ($(USE_RTTI),1)
129 __RTTIFLAG =
130 endif
131 ifeq ($(USE_EXCEPTIONS),0)
132 __EXCEPTIONSFLAG = -fno-exceptions
133 endif
134 ifeq ($(USE_EXCEPTIONS),1)
135 __EXCEPTIONSFLAG =
136 endif
137 ifeq ($(WXUNIV),1)
138 __WXUNIV_DEFINE_p = -D__WXUNIVERSAL__
139 endif
140 ifeq ($(DEBUG_FLAG),0)
141 __DEBUG_DEFINE_p = -DwxDEBUG_LEVEL=0
142 endif
143 ifeq ($(BUILD),release)
144 __NDEBUG_DEFINE_p = -DNDEBUG
145 endif
146 ifeq ($(USE_EXCEPTIONS),0)
147 __EXCEPTIONS_DEFINE_p = -DwxNO_EXCEPTIONS
148 endif
149 ifeq ($(USE_RTTI),0)
150 __RTTI_DEFINE_p = -DwxNO_RTTI
151 endif
152 ifeq ($(USE_THREADS),0)
153 __THREAD_DEFINE_p = -DwxNO_THREADS
154 endif
155 ifeq ($(UNICODE),0)
156 __UNICODE_DEFINE_p = -DwxUSE_UNICODE=0
157 endif
158 ifeq ($(UNICODE),1)
159 __UNICODE_DEFINE_p = -D_UNICODE
160 endif
161 ifeq ($(MSLU),1)
162 __MSLU_DEFINE_p = -DwxUSE_UNICODE_MSLU=1
163 endif
164 ifeq ($(USE_CAIRO),1)
165 ____CAIRO_INCLUDEDIR_FILENAMES = -I$(CAIRO_ROOT)\include\cairo
166 endif
167 ifeq ($(MONOLITHIC),0)
168 __WXLIB_CORE_p = \
169 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core
170 endif
171 ifeq ($(MONOLITHIC),0)
172 __WXLIB_BASE_p = \
173 -lwxbase$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
174 endif
175 ifeq ($(MONOLITHIC),1)
176 __WXLIB_MONO_p = \
177 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
178 endif
179 ifeq ($(USE_GUI),1)
180 __LIB_TIFF_p = -lwxtiff$(WXDEBUGFLAG)
181 endif
182 ifeq ($(USE_GUI),1)
183 __LIB_JPEG_p = -lwxjpeg$(WXDEBUGFLAG)
184 endif
185 ifeq ($(USE_GUI),1)
186 __LIB_PNG_p = -lwxpng$(WXDEBUGFLAG)
187 endif
188 ifeq ($(MSLU),1)
189 __UNICOWS_LIB_p = -lunicows
190 endif
191 ifeq ($(USE_CAIRO),1)
192 __CAIRO_LIB_p = -lcairo
193 endif
194 ifeq ($(USE_CAIRO),1)
195 ____CAIRO_LIBDIR_FILENAMES = -L$(CAIRO_ROOT)\lib
196 endif
197 ifeq ($(BUILD),debug)
198 ifeq ($(DEBUG_INFO),default)
199 __DEBUGINFO = -g
200 endif
201 endif
202 ifeq ($(BUILD),release)
203 ifeq ($(DEBUG_INFO),default)
204 __DEBUGINFO =
205 endif
206 endif
207 ifeq ($(DEBUG_INFO),0)
208 __DEBUGINFO =
209 endif
210 ifeq ($(DEBUG_INFO),1)
211 __DEBUGINFO = -g
212 endif
213 ifeq ($(USE_THREADS),0)
214 __THREADSFLAG =
215 endif
216 ifeq ($(USE_THREADS),1)
217 __THREADSFLAG = -mthreads
218 endif
219
220
221 all: $(OBJS)
222 $(OBJS):
223 -if not exist $(OBJS) mkdir $(OBJS)
224
225 ### Targets: ###
226
227 all: $(OBJS)\render.exe $(__renddll___depname)
228
229 clean:
230 -if exist $(OBJS)\*.o del $(OBJS)\*.o
231 -if exist $(OBJS)\*.d del $(OBJS)\*.d
232 -if exist $(OBJS)\render.exe del $(OBJS)\render.exe
233 -if exist $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_VERSION_NODOT)_gcc.dll del $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_VERSION_NODOT)_gcc.dll
234
235 $(OBJS)\render.exe: $(RENDER_OBJECTS) $(OBJS)\render_sample_rc.o
236 $(CXX) -o $@ $(RENDER_OBJECTS) $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) -Wl,--subsystem,windows -mwindows $(____CAIRO_LIBDIR_FILENAMES) $(LDFLAGS) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_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
237
238 ifeq ($(SHARED),1)
239 $(OBJS)\renddll_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_VERSION_NODOT)_gcc.dll: $(RENDDLL_OBJECTS)
240 $(CXX) $(LINK_MODULE_FLAGS) -fPIC -o $@ $(RENDDLL_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) -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
241 endif
242
243 $(OBJS)\render_sample_rc.o: ./../../samples/sample.rc
244 windres --use-temp-file -i$< -o$@ --define __WXMSW__ $(__WXUNIV_DEFINE_p_1) $(__DEBUG_DEFINE_p_1) $(__NDEBUG_DEFINE_p_1) $(__EXCEPTIONS_DEFINE_p_1) $(__RTTI_DEFINE_p_1) $(__THREAD_DEFINE_p_1) $(__UNICODE_DEFINE_p_1) $(__MSLU_DEFINE_p_1) --include-dir $(SETUPHDIR) --include-dir ./../../include $(__CAIRO_INCLUDEDIR_p) --include-dir . $(__DLLFLAG_p_1) --include-dir ./../../samples --define NOPCH
245
246 $(OBJS)\render_render.o: ./render.cpp
247 $(CXX) -c -o $@ $(RENDER_CXXFLAGS) $(CPPDEPS) $<
248
249 $(OBJS)\renddll_renddll.o: ./renddll.cpp
250 $(CXX) -c -o $@ $(RENDDLL_CXXFLAGS) $(CPPDEPS) $<
251
252 .PHONY: all clean
253
254
255 SHELL := $(COMSPEC)
256
257 # Dependencies tracking:
258 -include $(OBJS)/*.d