]> git.saurik.com Git - wxWidgets.git/blob - build/bakefiles/common.bkl
642754bb3b79255ab13ac50469986b37e77f5993
[wxWidgets.git] / build / bakefiles / common.bkl
1 <?xml version="1.0" ?>
2 <!-- $Id$ -->
3
4 <makefile>
5
6 <requires version="0.1.7"/>
7
8 <!-- bakefile modules we need: -->
9 <using module="datafiles"/>
10
11 <!-- load python module with wxwindows helpers: -->
12 <using module="wxwin"/>
13
14 <!-- DFE: Add a platform meaning regular MacOS (not OS X) -->
15 <!-- FIXME: This will be handled in Bakefile but for now I wanted to
16 get my changes to the wx bakefiles in the tree but invisible to
17 windows toolkits and their config.xxx settings -->
18 <if cond="FORMAT=='autoconf'">
19 <option name="PLATFORM_MACOS"/>
20 </if>
21 <if cond="FORMAT!='autoconf'">
22 <set var="PLATFORM_MACOS">0</set>
23 </if>
24
25 <!-- FIXME: PalmOS is another candidate to bakefiles -->
26 <set var="PLATFORM_PALMOS">0</set>
27
28 <include file="config.bkl"/>
29
30 <include file="plugins_deps.bkl"/>
31
32 <!-- ================================================================== -->
33 <!-- wxWidgets version numbers: -->
34 <!-- ================================================================== -->
35
36 <set var="WXVER_MAJOR">$(wxwin.getVersionMajor())</set>
37 <set var="WXVER_MINOR">$(wxwin.getVersionMinor())</set>
38 <set var="WXVER_RELEASE">$(wxwin.getVersionRelease())</set>
39 <set var="WX_RELEASE" make_var="1">
40 $(WXVER_MAJOR).$(WXVER_MINOR)
41 </set>
42 <set var="WX_RELEASE_NODOT" make_var="1">
43 $(WXVER_MAJOR)$(WXVER_MINOR)
44 </set>
45 <set var="WX_VERSION" make_var="1">
46 $(WX_RELEASE).$(WXVER_RELEASE)
47 </set>
48 <set var="WX_VERSION_NODOT" make_var="1">
49 $(WX_RELEASE_NODOT)$(WXVER_RELEASE)
50 </set>
51
52 <set var="WX_STABLE_BRANCH">$(int(int(WXVER_MINOR) % 2 == 0))</set>
53
54 <set var="WXSOVERSION">
55 <if cond="WX_STABLE_BRANCH=='1'">0.0.0</if>
56 <if cond="WX_STABLE_BRANCH=='0'">$(WXVER_RELEASE).0.0</if>
57 </set>
58 <set var="WXMACVERSION">$(WX_VERSION)</set>
59 <set var="WXWIN32DLLVERSION">
60 <if cond="WX_STABLE_BRANCH=='1'">$(WX_RELEASE_NODOT)</if>
61 <if cond="WX_STABLE_BRANCH=='0'">$(WX_VERSION_NODOT)</if>
62 </set>
63
64
65 <!-- ================================================================== -->
66 <!-- Names of libraries and DLLs: -->
67 <!-- ================================================================== -->
68
69 <set var="PORTNAME">
70 <if cond="USE_GUI=='0'">base</if>
71 <if cond="USE_GUI=='1'">$(TOOLKIT_LOWERCASE)$(TOOLKIT_VERSION)</if>
72 </set>
73
74 <set var="WXBASEPORT">
75 <if cond="TOOLKIT=='MAC'">_carbon</if>
76 </set>
77
78 <set var="COMPILERORGCC">
79 <if cond="isdefined('COMPILER')">$(COMPILER)</if>
80 <if cond="not isdefined('COMPILER')">gcc</if>
81 </set>
82 <set var="WXCOMPILER">
83 <if cond="PLATFORM_WIN32=='1'">_$(COMPILERORGCC)</if>
84 </set>
85
86 <set var="VENDORTAG">
87 <if cond="PLATFORM_WIN32=='1' and OFFICIAL_BUILD=='1'"></if>
88 <if cond="PLATFORM_WIN32=='1' and OFFICIAL_BUILD=='0'">_$(VENDOR)</if>
89 </set>
90
91 <set var="WXDEBUGFLAG">
92 <if cond="BUILD=='debug' and DEBUG_FLAG=='default'">d</if>
93 <if cond="DEBUG_FLAG=='1'">d</if>
94 </set>
95 <set var="WXUNICODEFLAG">
96 <!-- WinCE is Unicode-only platform: -->
97 <if cond="UNICODE=='1' and FORMAT!='msevc4prj'">u</if>
98 </set>
99 <set var="WXNAMESUFFIX">
100 $(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
101 </set>
102
103 <set var="WXUNIVNAME">
104 <if cond="WXUNIV=='1'">univ</if>
105 </set>
106 <set var="WXUNIV_DEFINE">
107 <if cond="WXUNIV=='1'">__WXUNIVERSAL__</if>
108 </set>
109
110 <if cond="FORMAT=='autoconf'">
111 <set var="WXNAMEPREFIX">wx_base$(WXBASEPORT)</set>
112 <set var="WXNAMEPREFIXGUI">wx_$(PORTNAME)$(WXUNIVNAME)</set>
113 <set var="WXVERSIONTAG">-$(WX_RELEASE)</set>
114 </if>
115 <if cond="FORMAT!='autoconf'">
116 <set var="WXNAMEPREFIX">
117 wxbase$(WXBASEPORT)$(WX_RELEASE_NODOT)
118 </set>
119 <set var="WXNAMEPREFIXGUI">
120 wx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)</set>
121 <set var="WXVERSIONTAG"></set>
122 </if>
123 <set var="WXDLLNAMEPREFIX">
124 <if cond="PLATFORM_WIN32=='1'">
125 wxbase$(WXBASEPORT)$(WXWIN32DLLVERSION)
126 </if>
127 <if cond="PLATFORM_WIN32=='0'">$(WXNAMEPREFIX)</if>
128 </set>
129 <set var="WXDLLNAMEPREFIXGUI">
130 <if cond="PLATFORM_WIN32=='1'">
131 wx$(PORTNAME)$(WXUNIVNAME)$(WXWIN32DLLVERSION)
132 </if>
133 <if cond="PLATFORM_WIN32=='0'">$(WXNAMEPREFIXGUI)</if>
134 </set>
135 <set var="WXDLLVERSIONTAG">
136 <if cond="PLATFORM_WIN32=='1'"></if>
137 <if cond="PLATFORM_WIN32=='0'">$(WXVERSIONTAG)</if>
138 </set>
139
140
141 <!-- =============================================================== -->
142 <!-- Names of component libraries: -->
143 <!-- =============================================================== -->
144
145 <set var="WXLIB_BASE">
146 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('base')))</if>
147 </set>
148 <set var="WXLIB_NET">
149 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('net')))</if>
150 </set>
151 <set var="WXLIB_CORE">
152 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('core')))</if>
153 </set>
154 <set var="WXLIB_ADV">
155 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('adv')))</if>
156 </set>
157 <set var="WXLIB_MEDIA">
158 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('media')))</if>
159 </set>
160 <set var="WXLIB_HTML">
161 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('html')))</if>
162 </set>
163 <set var="WXLIB_XML">
164 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('xml')))</if>
165 </set>
166 <set var="WXLIB_XRC">
167 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('xrc')))</if>
168 </set>
169 <set var="WXLIB_ODBC">
170 <if cond="MONOLITHIC=='0' and USE_ODBC=='1'">
171 $(mk.evalExpr(wxwin.mkLibName('odbc')))
172 </if>
173 </set>
174 <set var="WXLIB_DBGRID">
175 <if cond="MONOLITHIC=='0'">$(mk.evalExpr(wxwin.mkLibName('dbgrid')))</if>
176 </set>
177
178 <set var="WXLIB_MONO">
179 <if cond="MONOLITHIC=='1'">$(mk.evalExpr(wxwin.mkLibName('mono')))</if>
180 </set>
181
182
183 <!-- =============================================================== -->
184 <!-- Where to store built libraries and objects: -->
185 <!-- =============================================================== -->
186
187 <set var="DIR_SUFFIX_CPU">
188 <if cond="FORMAT=='msevc4prj'">_$(CPU)</if>
189 </set>
190
191 <if cond="FORMAT!='autoconf'">
192 <set var="WXDLLFLAG">
193 <if cond="SHARED=='1'">dll</if>
194 </set>
195 <set var="CFG_NAME_PART">
196 $(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
197 </set>
198 <set var="OBJS" make_var="1">
199 <if cond="FORMAT!='cbuilderx'">
200 $(COMPILER)_$(CFG_NAME_PART)$(DIR_SUFFIX_CPU)
201 </if>
202 <!-- FIXME: waiting for removal after CBX has better ../ dirs
203 support -->
204 <if cond="FORMAT=='cbuilderx'">build_cbx_$(CFG_NAME_PART)</if>
205 </set>
206
207 <set var="BUILDDIR">$(OBJS)</set>
208 </if>
209
210 <set var="LIBTYPE_SUFFIX" make_var="1">
211 <if cond="FORMAT!='autoconf' and SHARED=='0'">lib</if>
212 <if cond="FORMAT!='autoconf' and SHARED=='1'">dll</if>
213 </set>
214
215 <set var="LIBDIRNAME" make_var="1">
216 <if cond="FORMAT=='autoconf'">$(top_builddir)lib</if>
217 <if cond="FORMAT!='autoconf'">
218 $(nativePaths(TOP_SRCDIR))lib$(DIRSEP)$(COMPILER)$(DIR_SUFFIX_CPU)_$(LIBTYPE_SUFFIX)$(CFG)
219 </if>
220 </set>
221
222 <if cond="FORMAT!='autoconf'">
223 <set var="SETUPHDIR" make_var="1">
224 $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)$(WXUNICODEFLAG)$(WXDEBUGFLAG)
225 </set>
226 </if>
227
228
229
230 <!-- =============================================================== -->
231 <!-- Templates for libs: -->
232 <!-- =============================================================== -->
233
234 <set var="DEBUGINFO">
235 <if cond="BUILD=='debug' and DEBUG_INFO=='default'">on</if>
236 <if cond="DEBUG_INFO=='1'">on</if>
237 <if cond="BUILD=='release' and DEBUG_INFO=='default'">off</if>
238 <if cond="DEBUG_INFO=='0'">off</if>
239 </set>
240 <set var="DEBUGRUNTIME">
241 <if cond="DEBUG_RUNTIME_LIBS=='default'">$(DEBUGINFO)</if>
242 <if cond="DEBUG_RUNTIME_LIBS=='0'">off</if>
243 <if cond="DEBUG_RUNTIME_LIBS=='1'">on</if>
244 </set>
245 <set var="OPTIMIZEFLAG">
246 <if cond="BUILD=='debug'">off</if>
247 <if cond="BUILD=='release'">speed</if>
248 </set>
249 <set var="EXCEPTIONSFLAG">
250 <if cond="USE_EXCEPTIONS=='1'">on</if>
251 <if cond="USE_EXCEPTIONS=='0'">off</if>
252 </set>
253 <set var="RTTIFLAG">
254 <if cond="USE_RTTI=='1'">on</if>
255 <if cond="USE_RTTI=='0'">off</if>
256 </set>
257 <set var="THREADSFLAG">
258 <if cond="USE_THREADS=='1'">multi</if>
259 <if cond="USE_THREADS=='0'">single</if>
260 </set>
261
262 <set var="DEBUG_DEFINE">
263 <if cond="FORMAT!='autoconf' and BUILD=='debug' and DEBUG_FLAG=='default'">__WXDEBUG__</if>
264 <if cond="FORMAT!='autoconf' and DEBUG_FLAG=='1'">__WXDEBUG__</if>
265 </set>
266 <!-- does not cover all cases, but better than nothing -->
267 <set var="NO_VC_CRTDBG">
268 <if cond="FORMAT=='msvc' and BUILD=='debug' and DEBUG_RUNTIME_LIBS=='0'">__NO_VC_CRTDBG__</if>
269 <if cond="FORMAT=='msvc' and BUILD=='release' and DEBUG_FLAG=='1'">__NO_VC_CRTDBG__</if>
270 </set>
271 <set var="UNICODE_DEFINE">
272 <if cond="FORMAT!='autoconf' and UNICODE=='1'">_UNICODE</if>
273 </set>
274
275 <!-- fill for the specific case of the format/compiler -->
276 <set var="WIN32_WINNT">
277 <if cond="FORMAT=='dmars' or FORMAT=='dmars_smake'">_WIN32_WINNT=0x0400</if>
278 </set>
279
280 <set var="UNICOWS_LIB">
281 <if cond="MSLU=='1'">unicows</if>
282 </set>
283
284 <template id="common_settings">
285 <debug-info>$(DEBUGINFO)</debug-info>
286 <debug-runtime-libs>$(DEBUGRUNTIME)</debug-runtime-libs>
287 <optimize>$(OPTIMIZEFLAG)</optimize>
288 <threading>$(THREADSFLAG)</threading>
289 <runtime-libs>$(RUNTIME_LIBS)</runtime-libs>
290 <cxx-rtti>$(RTTIFLAG)</cxx-rtti>
291 <cxx-exceptions>$(EXCEPTIONSFLAG)</cxx-exceptions>
292 <if cond="FORMAT!='autoconf'">
293 <cppflags>$(EXTRACFLAGS)</cppflags>
294 </if>
295 <define>$(NO_VC_CRTDBG)</define>
296 <define>$(WIN32_WINNT)</define>
297 </template>
298
299 <template id="anylib">
300 <dirname>$(LIBDIRNAME)</dirname>
301 <install-to>$(LIBDIR)</install-to>
302 </template>
303
304 <template id="3rdparty_lib" template="common_settings,anylib">
305 <if cond="FORMAT=='autoconf'">
306 <libname>$(id)$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)</libname>
307 </if>
308 <if cond="FORMAT!='autoconf'">
309 <libname>$(id)$(WXDEBUGFLAG)$(HOST_SUFFIX)</libname>
310 </if>
311 <!--
312 we want to install 3rd party libs system-wide only with static
313 version of wxWidgets; otherwise they are embedded in shared libs:
314 -->
315 <install-if>SHARED=='0'</install-if>
316 <pic>$(substituteFromDict(SHARED, {'0':'off', '1':'on'}))</pic>
317 </template>
318
319
320 <!-- deal with the need to copy setup.h here: -->
321
322 <set var="IS_MSVC_PRJ">$(FORMAT in ['msvc6prj','msevc4prj'])</set>
323
324 <define-tag name="msvc-headers" rules="dll,lib">
325 <if cond="IS_MSVC_PRJ">
326 <msvc-project-files>
327 $(addPrefixToList('include\', wxwin.headersOnly(value)))
328 </msvc-project-files>
329 </if>
330 </define-tag>
331
332 <define-tag name="msvc-copy-setup-h" rules="dll,lib">
333 <if cond="FORMAT=='msevc4prj'">
334 <msvc-headers>wx/msw/wince/setup.h</msvc-headers>
335 <set var="vc_setup_h">wince\setup.h</set>
336 <set var="vc_setup_h_rule">wince_setup_h</set>
337 </if>
338 <if cond="FORMAT!='msevc4prj'">
339 <msvc-headers>wx/msw/setup.h</msvc-headers>
340 <set var="vc_setup_h">setup.h</set>
341 <set var="vc_setup_h_rule">setup_h</set>
342 </if>
343 <if cond="IS_MSVC_PRJ">
344 <set var="_custom_build_files" append="1">
345 include\wx\msw\$(vc_setup_h)
346 </set>
347 <set var="_custom_build_include_wx_msw_$(vc_setup_h_rule)">
348 Creating $(SETUPHDIR)\wx\setup.h
349 InputPath=..\include\wx\msw\$(vc_setup_h)
350
351 "$(SETUPHDIR)\wx\setup.h" : $(DOLLAR)(SOURCE) "$(DOLLAR)(INTDIR)" "$(DOLLAR)(OUTDIR)"
352 $(TAB)copy "$(DOLLAR)(InputPath)" $(SETUPHDIR)\wx\setup.h
353 </set>
354 </if>
355 </define-tag>
356
357 <template id="msvc_setup_h">
358 <msvc-copy-setup-h/>
359 </template>
360
361 <!-- =============================================================== -->
362 <!-- 3rd party libs: -->
363 <!-- =============================================================== -->
364
365 <!-- 3rd party libraries: -->
366 <include file="regex.bkl"/>
367 <include file="zlib.bkl"/>
368 <include file="png.bkl"/>
369 <include file="jpeg.bkl"/>
370 <include file="tiff.bkl"/>
371 <include file="odbc.bkl"/>
372 <include file="expat.bkl"/>
373
374
375 <!-- =============================================================== -->
376 <!-- Templates for wxWidgets libs: -->
377 <!-- =============================================================== -->
378
379 <!-- NB: in monolithic build, even wxBase-only must be linked against
380 GUI extralibs, otherwise there would be unresolved references.
381 The variables below are defined so that all libs are used
382 in monolithic build, but not in multilib one. -->
383 <set var="EXTRALIBS_FOR_BASE">
384 <if cond="MONOLITHIC=='1'">$(EXTRALIBS) $(EXTRALIBS_GUI)</if>
385 <if cond="MONOLITHIC=='0'">$(EXTRALIBS)</if>
386 </set>
387 <set var="EXTRALIBS_FOR_GUI">
388 <if cond="MONOLITHIC=='1'"></if>
389 <if cond="MONOLITHIC=='0'">$(EXTRALIBS_GUI)</if>
390 </set>
391
392 <template id="wx" template="common_settings">
393 <set var="wxid">$(wxwin.mk_wxid(id))</set>
394 <define>__WX$(TOOLKIT)__</define>
395 <define>$(WXUNIV_DEFINE)</define>
396 <define>$(DEBUG_DEFINE)</define>
397 <define>$(UNICODE_DEFINE)</define>
398 <!-- this include is added by configure, we need to put other
399 includes before it: -->
400 <include cond="FORMAT!='autoconf'">$(TOP_SRCDIR)include</include>
401 <lib-path>$(LIBDIRNAME)</lib-path>
402 <include cond="FORMAT!='autoconf'">$(SETUPHDIR)</include>
403 <warnings>max</warnings>
404 <cppflags-watcom>
405 -wcd=549 <!-- 'sizeof' operand contains compiler generated information -->
406 -wcd=656 <!-- define this function inside its class definition (may improve code quality) -->
407 -wcd=657 <!-- define this function inside its class definition (could have improved code quality) -->
408 -wcd=667 <!-- 'va_start' macro will not work without an argument before '...' -->
409 </cppflags-watcom>
410 <cxxflags-mingw>
411 -Wno-ctor-dtor-privacy <!-- only defines a private destructor and has no friends -->
412 </cxxflags-mingw>
413 </template>
414
415 <!-- for both GUI and wxBase libs/samples: -->
416 <template id="wx_append_base_nomono">
417 <!-- link against builtin 3rd party libs, if needed: -->
418 <sys-lib>$(LIB_TIFF)</sys-lib>
419 <sys-lib>$(LIB_JPEG)</sys-lib>
420 <sys-lib>$(LIB_PNG)</sys-lib>
421 <sys-lib>$(LIB_ZLIB)</sys-lib>
422 <sys-lib>$(LIB_ODBC)</sys-lib>
423 <sys-lib>$(LIB_REGEX)</sys-lib>
424 <sys-lib>$(LIB_EXPAT)</sys-lib>
425
426 <ldlibs>$(EXTRALIBS_FOR_BASE)</ldlibs>
427
428 <!-- system libraries on windows: -->
429 <if cond="FORMAT!='autoconf'">
430 <sys-lib>$(UNICOWS_LIB)</sys-lib>
431 <if cond="FORMAT=='borland'">
432 <sys-lib>ole2w32</sys-lib>
433 </if>
434 <if cond="FORMAT=='msevc4prj'">
435 <sys-lib>ole32</sys-lib>
436 <sys-lib>oleaut32</sys-lib>
437 <sys-lib>uuid</sys-lib>
438 <sys-lib>commctrl</sys-lib>
439 <sys-lib>winsock</sys-lib>
440 <sys-lib>wininet</sys-lib>
441 </if>
442 <if cond="FORMAT!='borland' and FORMAT!='msevc4prj'">
443 <sys-lib>kernel32</sys-lib>
444 <sys-lib>user32</sys-lib>
445 <sys-lib>gdi32</sys-lib>
446 <sys-lib>comdlg32</sys-lib>
447 <sys-lib>winspool</sys-lib>
448 <sys-lib>winmm</sys-lib>
449 <sys-lib>shell32</sys-lib>
450 <sys-lib>comctl32</sys-lib>
451 <sys-lib>ole32</sys-lib>
452 <sys-lib>oleaut32</sys-lib>
453 <sys-lib>uuid</sys-lib>
454 <sys-lib>rpcrt4</sys-lib>
455 <sys-lib>advapi32</sys-lib>
456 <sys-lib>wsock32</sys-lib>
457 </if>
458 <if cond="FORMAT=='msvc' or FORMAT=='msvc6prj' or FORMAT=='borland'">
459 <sys-lib>oleacc</sys-lib>
460 </if>
461 <if cond="FORMAT!='msevc4prj'">
462 <sys-lib>odbc32</sys-lib>
463 </if>
464 </if>
465 </template>
466
467
468 <!-- for GUI libs/samples: -->
469 <template id="wx_append_nomono" template="wx_append_base_nomono">
470 <ldlibs>$(EXTRALIBS_FOR_GUI)</ldlibs>
471 </template>
472
473
474 <template id="wx_append_base" template_append="wx_append_base_nomono">
475 <!-- Always link against the wxWin library in monolithic build: -->
476 <sys-lib>$(WXLIB_MONO)</sys-lib>
477 </template>
478 <template id="wx_append" template_append="wx_append_nomono">
479 <!-- Always link against the wxWin library in monolithic build: -->
480 <sys-lib>$(WXLIB_MONO)</sys-lib>
481 </template>
482
483
484 <set var="WX_DISABLE_PRECOMP_HEADERS" overwrite="0">0</set>
485
486 <template id="wx_lib_b" template="wx,anylib">
487 <set var="WXLIBNAME">$(wxwin.mkLibName(wxid))</set>
488 <libname>$(WXLIBNAME)</libname>
489
490 <if cond="WX_DISABLE_PRECOMP_HEADERS=='0'">
491 <if cond="FORMAT!='autoconf' and TOOLKIT=='MSW'">
492 <sources>$(WXTOPDIR)src/msw/dummy.cpp</sources>
493 <precomp-headers-gen>
494 $(WXTOPDIR)src/msw/dummy.cpp
495 </precomp-headers-gen>
496 </if>
497 <precomp-headers-location>$(WXTOPDIR)include</precomp-headers-location>
498 <precomp-headers-header>wx/wxprec.h</precomp-headers-header>
499 <precomp-headers>on</precomp-headers>
500 <precomp-headers-file>wxprec_$(id)</precomp-headers-file>
501 <precomp-headers-exclude>
502 src/common/extended.c
503 </precomp-headers-exclude>
504 </if>
505
506 <if cond="IS_MSVC_PRJ=='1' and BUILDING_LIB=='1'">
507 <msvc-file-group>Common Sources:src/common/*</msvc-file-group>
508 <msvc-file-group>MSW Sources:src/msw/*</msvc-file-group>
509 <msvc-file-group>Generic Sources:src/generic/*</msvc-file-group>
510 <msvc-file-group>wxUniv Sources:src/univ/*</msvc-file-group>
511 <msvc-file-group>wxHTML Sources:src/html/*</msvc-file-group>
512 <msvc-file-group>Setup Headers:*/setup.h</msvc-file-group>
513 <msvc-file-group>MSW Headers:*wx/msw/*.h</msvc-file-group>
514 <msvc-file-group>Generic Headers:*wx/generic/*.h</msvc-file-group>
515 <msvc-file-group>wxUniv Headers:*wx/univ/*.h</msvc-file-group>
516 <msvc-file-group>wxHTML Headers:*wx/html/*.h</msvc-file-group>
517 <msvc-file-group>Common Headers:*wx/*.h</msvc-file-group>
518 </if>
519 </template>
520
521 <template id="wx_dll_b" template="wx_lib_b">
522 <set var="WXDLLNAME">$(wxwin.mkDllName(wxid))</set>
523 <dllname>$(WXDLLNAME)</dllname>
524 <version>$(WX_VERSION)</version>
525 <so_version>$(WXSOVERSION)</so_version>
526 <mac_version>$(WXMACVERSION)</mac_version>
527
528 <!-- version info resources: -->
529 <if cond="FORMAT not in ['rpmspec','wx24dsp']"> <!-- FIXME: fix for bkl-0.1.7 only, remove the cond later -->
530 <res-define>WXDLLNAME=$(WXDLLNAME)</res-define>
531 <res-include cond="FORMAT=='autoconf'">
532 $(TOP_SRCDIR)include
533 </res-include>
534 </if>
535 <win32-res>src/msw/version.rc</win32-res>
536 </template>
537
538 <template id="wx_3rdparty_dependencies_gui" cond="USE_GUI=='1'">
539 <depends>wxtiff</depends>
540 <depends>wxjpeg</depends>
541 <depends>wxpng</depends>
542 </template>
543
544 <template id="wx_3rdparty_dependencies"
545 template="wx_3rdparty_dependencies_gui">
546 <depends>wxexpat</depends>
547 <depends>wxzlib</depends>
548 <depends cond="FORMAT=='autoconf'">wxodbc</depends>
549 <depends>wxregex</depends>
550 </template>
551
552 <template id="wx_3rdparty_includes_gui" cond="USE_GUI=='1'">
553 <include>$(INC_TIFF)</include>
554 <include>$(INC_JPEG)</include>
555 <include>$(INC_PNG)</include>
556 </template>
557
558 <template id="wx_3rdparty_includes"
559 template="wx_3rdparty_includes_gui">
560 <include>$(INC_ZLIB)</include>
561 <include>$(INC_ODBC)</include>
562 <include>$(INC_REGEX)</include>
563 <include>$(INC_EXPAT)</include>
564 </template>
565
566 <template id="wx_lib"
567 template="wx_lib_b,wx_3rdparty_includes,msvc_setup_h"/>
568 <template id="wx_base_lib"
569 template="wx_lib_b,wx_3rdparty_includes,msvc_setup_h">
570 <define>wxUSE_GUI=0</define>
571 </template>
572
573 <template id="wx_dll"
574 template="wx_dll_b,wx_3rdparty_dependencies,wx_3rdparty_includes"
575 template_append="msvc_setup_h,wx_append_nomono"/>
576 <template id="wx_base_dll"
577 template="wx_dll_b,wx_3rdparty_dependencies,wx_3rdparty_includes"
578 template_append="msvc_setup_h,wx_append_base_nomono">
579 <define>wxUSE_GUI=0</define>
580 </template>
581
582 <!-- =============================================================== -->
583 <!-- Templates for building wxWidgets plugins: -->
584 <!-- =============================================================== -->
585
586 <if cond="WX_STABLE_BRANCH=='1'">
587 <set var="PLUGIN_VERSION0">
588 <if cond="PLATFORM_UNIX=='1'">$(WX_RELEASE)</if>
589 <if cond="PLATFORM_UNIX=='0'">$(WX_RELEASE_NODOT)</if>
590 </set>
591 </if>
592 <if cond="WX_STABLE_BRANCH=='0'">
593 <set var="PLUGIN_VERSION0">
594 <if cond="PLATFORM_UNIX=='1'">$(WX_VERSION)</if>
595 <if cond="PLATFORM_UNIX=='0'">$(WX_VERSION_NODOT)</if>
596 </set>
597 </if>
598 <set var="PLUGVERDELIM">
599 <if cond="PLATFORM_UNIX=='1'">-</if>
600 <if cond="PLATFORM_UNIX=='0'"></if>
601 </set>
602 <set var="PLUGIN_VERSION">$(PLUGVERDELIM)$(PLUGIN_VERSION0)</set>
603
604 <set var="PLUGINSUFFIX">
605 <if cond="UNICODE=='0' and BUILD=='release'"></if>
606 <if cond="UNICODE=='0' and BUILD=='debug'">d</if>
607 <if cond="UNICODE=='1' and BUILD=='release'">u</if>
608 <if cond="UNICODE=='1' and BUILD=='debug'">ud</if>
609 </set>
610
611 <set var="PLUGINS_INST_DIR" make_var="1">
612 $(LIBDIR)/wx/$(PLUGIN_VERSION0)
613 </set>
614
615 <define-rule name="wx-base-plugin" extends="module">
616 <template>
617 <dllname>
618 $(id)$(PLUGINSUFFIX)$(PLUGIN_VERSION)$(WXCOMPILER)
619 </dllname>
620 <define>WXUSINGDLL</define>
621 <define>wxUSE_GUI=0</define>
622 <install-to>$(PLUGINS_INST_DIR)</install-to>
623 </template>
624 </define-rule>
625
626 <define-rule name="wx-gui-plugin" extends="module">
627 <template template="wx">
628 <dllname>
629 $(id)_$(PORTNAME)$(WXUNIVNAME)$(PLUGINSUFFIX)$(PLUGIN_VERSION)$(WXCOMPILER)
630 </dllname>
631 <define>WXUSINGDLL</define>
632 <install-to>$(PLUGINS_INST_DIR)</install-to>
633 </template>
634 </define-rule>
635
636 <!-- =============================================================== -->
637 <!-- Support for wxWidgets samples and contrib: -->
638 <!-- =============================================================== -->
639
640 <!-- Link against one wxWin library. Value must be literal! -->
641 <define-tag name="wx-lib" rules="exe,dll,module">
642 <sys-lib>$(wxwin.libToLink(value))</sys-lib>
643 <ldlibs>$(wxwin.extraLdflags(value))</ldlibs>
644 <if cond="IS_MSVC_PRJ=='1' and MONOLITHIC=='0'">
645 <depends-on-dsp>$(wxwin.makeDspDependency(value))</depends-on-dsp>
646 </if>
647 </define-tag>
648
649
650 <!-- A hack to keep autoconf happy (we pass CPPFLAGS that contain
651 {top_srcdir} from configure, poor bakefile can't know that
652 and won't output top_srcdir = @top_srcdir@ line): -->
653 <set var="VARS_DONT_ELIMINATE" append="1">top_srcdir</set>
654
655
656 </makefile>