]> git.saurik.com Git - wxWidgets.git/blame - samples/dll/makefile.gcc
wxMessageBox off the main thread lost result code.
[wxWidgets.git] / samples / dll / makefile.gcc
CommitLineData
61aba460
VS
1# =========================================================================\r
2# This makefile was generated by\r
00eef16d 3# Bakefile 0.2.9 (http://www.bakefile.org)\r
61aba460
VS
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
e7bdf0ac 16WX_RELEASE_NODOT = 30\r
61aba460
VS
17COMPILER_PREFIX = gcc\r
18OBJS = \\r
4863951a
VS
19 $(COMPILER_PREFIX)$(COMPILER_VERSION)_$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)\r
20LIBDIRNAME = \\r
21 .\..\..\lib\$(COMPILER_PREFIX)$(COMPILER_VERSION)_$(LIBTYPE_SUFFIX)$(CFG)\r
61aba460
VS
22SETUPHDIR = \\r
23 $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)\r
24MY_DLL_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) $(GCCFLAGS) \\r
bed99c22 25 -DHAVE_W32API_H -D__WXMSW__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) \\r
da8b1d4b
KO
26 $(__NDEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) \\r
27 $(__THREAD_DEFINE_p) $(__UNICODE_DEFINE_p) $(__MSLU_DEFINE_p) \\r
b796194b
VS
28 -I$(SETUPHDIR) -I.\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES) -W -Wall \\r
29 $(__DLLFLAG_p) -DMY_DLL_BUILDING -I. $(__RTTIFLAG) $(__EXCEPTIONSFLAG) \\r
bed99c22 30 -Wno-ctor-dtor-privacy $(CPPFLAGS) $(CXXFLAGS)\r
61aba460
VS
31MY_DLL_OBJECTS = \\r
32 $(OBJS)\my_dll_my_dll.o\r
33WX_EXE_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) $(GCCFLAGS) \\r
bed99c22 34 -DHAVE_W32API_H -D__WXMSW__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) \\r
da8b1d4b
KO
35 $(__NDEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) \\r
36 $(__THREAD_DEFINE_p) $(__UNICODE_DEFINE_p) $(__MSLU_DEFINE_p) \\r
b796194b
VS
37 -I$(SETUPHDIR) -I.\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES) -W -Wall \\r
38 -I. $(__DLLFLAG_p) -I.\..\..\samples -DNOPCH $(__RTTIFLAG) \\r
bed99c22 39 $(__EXCEPTIONSFLAG) -Wno-ctor-dtor-privacy $(CPPFLAGS) $(CXXFLAGS)\r
61aba460
VS
40WX_EXE_OBJECTS = \\r
41 $(OBJS)\wx_exe_sample_rc.o \\r
1ffe64ef 42 $(OBJS)\wx_exe_wx_exe.o\r
da8b1d4b
KO
43SDK_EXE_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG) $(__THREADSFLAG) \\r
44 $(GCCFLAGS) -DHAVE_W32API_H $(__RTTIFLAG) $(__EXCEPTIONSFLAG) $(CPPFLAGS) \\r
45 $(CXXFLAGS)\r
46SDK_EXE_OBJECTS = \\r
47 $(OBJS)\sdk_exe_sdk_exe.o\r
61aba460
VS
48\r
49### Conditionally set variables: ###\r
50\r
51ifeq ($(GCC_VERSION),2.95)\r
52GCCFLAGS = -fvtable-thunks\r
53endif\r
54ifeq ($(USE_GUI),0)\r
55PORTNAME = base\r
56endif\r
57ifeq ($(USE_GUI),1)\r
bed99c22 58PORTNAME = msw$(TOOLKIT_VERSION)\r
4863951a
VS
59endif\r
60ifeq ($(OFFICIAL_BUILD),1)\r
61COMPILER_VERSION = ERROR-COMPILER-VERSION-MUST-BE-SET-FOR-OFFICIAL-BUILD\r
22a3b6e4 62endif\r
61aba460
VS
63ifeq ($(BUILD),debug)\r
64WXDEBUGFLAG = d\r
65endif\r
66ifeq ($(UNICODE),1)\r
67WXUNICODEFLAG = u\r
68endif\r
69ifeq ($(WXUNIV),1)\r
70WXUNIVNAME = univ\r
71endif\r
72ifeq ($(SHARED),1)\r
73WXDLLFLAG = dll\r
74endif\r
75ifeq ($(SHARED),0)\r
76LIBTYPE_SUFFIX = lib\r
77endif\r
78ifeq ($(SHARED),1)\r
79LIBTYPE_SUFFIX = dll\r
80endif\r
81ifeq ($(MONOLITHIC),0)\r
82EXTRALIBS_FOR_BASE = \r
83endif\r
84ifeq ($(MONOLITHIC),1)\r
51ec29ea 85EXTRALIBS_FOR_BASE = \r
61aba460
VS
86endif\r
87ifeq ($(SHARED),0)\r
88__wx_exe___depname = $(OBJS)\wx_exe.exe\r
89endif\r
90ifeq ($(WXUNIV),1)\r
91__WXUNIV_DEFINE_p_3 = --define __WXUNIVERSAL__\r
92endif\r
93ifeq ($(DEBUG_FLAG),0)\r
94__DEBUG_DEFINE_p_3 = --define wxDEBUG_LEVEL=0\r
95endif\r
da8b1d4b
KO
96ifeq ($(BUILD),release)\r
97__NDEBUG_DEFINE_p_3 = --define NDEBUG\r
98endif\r
61aba460
VS
99ifeq ($(USE_EXCEPTIONS),0)\r
100__EXCEPTIONS_DEFINE_p_3 = --define wxNO_EXCEPTIONS\r
101endif\r
102ifeq ($(USE_RTTI),0)\r
103__RTTI_DEFINE_p_3 = --define wxNO_RTTI\r
104endif\r
105ifeq ($(USE_THREADS),0)\r
106__THREAD_DEFINE_p_3 = --define wxNO_THREADS\r
107endif\r
108ifeq ($(UNICODE),0)\r
109__UNICODE_DEFINE_p_3 = --define wxUSE_UNICODE=0\r
110endif\r
111ifeq ($(UNICODE),1)\r
112__UNICODE_DEFINE_p_3 = --define _UNICODE\r
113endif\r
114ifeq ($(MSLU),1)\r
115__MSLU_DEFINE_p_3 = --define wxUSE_UNICODE_MSLU=1\r
116endif\r
61aba460
VS
117ifeq ($(USE_CAIRO),1)\r
118__CAIRO_INCLUDEDIR_p_1 = --include-dir $(CAIRO_ROOT)/include/cairo\r
119endif\r
120ifeq ($(SHARED),1)\r
121__DLLFLAG_p_3 = --define WXUSINGDLL\r
122endif\r
61aba460
VS
123ifeq ($(WXUNIV),1)\r
124__WXUNIV_DEFINE_p = -D__WXUNIVERSAL__\r
125endif\r
126ifeq ($(DEBUG_FLAG),0)\r
127__DEBUG_DEFINE_p = -DwxDEBUG_LEVEL=0\r
128endif\r
da8b1d4b
KO
129ifeq ($(BUILD),release)\r
130__NDEBUG_DEFINE_p = -DNDEBUG\r
131endif\r
61aba460
VS
132ifeq ($(USE_EXCEPTIONS),0)\r
133__EXCEPTIONS_DEFINE_p = -DwxNO_EXCEPTIONS\r
134endif\r
135ifeq ($(USE_RTTI),0)\r
136__RTTI_DEFINE_p = -DwxNO_RTTI\r
137endif\r
138ifeq ($(USE_THREADS),0)\r
139__THREAD_DEFINE_p = -DwxNO_THREADS\r
140endif\r
141ifeq ($(UNICODE),0)\r
142__UNICODE_DEFINE_p = -DwxUSE_UNICODE=0\r
143endif\r
144ifeq ($(UNICODE),1)\r
145__UNICODE_DEFINE_p = -D_UNICODE\r
146endif\r
147ifeq ($(MSLU),1)\r
148__MSLU_DEFINE_p = -DwxUSE_UNICODE_MSLU=1\r
149endif\r
61aba460
VS
150ifeq ($(USE_CAIRO),1)\r
151____CAIRO_INCLUDEDIR_FILENAMES = -I$(CAIRO_ROOT)\include\cairo\r
152endif\r
153ifeq ($(SHARED),1)\r
154__DLLFLAG_p = -DWXUSINGDLL\r
155endif\r
156ifeq ($(MONOLITHIC),0)\r
157__WXLIB_CORE_p = \\r
158 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core\r
159endif\r
160ifeq ($(MONOLITHIC),0)\r
161__WXLIB_BASE_p = \\r
bed99c22 162 -lwxbase$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)\r
61aba460
VS
163endif\r
164ifeq ($(MONOLITHIC),1)\r
165__WXLIB_MONO_p = \\r
166 -lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)\r
167endif\r
a4830bb5 168ifeq ($(MONOLITHIC),1)\r
e7bdf0ac 169ifeq ($(USE_STC),1)\r
a4830bb5
VZ
170__LIB_SCINTILLA_IF_MONO_p = -lwxscintilla$(WXDEBUGFLAG)\r
171endif\r
e7bdf0ac 172endif\r
61aba460
VS
173ifeq ($(USE_GUI),1)\r
174__LIB_TIFF_p = -lwxtiff$(WXDEBUGFLAG)\r
175endif\r
176ifeq ($(USE_GUI),1)\r
177__LIB_JPEG_p = -lwxjpeg$(WXDEBUGFLAG)\r
178endif\r
179ifeq ($(USE_GUI),1)\r
180__LIB_PNG_p = -lwxpng$(WXDEBUGFLAG)\r
181endif\r
182ifeq ($(MSLU),1)\r
183__UNICOWS_LIB_p = -lunicows\r
184endif\r
61aba460
VS
185ifeq ($(USE_CAIRO),1)\r
186__CAIRO_LIB_p = -lcairo\r
187endif\r
188ifeq ($(USE_CAIRO),1)\r
189____CAIRO_LIBDIR_FILENAMES = -L$(CAIRO_ROOT)\lib\r
190endif\r
191ifeq ($(BUILD),debug)\r
da8b1d4b
KO
192__OPTIMIZEFLAG = -O0\r
193endif\r
194ifeq ($(BUILD),release)\r
195__OPTIMIZEFLAG = -O2\r
196endif\r
197ifeq ($(USE_RTTI),0)\r
198__RTTIFLAG = -fno-rtti\r
199endif\r
200ifeq ($(USE_RTTI),1)\r
201__RTTIFLAG = \r
202endif\r
203ifeq ($(USE_EXCEPTIONS),0)\r
204__EXCEPTIONSFLAG = -fno-exceptions\r
205endif\r
206ifeq ($(USE_EXCEPTIONS),1)\r
207__EXCEPTIONSFLAG = \r
208endif\r
209ifeq ($(BUILD),debug)\r
61aba460
VS
210ifeq ($(DEBUG_INFO),default)\r
211__DEBUGINFO = -g\r
212endif\r
213endif\r
214ifeq ($(BUILD),release)\r
215ifeq ($(DEBUG_INFO),default)\r
216__DEBUGINFO = \r
217endif\r
218endif\r
219ifeq ($(DEBUG_INFO),0)\r
220__DEBUGINFO = \r
221endif\r
222ifeq ($(DEBUG_INFO),1)\r
223__DEBUGINFO = -g\r
224endif\r
225ifeq ($(USE_THREADS),0)\r
226__THREADSFLAG = \r
227endif\r
228ifeq ($(USE_THREADS),1)\r
229__THREADSFLAG = -mthreads\r
230endif\r
231\r
232\r
233all: $(OBJS)\r
234$(OBJS):\r
235 -if not exist $(OBJS) mkdir $(OBJS)\r
236\r
237### Targets: ###\r
238\r
da8b1d4b 239all: $(OBJS)\my_dll.dll $(__wx_exe___depname) $(OBJS)\sdk_exe.exe\r
61aba460
VS
240\r
241clean: \r
242 -if exist $(OBJS)\*.o del $(OBJS)\*.o\r
243 -if exist $(OBJS)\*.d del $(OBJS)\*.d\r
244 -if exist $(OBJS)\my_dll.dll del $(OBJS)\my_dll.dll\r
245 -if exist $(OBJS)\libmy_dll.a del $(OBJS)\libmy_dll.a\r
246 -if exist $(OBJS)\wx_exe.exe del $(OBJS)\wx_exe.exe\r
da8b1d4b 247 -if exist $(OBJS)\sdk_exe.exe del $(OBJS)\sdk_exe.exe\r
61aba460
VS
248\r
249$(OBJS)\my_dll.dll: $(MY_DLL_OBJECTS)\r
a4830bb5 250 $(CXX) $(LINK_DLL_FLAGS) -fPIC -o $@ $(MY_DLL_OBJECTS) -Wl,--out-implib=$(OBJS)\libmy_dll.a $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) $(____CAIRO_LIBDIR_FILENAMES) $(LDFLAGS) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_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\r
61aba460
VS
251\r
252ifeq ($(SHARED),0)\r
253$(OBJS)\wx_exe.exe: $(WX_EXE_OBJECTS) $(OBJS)\wx_exe_sample_rc.o $(OBJS)\my_dll.dll\r
a4830bb5 254 $(CXX) -o $@ $(WX_EXE_OBJECTS) $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) -Wl,--subsystem,windows -mwindows $(____CAIRO_LIBDIR_FILENAMES) $(LDFLAGS) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(OBJS)\libmy_dll.a $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_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\r
61aba460
VS
255endif\r
256\r
da8b1d4b
KO
257$(OBJS)\sdk_exe.exe: $(SDK_EXE_OBJECTS) $(OBJS)\my_dll.dll\r
258 $(CXX) -o $@ $(SDK_EXE_OBJECTS) $(__DEBUGINFO) $(__THREADSFLAG) -Wl,--subsystem,windows -mwindows $(LDFLAGS) $(OBJS)\libmy_dll.a -luser32\r
259\r
61aba460
VS
260$(OBJS)\my_dll_my_dll.o: ./my_dll.cpp\r
261 $(CXX) -c -o $@ $(MY_DLL_CXXFLAGS) $(CPPDEPS) $<\r
262\r
263$(OBJS)\wx_exe_sample_rc.o: ./../../samples/sample.rc\r
bed99c22 264 windres --use-temp-file -i$< -o$@ --define __WXMSW__ $(__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\r
61aba460 265\r
1ffe64ef 266$(OBJS)\wx_exe_wx_exe.o: ./wx_exe.cpp\r
61aba460
VS
267 $(CXX) -c -o $@ $(WX_EXE_CXXFLAGS) $(CPPDEPS) $<\r
268\r
da8b1d4b
KO
269$(OBJS)\sdk_exe_sdk_exe.o: ./sdk_exe.cpp\r
270 $(CXX) -c -o $@ $(SDK_EXE_CXXFLAGS) $(CPPDEPS) $<\r
271\r
61aba460
VS
272.PHONY: all clean\r
273\r
274\r
275SHELL := $(COMSPEC)\r
276\r
277# Dependencies tracking:\r
278-include $(OBJS)/*.d\r