]> git.saurik.com Git - wxWidgets.git/blame - include/wx/chkconf.h
limit recursion depth in DumpUDT() to prevent crashes when dumping linked lists
[wxWidgets.git] / include / wx / chkconf.h
CommitLineData
b45f79ec
VZ
1/*
2 * Name: wx/chkconf.h
3 * Purpose: check the config settings for consistency
4 * Author: Vadim Zeitlin
5 * Modified by:
6 * Created: 09.08.00
7 * RCS-ID: $Id$
8 * Copyright: (c) 2000 Vadim Zeitlin <vadim@wxwidgets.org>
9 * Licence: wxWindows licence
10 */
1e6feb95
VZ
11
12/* THIS IS A C FILE, DON'T USE C++ FEATURES (IN PARTICULAR COMMENTS) IN IT */
13
01ebf752
JS
14/*
15 Compiler-specific checking.
16 */
17
4055ed82 18#if defined(__WXPALMOS__)
ffecfa5a 19# include "wx/palmos/chkconf.h"
69dada2e
VZ
20#elif defined(__WXWINCE__)
21# include "wx/msw/wince/chkconf.h"
ffecfa5a 22#elif defined(__WXMSW__)
01ebf752
JS
23# include "wx/msw/chkconf.h"
24#elif defined(__WXMAC__)
25# include "wx/mac/chkconf.h"
b45f79ec 26#elif defined(__WXMOTIF__)
5c7c67fd 27# include "wx/motif/chkconf.h"
01ebf752
JS
28#endif
29
1e6feb95 30/*
730dfeb4 31 this global setting determines what should we do if the setting FOO
1e6feb95
VZ
32 requires BAR and BAR is not set: we can either silently define BAR
33 (default, recommended) or give an error and abort (mainly useful for
730dfeb4 34 developers only)
1e6feb95
VZ
35 */
36#define wxABORT_ON_CONFIG_ERROR
37
6962f34e
VZ
38/*
39 global features
40 */
41
42/* GUI build by default */
43#if !defined(wxUSE_GUI)
44# define wxUSE_GUI 1
45#endif /* !defined(wxUSE_GUI) */
46
1bbcb0d5
VZ
47/*
48 If we're compiling without support for threads/exceptions we have to
49 disable the corresponding features.
50 */
51#ifdef wxNO_THREADS
52# undef wxUSE_THREADS
53# define wxUSE_THREADS 0
54#endif /* wxNO_THREADS */
55
56#ifdef wxNO_EXCEPTIONS
57# undef wxUSE_EXCEPTIONS
58# define wxUSE_EXCEPTIONS 0
59#endif /* wxNO_EXCEPTIONS */
60
4652511f
VZ
61/* we also must disable exceptions if compiler doesn't support them */
62#if defined(_MSC_VER) && !defined(_CPPUNWIND)
63# undef wxUSE_EXCEPTIONS
64# define wxUSE_EXCEPTIONS 0
65#endif /* VC++ without exceptions support */
66
1bbcb0d5 67
1e6feb95 68/*
03169422
RL
69 tests for non GUI features
70 */
71
0c46d866
VZ
72#ifndef wxUSE_CRASHREPORT
73# ifdef wxABORT_ON_CONFIG_ERROR
74# error "wxUSE_CRASHREPORT must be defined."
75# else
76# define wxUSE_CRASHREPORT 0
77# endif
78#endif /* !defined(wxUSE_CRASHREPORT) */
79
03169422
RL
80#ifndef wxUSE_DYNLIB_CLASS
81# ifdef wxABORT_ON_CONFIG_ERROR
82# error "wxUSE_DYNLIB_CLASS must be defined."
83# else
84# define wxUSE_DYNLIB_CLASS 0
85# endif
86#endif /* !defined(wxUSE_DYNLIB_CLASS) */
87
4199367e
VZ
88#ifndef wxUSE_EXCEPTIONS
89# ifdef wxABORT_ON_CONFIG_ERROR
90# error "wxUSE_EXCEPTIONS must be defined."
91# else
92# define wxUSE_EXCEPTIONS 0
93# endif
94#endif /* !defined(wxUSE_EXCEPTIONS) */
95
c7f3eecc
VZ
96#ifndef wxUSE_FILESYSTEM
97# ifdef wxABORT_ON_CONFIG_ERROR
98# error "wxUSE_FILESYSTEM must be defined."
99# else
100# define wxUSE_FILESYSTEM 0
101# endif
102#endif /* !defined(wxUSE_FILESYSTEM) */
103
6fb17fd5 104/* don't give an error about this one yet, it's not fully implemented */
05815ab3 105#ifndef wxUSE_FSVOLUME
6fb17fd5 106# define wxUSE_FSVOLUME 0
05815ab3
VZ
107#endif /* !defined(wxUSE_FSVOLUME) */
108
03169422
RL
109#ifndef wxUSE_DYNAMIC_LOADER
110# ifdef wxABORT_ON_CONFIG_ERROR
111# error "wxUSE_DYNAMIC_LOADER must be defined."
112# else
113# define wxUSE_DYNAMIC_LOADER 0
114# endif
115#endif /* !defined(wxUSE_DYNAMIC_LOADER) */
116
a5d46b73
VZ
117#ifndef wxUSE_LOG
118# ifdef wxABORT_ON_CONFIG_ERROR
119# error "wxUSE_LOG must be defined."
120# else
121# define wxUSE_LOG 0
122# endif
123#endif /* !defined(wxUSE_LOG) */
124
125#ifndef wxUSE_LONGLONG
126# ifdef wxABORT_ON_CONFIG_ERROR
127# error "wxUSE_LONGLONG must be defined."
128# else
129# define wxUSE_LONGLONG 0
130# endif
131#endif /* !defined(wxUSE_LONGLONG) */
132
133#ifndef wxUSE_MIMETYPE
134# ifdef wxABORT_ON_CONFIG_ERROR
135# error "wxUSE_MIMETYPE must be defined."
136# else
137# define wxUSE_MIMETYPE 0
138# endif
139#endif /* !defined(wxUSE_MIMETYPE) */
140
0c46d866
VZ
141#ifndef wxUSE_ON_FATAL_EXCEPTION
142# ifdef wxABORT_ON_CONFIG_ERROR
143# error "wxUSE_ON_FATAL_EXCEPTION must be defined."
144# else
145# define wxUSE_ON_FATAL_EXCEPTION 0
146# endif
147#endif /* !defined(wxUSE_ON_FATAL_EXCEPTION) */
148
a5d46b73
VZ
149#ifndef wxUSE_PROTOCOL
150# ifdef wxABORT_ON_CONFIG_ERROR
151# error "wxUSE_PROTOCOL must be defined."
152# else
153# define wxUSE_PROTOCOL 0
154# endif
155#endif /* !defined(wxUSE_PROTOCOL) */
156
157/* we may not define wxUSE_PROTOCOL_XXX if wxUSE_PROTOCOL is set to 0 */
158#if !wxUSE_PROTOCOL
159# undef wxUSE_PROTOCOL_HTTP
160# undef wxUSE_PROTOCOL_FTP
161# undef wxUSE_PROTOCOL_FILE
162# define wxUSE_PROTOCOL_HTTP 0
163# define wxUSE_PROTOCOL_FTP 0
164# define wxUSE_PROTOCOL_FILE 0
165#endif /* wxUSE_PROTOCOL */
166
167#ifndef wxUSE_PROTOCOL_HTTP
168# ifdef wxABORT_ON_CONFIG_ERROR
169# error "wxUSE_PROTOCOL_HTTP must be defined."
170# else
171# define wxUSE_PROTOCOL_HTTP 0
172# endif
173#endif /* !defined(wxUSE_PROTOCOL_HTTP) */
174
175#ifndef wxUSE_PROTOCOL_FTP
176# ifdef wxABORT_ON_CONFIG_ERROR
177# error "wxUSE_PROTOCOL_FTP must be defined."
178# else
179# define wxUSE_PROTOCOL_FTP 0
180# endif
181#endif /* !defined(wxUSE_PROTOCOL_FTP) */
182
183#ifndef wxUSE_PROTOCOL_FILE
184# ifdef wxABORT_ON_CONFIG_ERROR
185# error "wxUSE_PROTOCOL_FILE must be defined."
186# else
187# define wxUSE_PROTOCOL_FILE 0
188# endif
189#endif /* !defined(wxUSE_PROTOCOL_FILE) */
190
191#ifndef wxUSE_REGEX
192# ifdef wxABORT_ON_CONFIG_ERROR
193# error "wxUSE_REGEX must be defined."
194# else
195# define wxUSE_REGEX 0
196# endif
197#endif /* !defined(wxUSE_REGEX) */
198
07158944
VZ
199#ifndef wxUSE_STDPATHS
200# ifdef wxABORT_ON_CONFIG_ERROR
201# error "wxUSE_STDPATHS must be defined."
202# else
203# define wxUSE_STDPATHS 1
204# endif
205#endif /* !defined(wxUSE_STDPATHS) */
206
27b0c286
VS
207#ifndef wxUSE_XML
208# ifdef wxABORT_ON_CONFIG_ERROR
209# error "wxUSE_XML must be defined."
210# else
211# define wxUSE_XML 0
212# endif
213#endif /* !defined(wxUSE_XML) */
214
a5d46b73
VZ
215#ifndef wxUSE_SOCKETS
216# ifdef wxABORT_ON_CONFIG_ERROR
217# error "wxUSE_SOCKETS must be defined."
218# else
219# define wxUSE_SOCKETS 0
220# endif
221#endif /* !defined(wxUSE_SOCKETS) */
222
223#ifndef wxUSE_STREAMS
224# ifdef wxABORT_ON_CONFIG_ERROR
225# error "wxUSE_STREAMS must be defined."
226# else
227# define wxUSE_STREAMS 0
228# endif
229#endif /* !defined(wxUSE_STREAMS) */
230
231#ifndef wxUSE_STOPWATCH
232# ifdef wxABORT_ON_CONFIG_ERROR
233# error "wxUSE_STOPWATCH must be defined."
234# else
235# define wxUSE_STOPWATCH 0
236# endif
237#endif /* !defined(wxUSE_STOPWATCH) */
238
239#ifndef wxUSE_TEXTBUFFER
240# ifdef wxABORT_ON_CONFIG_ERROR
241# error "wxUSE_TEXTBUFFER must be defined."
242# else
243# define wxUSE_TEXTBUFFER 0
244# endif
245#endif /* !defined(wxUSE_TEXTBUFFER) */
246
247#ifndef wxUSE_TEXTFILE
248# ifdef wxABORT_ON_CONFIG_ERROR
249# error "wxUSE_TEXTFILE must be defined."
250# else
251# define wxUSE_TEXTFILE 0
252# endif
253#endif /* !defined(wxUSE_TEXTFILE) */
254
255#ifndef wxUSE_UNICODE
256# ifdef wxABORT_ON_CONFIG_ERROR
257# error "wxUSE_UNICODE must be defined."
258# else
259# define wxUSE_UNICODE 0
260# endif
261#endif /* !defined(wxUSE_UNICODE) */
262
263#ifndef wxUSE_URL
264# ifdef wxABORT_ON_CONFIG_ERROR
265# error "wxUSE_URL must be defined."
266# else
267# define wxUSE_URL 0
268# endif
269#endif /* !defined(wxUSE_URL) */
270
03169422
RL
271/*
272 all these tests are for GUI only
1e6feb95
VZ
273 */
274#if wxUSE_GUI
275
276/*
277 all of the settings tested below must be defined or we'd get an error from
278 preprocessor about invalid integer expression
279 */
280
281#ifndef wxUSE_ACCEL
282# ifdef wxABORT_ON_CONFIG_ERROR
283# error "wxUSE_ACCEL must be defined."
284# else
285# define wxUSE_ACCEL 0
286# endif
287#endif /* !defined(wxUSE_ACCEL) */
288
289#ifndef wxUSE_BMPBUTTON
290# ifdef wxABORT_ON_CONFIG_ERROR
291# error "wxUSE_BMPBUTTON must be defined."
292# else
293# define wxUSE_BMPBUTTON 0
294# endif
295#endif /* !defined(wxUSE_BMPBUTTON) */
296
297#ifndef wxUSE_BUTTON
298# ifdef wxABORT_ON_CONFIG_ERROR
299# error "wxUSE_BUTTON must be defined."
300# else
301# define wxUSE_BUTTON 0
302# endif
303#endif /* !defined(wxUSE_BUTTON) */
304
305#ifndef wxUSE_CALENDARCTRL
306# ifdef wxABORT_ON_CONFIG_ERROR
307# error "wxUSE_CALENDARCTRL must be defined."
308# else
309# define wxUSE_CALENDARCTRL 0
310# endif
311#endif /* !defined(wxUSE_CALENDARCTRL) */
312
313#ifndef wxUSE_CARET
314# ifdef wxABORT_ON_CONFIG_ERROR
315# error "wxUSE_CARET must be defined."
316# else
317# define wxUSE_CARET 0
318# endif
319#endif /* !defined(wxUSE_CARET) */
320
321#ifndef wxUSE_CHECKBOX
322# ifdef wxABORT_ON_CONFIG_ERROR
323# error "wxUSE_CHECKBOX must be defined."
324# else
325# define wxUSE_CHECKBOX 0
326# endif
327#endif /* !defined(wxUSE_CHECKBOX) */
328
329#ifndef wxUSE_CHECKLISTBOX
330# ifdef wxABORT_ON_CONFIG_ERROR
331# error "wxUSE_CHECKLISTBOX must be defined."
332# else
333# define wxUSE_CHECKLISTBOX 0
334# endif
335#endif /* !defined(wxUSE_CHECKLISTBOX) */
336
337#ifndef wxUSE_CHOICE
338# ifdef wxABORT_ON_CONFIG_ERROR
339# error "wxUSE_CHOICE must be defined."
340# else
341# define wxUSE_CHOICE 0
342# endif
343#endif /* !defined(wxUSE_CHOICE) */
344
f5e0b4bc
WS
345#ifndef wxUSE_CHOICEBOOK
346# ifdef wxABORT_ON_CONFIG_ERROR
347# error "wxUSE_CHOICEBOOK must be defined."
348# else
349# define wxUSE_CHOICEBOOK 0
350# endif
351#endif /* !defined(wxUSE_CHOICEBOOK) */
352
3379ed37
VZ
353#ifndef wxUSE_CHOICEDLG
354# ifdef wxABORT_ON_CONFIG_ERROR
355# error "wxUSE_CHOICEDLG must be defined."
356# else
357# define wxUSE_CHOICEDLG 0
358# endif
359#endif /* !defined(wxUSE_CHOICEDLG) */
360
1e6feb95
VZ
361#ifndef wxUSE_CLIPBOARD
362# ifdef wxABORT_ON_CONFIG_ERROR
363# error "wxUSE_CLIPBOARD must be defined."
364# else
365# define wxUSE_CLIPBOARD 0
366# endif
367#endif /* !defined(wxUSE_CLIPBOARD) */
368
a2c0a9c5
VZ
369#ifndef wxUSE_COLOURDLG
370# ifdef wxABORT_ON_CONFIG_ERROR
371# error "wxUSE_COLOURDLG must be defined."
372# else
373# define wxUSE_COLOURDLG 0
374# endif
375#endif /* !defined(wxUSE_COLOURDLG) */
376
1e6feb95
VZ
377#ifndef wxUSE_COMBOBOX
378# ifdef wxABORT_ON_CONFIG_ERROR
379# error "wxUSE_COMBOBOX must be defined."
380# else
381# define wxUSE_COMBOBOX 0
382# endif
383#endif /* !defined(wxUSE_COMBOBOX) */
384
385#ifndef wxUSE_DATAOBJ
386# ifdef wxABORT_ON_CONFIG_ERROR
387# error "wxUSE_DATAOBJ must be defined."
388# else
389# define wxUSE_DATAOBJ 0
390# endif
391#endif /* !defined(wxUSE_DATAOBJ) */
392
337dc4c1
WS
393#ifndef wxUSE_DATEPICKCTRL
394# ifdef wxABORT_ON_CONFIG_ERROR
395# error "wxUSE_DATEPICKCTRL must be defined."
396# else
397# define wxUSE_DATEPICKCTRL 0
398# endif
399#endif /* !defined(wxUSE_DATEPICKCTRL) */
400
f8ba082e
VZ
401#ifndef wxUSE_DISPLAY
402# ifdef wxABORT_ON_CONFIG_ERROR
403# error "wxUSE_DISPLAY must be defined."
404# else
405# define wxUSE_DISPLAY 0
406# endif
407#endif /* !defined(wxUSE_DISPLAY) */
408
3379ed37
VZ
409#ifndef wxUSE_DOC_VIEW_ARCHITECTURE
410# ifdef wxABORT_ON_CONFIG_ERROR
411# error "wxUSE_DOC_VIEW_ARCHITECTURE must be defined."
412# else
413# define wxUSE_DOC_VIEW_ARCHITECTURE 0
414# endif
415#endif /* !defined(wxUSE_DOC_VIEW_ARCHITECTURE) */
416
1e6feb95
VZ
417#ifndef wxUSE_FILEDLG
418# ifdef wxABORT_ON_CONFIG_ERROR
419# error "wxUSE_FILEDLG must be defined."
420# else
421# define wxUSE_FILEDLG 0
422# endif
423#endif /* !defined(wxUSE_FILEDLG) */
424
425#ifndef wxUSE_FONTDLG
426# ifdef wxABORT_ON_CONFIG_ERROR
427# error "wxUSE_FONTDLG must be defined."
428# else
429# define wxUSE_FONTDLG 0
430# endif
431#endif /* !defined(wxUSE_FONTDLG) */
432
433#ifndef wxUSE_FONTMAP
434# ifdef wxABORT_ON_CONFIG_ERROR
435# error "wxUSE_FONTMAP must be defined."
436# else
437# define wxUSE_FONTMAP 0
438# endif
439#endif /* !defined(wxUSE_FONTMAP) */
440
441#ifndef wxUSE_GAUGE
442# ifdef wxABORT_ON_CONFIG_ERROR
443# error "wxUSE_GAUGE must be defined."
444# else
445# define wxUSE_GAUGE 0
446# endif
447#endif /* !defined(wxUSE_GAUGE) */
448
449#ifndef wxUSE_GRID
450# ifdef wxABORT_ON_CONFIG_ERROR
451# error "wxUSE_GRID must be defined."
452# else
453# define wxUSE_GRID 0
454# endif
455#endif /* !defined(wxUSE_GRID) */
456
3379ed37
VZ
457#ifndef wxUSE_HELP
458# ifdef wxABORT_ON_CONFIG_ERROR
459# error "wxUSE_HELP must be defined."
460# else
461# define wxUSE_HELP 0
462# endif
463#endif /* !defined(wxUSE_HELP) */
464
05dcbb8e
VZ
465#ifndef wxUSE_HTML
466# ifdef wxABORT_ON_CONFIG_ERROR
467# error "wxUSE_HTML must be defined."
468# else
469# define wxUSE_HTML 0
470# endif
471#endif /* !defined(wxUSE_HTML) */
472
d2ebf0b7
VS
473#ifndef wxUSE_XRC
474# ifdef wxABORT_ON_CONFIG_ERROR
475# error "wxUSE_XRC must be defined."
476# else
477# define wxUSE_XRC 0
478# endif
479#endif /* !defined(wxUSE_XRC) */
480
c839485c
VS
481#ifndef wxUSE_LIBMSPACK
482# ifndef __UNIX__
483 /* set to 0 on platforms that don't have libmspack */
484# define wxUSE_LIBMSPACK 0
485# else
486# ifdef wxABORT_ON_CONFIG_ERROR
487# error "wxUSE_LIBMSPACK must be defined."
488# else
489# define wxUSE_LIBMSPACK 0
490# endif
491# endif
492#endif /* !defined(wxUSE_LIBMSPACK) */
493
658974ae
VS
494#ifndef wxUSE_ICO_CUR
495# ifdef wxABORT_ON_CONFIG_ERROR
496# error "wxUSE_ICO_CUR must be defined."
497# else
498# define wxUSE_ICO_CUR 0
499# endif
500#endif /* !defined(wxUSE_ICO_CUR) */
501
1663afc0
VS
502#ifndef wxUSE_IFF
503# ifdef wxABORT_ON_CONFIG_ERROR
504# error "wxUSE_IFF must be defined."
505# else
506# define wxUSE_IFF 0
507# endif
508#endif /* !defined(wxUSE_IFF) */
509
1e6feb95
VZ
510#ifndef wxUSE_IMAGLIST
511# ifdef wxABORT_ON_CONFIG_ERROR
512# error "wxUSE_IMAGLIST must be defined."
513# else
514# define wxUSE_IMAGLIST 0
515# endif
516#endif /* !defined(wxUSE_IMAGLIST) */
517
2131b89d
VZ
518#ifndef wxUSE_JOYSTICK
519# ifdef wxABORT_ON_CONFIG_ERROR
520# error "wxUSE_JOYSTICK must be defined."
521# else
522# define wxUSE_JOYSTICK 0
523# endif
524#endif /* !defined(wxUSE_JOYSTICK) */
525
5b5e4f32
VZ
526#ifndef wxUSE_LISTBOOK
527# ifdef wxABORT_ON_CONFIG_ERROR
528# error "wxUSE_LISTBOOK must be defined."
529# else
530# define wxUSE_LISTBOOK 0
531# endif
532#endif /* !defined(wxUSE_LISTBOOK) */
533
1e6feb95
VZ
534#ifndef wxUSE_LISTBOX
535# ifdef wxABORT_ON_CONFIG_ERROR
536# error "wxUSE_LISTBOX must be defined."
537# else
538# define wxUSE_LISTBOX 0
539# endif
540#endif /* !defined(wxUSE_LISTBOX) */
541
542#ifndef wxUSE_LISTCTRL
543# ifdef wxABORT_ON_CONFIG_ERROR
544# error "wxUSE_LISTCTRL must be defined."
545# else
546# define wxUSE_LISTCTRL 0
547# endif
548#endif /* !defined(wxUSE_LISTCTRL) */
549
3379ed37
VZ
550#ifndef wxUSE_LOGGUI
551# ifdef wxABORT_ON_CONFIG_ERROR
552# error "wxUSE_LOGGUI must be defined."
553# else
554# define wxUSE_LOGGUI 0
555# endif
556#endif /* !defined(wxUSE_LOGGUI) */
557
558#ifndef wxUSE_LOGWINDOW
559# ifdef wxABORT_ON_CONFIG_ERROR
560# error "wxUSE_LOGWINDOW must be defined."
561# else
562# define wxUSE_LOGWINDOW 0
563# endif
564#endif /* !defined(wxUSE_LOGWINDOW) */
e421922f 565
3e6e2754
JS
566#ifndef wxUSE_LOG_DIALOG
567# ifdef wxABORT_ON_CONFIG_ERROR
568# error "wxUSE_LOG_DIALOG must be defined."
569# else
570# define wxUSE_LOG_DIALOG 0
571# endif
71908213 572#endif /* !defined(wxUSE_LOG_DIALOG) */
3e6e2754 573
efd17a1d
VZ
574#ifndef wxUSE_MDI
575# ifdef wxABORT_ON_CONFIG_ERROR
576# error "wxUSE_MDI must be defined."
577# else
578# define wxUSE_MDI 0
579# endif
580#endif /* !defined(wxUSE_MDI) */
581
1e6feb95
VZ
582#ifndef wxUSE_MDI_ARCHITECTURE
583# ifdef wxABORT_ON_CONFIG_ERROR
584# error "wxUSE_MDI_ARCHITECTURE must be defined."
585# else
586# define wxUSE_MDI_ARCHITECTURE 0
587# endif
588#endif /* !defined(wxUSE_MDI_ARCHITECTURE) */
589
590#ifndef wxUSE_MENUS
591# ifdef wxABORT_ON_CONFIG_ERROR
592# error "wxUSE_MENUS must be defined."
593# else
594# define wxUSE_MENUS 0
595# endif
596#endif /* !defined(wxUSE_MENUS) */
597
3379ed37
VZ
598#ifndef wxUSE_MSGDLG
599# ifdef wxABORT_ON_CONFIG_ERROR
600# error "wxUSE_MSGDLG must be defined."
601# else
602# define wxUSE_MSGDLG 0
603# endif
604#endif /* !defined(wxUSE_MSGDLG) */
605
1e6feb95
VZ
606#ifndef wxUSE_NOTEBOOK
607# ifdef wxABORT_ON_CONFIG_ERROR
608# error "wxUSE_NOTEBOOK must be defined."
609# else
610# define wxUSE_NOTEBOOK 0
611# endif
612#endif /* !defined(wxUSE_NOTEBOOK) */
613
d275c7eb
VZ
614#ifndef wxUSE_PALETTE
615# ifdef wxABORT_ON_CONFIG_ERROR
616# error "wxUSE_PALETTE must be defined."
617# else
618# define wxUSE_PALETTE 0
619# endif
620#endif /* !defined(wxUSE_PALETTE) */
621
1e6feb95
VZ
622#ifndef wxUSE_POPUPWIN
623# ifdef wxABORT_ON_CONFIG_ERROR
624# error "wxUSE_POPUPWIN must be defined."
625# else
626# define wxUSE_POPUPWIN 0
627# endif
628#endif /* !defined(wxUSE_POPUPWIN) */
629
3379ed37
VZ
630#ifndef wxUSE_PRINTING_ARCHITECTURE
631# ifdef wxABORT_ON_CONFIG_ERROR
632# error "wxUSE_PRINTING_ARCHITECTURE must be defined."
633# else
634# define wxUSE_PRINTING_ARCHITECTURE 0
635# endif
636#endif /* !defined(wxUSE_PRINTING_ARCHITECTURE) */
637
1e6feb95
VZ
638#ifndef wxUSE_RADIOBOX
639# ifdef wxABORT_ON_CONFIG_ERROR
640# error "wxUSE_RADIOBOX must be defined."
641# else
642# define wxUSE_RADIOBOX 0
643# endif
644#endif /* !defined(wxUSE_RADIOBOX) */
645
646#ifndef wxUSE_RADIOBTN
647# ifdef wxABORT_ON_CONFIG_ERROR
648# error "wxUSE_RADIOBTN must be defined."
649# else
650# define wxUSE_RADIOBTN 0
651# endif
652#endif /* !defined(wxUSE_RADIOBTN) */
653
654#ifndef wxUSE_SASH
655# ifdef wxABORT_ON_CONFIG_ERROR
656# error "wxUSE_SASH must be defined."
657# else
658# define wxUSE_SASH 0
659# endif
660#endif /* !defined(wxUSE_SASH) */
661
662#ifndef wxUSE_SCROLLBAR
663# ifdef wxABORT_ON_CONFIG_ERROR
664# error "wxUSE_SCROLLBAR must be defined."
665# else
666# define wxUSE_SCROLLBAR 0
667# endif
668#endif /* !defined(wxUSE_SCROLLBAR) */
669
670#ifndef wxUSE_SLIDER
671# ifdef wxABORT_ON_CONFIG_ERROR
672# error "wxUSE_SLIDER must be defined."
673# else
674# define wxUSE_SLIDER 0
675# endif
676#endif /* !defined(wxUSE_SLIDER) */
677
cad1a197
VS
678#ifndef wxUSE_SOUND
679# ifdef wxABORT_ON_CONFIG_ERROR
680# error "wxUSE_SOUND must be defined."
681# else
682# define wxUSE_SOUND 0
683# endif
684#endif /* !defined(wxUSE_SOUND) */
685
1e6feb95
VZ
686#ifndef wxUSE_SPINBTN
687# ifdef wxABORT_ON_CONFIG_ERROR
688# error "wxUSE_SPINBTN must be defined."
689# else
690# define wxUSE_SPINBTN 0
691# endif
692#endif /* !defined(wxUSE_SPINBTN) */
693
694#ifndef wxUSE_SPINCTRL
695# ifdef wxABORT_ON_CONFIG_ERROR
696# error "wxUSE_SPINCTRL must be defined."
697# else
698# define wxUSE_SPINCTRL 0
699# endif
700#endif /* !defined(wxUSE_SPINCTRL) */
701
2654a046
MB
702#ifndef wxUSE_SPLASH
703# ifdef wxABORT_ON_CONFIG_ERROR
704# error "wxUSE_SPLASH must be defined."
705# else
706# define wxUSE_SPLASH 0
707# endif
708#endif /* !defined(wxUSE_SPLASH) */
709
1e6feb95
VZ
710#ifndef wxUSE_SPLITTER
711# ifdef wxABORT_ON_CONFIG_ERROR
712# error "wxUSE_SPLITTER must be defined."
713# else
714# define wxUSE_SPLITTER 0
715# endif
716#endif /* !defined(wxUSE_SPLITTER) */
717
718#ifndef wxUSE_STATBMP
719# ifdef wxABORT_ON_CONFIG_ERROR
720# error "wxUSE_STATBMP must be defined."
721# else
722# define wxUSE_STATBMP 0
723# endif
724#endif /* !defined(wxUSE_STATBMP) */
725
726#ifndef wxUSE_STATBOX
727# ifdef wxABORT_ON_CONFIG_ERROR
728# error "wxUSE_STATBOX must be defined."
729# else
730# define wxUSE_STATBOX 0
731# endif
732#endif /* !defined(wxUSE_STATBOX) */
733
734#ifndef wxUSE_STATLINE
735# ifdef wxABORT_ON_CONFIG_ERROR
736# error "wxUSE_STATLINE must be defined."
737# else
738# define wxUSE_STATLINE 0
739# endif
740#endif /* !defined(wxUSE_STATLINE) */
741
3379ed37
VZ
742#ifndef wxUSE_STATTEXT
743# ifdef wxABORT_ON_CONFIG_ERROR
744# error "wxUSE_STATTEXT must be defined."
745# else
746# define wxUSE_STATTEXT 0
747# endif
748#endif /* !defined(wxUSE_STATTEXT) */
749
1e6feb95
VZ
750#ifndef wxUSE_STATUSBAR
751# ifdef wxABORT_ON_CONFIG_ERROR
752# error "wxUSE_STATUSBAR must be defined."
753# else
754# define wxUSE_STATUSBAR 0
755# endif
756#endif /* !defined(wxUSE_STATUSBAR) */
757
1e6feb95
VZ
758#ifndef wxUSE_TAB_DIALOG
759# ifdef wxABORT_ON_CONFIG_ERROR
760# error "wxUSE_TAB_DIALOG must be defined."
761# else
762# define wxUSE_TAB_DIALOG 0
763# endif
764#endif /* !defined(wxUSE_TAB_DIALOG) */
765
766#ifndef wxUSE_TEXTCTRL
767# ifdef wxABORT_ON_CONFIG_ERROR
768# error "wxUSE_TEXTCTRL must be defined."
769# else
770# define wxUSE_TEXTCTRL 0
771# endif
772#endif /* !defined(wxUSE_TEXTCTRL) */
773
f38bcae5
VZ
774#ifndef wxUSE_TIPWINDOW
775# ifdef wxABORT_ON_CONFIG_ERROR
776# error "wxUSE_TIPWINDOW must be defined."
777# else
778# define wxUSE_TIPWINDOW 0
779# endif
780#endif /* !defined(wxUSE_TIPWINDOW) */
781
1e6feb95
VZ
782#ifndef wxUSE_TOOLBAR
783# ifdef wxABORT_ON_CONFIG_ERROR
784# error "wxUSE_TOOLBAR must be defined."
785# else
786# define wxUSE_TOOLBAR 0
787# endif
788#endif /* !defined(wxUSE_TOOLBAR) */
789
790#ifndef wxUSE_TOOLTIPS
791# ifdef wxABORT_ON_CONFIG_ERROR
792# error "wxUSE_TOOLTIPS must be defined."
793# else
794# define wxUSE_TOOLTIPS 0
795# endif
796#endif /* !defined(wxUSE_TOOLTIPS) */
797
798#ifndef wxUSE_TREECTRL
799# ifdef wxABORT_ON_CONFIG_ERROR
800# error "wxUSE_TREECTRL must be defined."
801# else
802# define wxUSE_TREECTRL 0
803# endif
804#endif /* !defined(wxUSE_TREECTRL) */
805
f8ba082e 806#ifndef wxUSE_VALIDATORS
12491c1f 807# ifdef wxABORT_ON_CONFIG_ERROR
f8ba082e 808# error "wxUSE_VALIDATORS must be defined."
12491c1f 809# else
f8ba082e 810# define wxUSE_VALIDATORS 0
12491c1f 811# endif
f8ba082e 812#endif /* !defined(wxUSE_VALIDATORS) */
12491c1f 813
3379ed37
VZ
814#ifndef wxUSE_WXHTML_HELP
815# ifdef wxABORT_ON_CONFIG_ERROR
816# error "wxUSE_WXHTML_HELP must be defined."
817# else
818# define wxUSE_WXHTML_HELP 0
819# endif
820#endif /* !defined(wxUSE_WXHTML_HELP) */
821
a5d46b73 822#endif /* wxUSE_GUI */
c4d596ea 823
1e6feb95
VZ
824/*
825 check consistency of the settings
826 */
a5d46b73 827
0c46d866
VZ
828#if wxUSE_CRASHREPORT && !wxUSE_ON_FATAL_EXCEPTION
829# ifdef wxABORT_ON_CONFIG_ERROR
830# error "wxUSE_CRASHREPORT requires wxUSE_ON_FATAL_EXCEPTION"
831# else
832# undef wxUSE_CRASHREPORT
833# define wxUSE_CRASHREPORT 0
834# endif
835#endif /* wxUSE_CRASHREPORT */
836
a5d46b73
VZ
837#if wxUSE_PROTOCOL_FILE || wxUSE_PROTOCOL_FTP || wxUSE_PROTOCOL_HTTP
838# if !wxUSE_PROTOCOL
839# ifdef wxABORT_ON_CONFIG_ERROR
840# error "wxUSE_PROTOCOL_XXX requires wxUSE_PROTOCOL"
841# else
842# undef wxUSE_PROTOCOL
843# define wxUSE_PROTOCOL 1
844# endif
845# endif
846#endif /* wxUSE_PROTOCOL_XXX */
847
848#if wxUSE_URL
849# if !wxUSE_PROTOCOL
850# ifdef wxABORT_ON_CONFIG_ERROR
851# error "wxUSE_URL requires wxUSE_PROTOCOL"
852# else
853# undef wxUSE_PROTOCOL
854# define wxUSE_PROTOCOL 1
855# endif
856# endif
857#endif /* wxUSE_URL */
858
859#if wxUSE_PROTOCOL
860# if !wxUSE_SOCKETS
861# if wxUSE_PROTOCOL_HTTP || wxUSE_PROTOCOL_FTP
862# ifdef wxABORT_ON_CONFIG_ERROR
863# error "wxUSE_PROTOCOL_FTP/HTTP requires wxUSE_SOCKETS"
864# else
865# undef wxUSE_SOCKETS
866# define wxUSE_SOCKETS 1
867# endif
868# endif
869# endif
870
871# if !wxUSE_STREAMS
872# ifdef wxABORT_ON_CONFIG_ERROR
873# error "wxUSE_PROTOCOL requires wxUSE_STREAMS"
874# else
875# undef wxUSE_STREAMS
876# define wxUSE_STREAMS 1
877# endif
878# endif
879#endif /* wxUSE_PROTOCOL */
880
c7f3eecc
VZ
881/* have to test for wxUSE_HTML before wxUSE_FILESYSTEM */
882#if wxUSE_HTML
883# if !wxUSE_FILESYSTEM
884# ifdef wxABORT_ON_CONFIG_ERROR
885# error "wxHTML requires wxFileSystem"
886# else
887# undef wxUSE_FILESYSTEM
888# define wxUSE_FILESYSTEM 1
889# endif
890# endif
891#endif /* wxUSE_HTML */
892
893#if wxUSE_FILESYSTEM
894# if !wxUSE_STREAMS
895# ifdef wxABORT_ON_CONFIG_ERROR
896# error "wxUSE_FILESYSTEM requires wxUSE_STREAMS"
897# else
898# undef wxUSE_STREAMS
899# define wxUSE_STREAMS 1
900# endif
901# endif
902#endif /* wxUSE_FILESYSTEM */
903
ce73e654
VS
904#if wxUSE_FS_INET
905# if !wxUSE_PROTOCOL
906# ifdef wxABORT_ON_CONFIG_ERROR
907# error "wxUSE_FS_INET requires wxUSE_PROTOCOL"
908# else
909# undef wxUSE_PROTOCOL
910# define wxUSE_PROTOCOL 1
911# endif
912# endif
913#endif /* wxUSE_FS_INET */
914
c7f3eecc 915#if wxUSE_STOPWATCH || wxUSE_DATETIME
a5d46b73
VZ
916# if !wxUSE_LONGLONG
917# ifdef wxABORT_ON_CONFIG_ERROR
c7f3eecc 918# error "wxUSE_STOPWATCH and wxUSE_DATETIME require wxUSE_LONGLONG"
a5d46b73
VZ
919# else
920# undef wxUSE_LONGLONG
921# define wxUSE_LONGLONG 1
922# endif
923# endif
924#endif /* wxUSE_STOPWATCH */
925
926#if wxUSE_MIMETYPE && !wxUSE_TEXTFILE
927# ifdef wxABORT_ON_CONFIG_ERROR
928# error "wxUSE_MIMETYPE requires wxUSE_TEXTFILE"
929# else
930# undef wxUSE_TEXTFILE
931# define wxUSE_TEXTFILE 1
932# endif
933#endif /* wxUSE_MIMETYPE */
934
935#if wxUSE_TEXTFILE && !wxUSE_TEXTBUFFER
936# ifdef wxABORT_ON_CONFIG_ERROR
937# error "wxUSE_TEXTFILE requires wxUSE_TEXTBUFFER"
938# else
939# undef wxUSE_TEXTBUFFER
940# define wxUSE_TEXTBUFFER 1
941# endif
942#endif /* wxUSE_TEXTFILE */
943
944#if wxUSE_TEXTFILE && !wxUSE_FILE
945# ifdef wxABORT_ON_CONFIG_ERROR
946# error "wxUSE_TEXTFILE requires wxUSE_FILE"
947# else
948# undef wxUSE_FILE
949# define wxUSE_FILE 1
950# endif
951#endif /* wxUSE_TEXTFILE */
952
953#if wxUSE_UNICODE_MSLU && !wxUSE_UNICODE
954# ifdef wxABORT_ON_CONFIG_ERROR
955# error "wxUSE_UNICODE_MSLU requires wxUSE_UNICODE"
956# else
957# undef wxUSE_UNICODE
958# define wxUSE_UNICODE 1
959# endif
960#endif /* wxUSE_UNICODE_MSLU */
961
7f799744
VS
962#if wxUSE_XML && !wxUSE_WCHAR_T
963# ifdef wxABORT_ON_CONFIG_ERROR
964# error "wxUSE_XML requires wxUSE_WCHAR_T"
965# else
966# undef wxUSE_XML
967# define wxUSE_XML 0
968# endif
969#endif /* wxUSE_UNICODE_MSLU */
970
1948bb32
VS
971#if !wxUSE_DYNLIB_CLASS
972# if wxUSE_DYNAMIC_LOADER
973# ifdef wxABORT_ON_CONFIG_ERROR
974# error "wxUSE_DYNAMIC_LOADER requires wxUSE_DYNLIB_CLASS."
975# else
976# define wxUSE_DYNLIB_CLASS 1
977# endif
978# endif
979#endif /* wxUSE_DYNLIB_CLASS */
980
81f90336
MW
981#if wxUSE_ZIPSTREAM
982# if !wxUSE_ZLIB
983# ifdef wxABORT_ON_CONFIG_ERROR
984# error "wxZip requires wxZlib"
985# else
986# undef wxUSE_ZLIB
987# define wxUSE_ZLIB 1
988# endif
989# endif
9e8e867f 990# if !wxUSE_ARCHIVE_STREAMS
81f90336
MW
991# ifdef wxABORT_ON_CONFIG_ERROR
992# error "wxZip requires wxArchive"
993# else
9e8e867f
MW
994# undef wxUSE_ARCHIVE_STREAMS
995# define wxUSE_ARCHIVE_STREAMS 1
81f90336
MW
996# endif
997# endif
998#endif /* wxUSE_ZIPSTREAM */
999
a5d46b73
VZ
1000/* the rest of the tests is for the GUI settings only */
1001#if wxUSE_GUI
1002
1e6feb95
VZ
1003#if wxUSE_BUTTON || \
1004 wxUSE_CALENDARCTRL || \
1005 wxUSE_CARET || \
1006 wxUSE_COMBOBOX || \
1007 wxUSE_BMPBUTTON || \
1008 wxUSE_CHECKBOX || \
1009 wxUSE_CHECKLISTBOX || \
1010 wxUSE_CHOICE || \
1011 wxUSE_GAUGE || \
1012 wxUSE_GRID || \
1e6feb95
VZ
1013 wxUSE_LISTBOX || \
1014 wxUSE_LISTCTRL || \
1015 wxUSE_NOTEBOOK || \
1016 wxUSE_RADIOBOX || \
1017 wxUSE_RADIOBTN || \
1018 wxUSE_SCROLLBAR || \
1019 wxUSE_SLIDER || \
1020 wxUSE_SPINBTN || \
1021 wxUSE_SPINCTRL || \
1022 wxUSE_STATBMP || \
1023 wxUSE_STATBOX || \
1024 wxUSE_STATLINE || \
3379ed37 1025 wxUSE_STATTEXT || \
1e6feb95
VZ
1026 wxUSE_STATUSBAR || \
1027 wxUSE_TEXTCTRL || \
1028 wxUSE_TOOLBAR || \
1029 wxUSE_TREECTRL
1030# if !wxUSE_CONTROLS
1031# ifdef wxABORT_ON_CONFIG_ERROR
1032# error "wxUSE_CONTROLS unset but some controls used"
1033# else
1034# undef wxUSE_CONTROLS
1035# define wxUSE_CONTROLS 1
1036# endif
1037# endif
1038#endif /* controls */
1039
0b4f47a3
DS
1040#if wxUSE_BMPBUTTON
1041# if !wxUSE_BUTTON
1042# ifdef wxABORT_ON_CONFIG_ERROR
1043# error "wxUSE_BMPBUTTON requires wxUSE_BUTTON"
1044# else
1045# undef wxUSE_BUTTON
1046# define wxUSE_BUTTON 1
1047# endif
1048# endif
1049#endif /* wxUSE_BMPBUTTON */
1050
f5e0b4bc 1051#if wxUSE_NOTEBOOK || wxUSE_LISTBOOK || wxUSE_CHOICEBOOK
15aad3b9
VZ
1052# if defined(wxUSE_BOOKCTRL) && !wxUSE_BOOKCTRL
1053# ifdef wxABORT_ON_CONFIG_ERROR
1054# error "wxUSE_BOOKCTRL must be set."
1055# else
1056# undef wxUSE_BOOKCTRL
1057# endif
1058# endif
1059
1060# ifndef wxUSE_BOOKCTRL
1061# define wxUSE_BOOKCTRL 1
1062# endif
1063#endif /* wxUSE_NOTEBOOK */
1064
5b5e4f32
VZ
1065#if wxUSE_LISTBOOK
1066# if !wxUSE_LISTCTRL
1067# ifdef wxABORT_ON_CONFIG_ERROR
1068# error "wxListbook requires wxListCtrl"
1069# else
1070# undef wxUSE_LISTCTRL
1071# define wxUSE_LISTCTRL 1
1072# endif
1073# endif
1074#endif /* wxUSE_LISTBOOK */
1075
f5e0b4bc
WS
1076#if wxUSE_CHOICEBOOK
1077# if !wxUSE_CHOICE
1078# ifdef wxABORT_ON_CONFIG_ERROR
1079# error "wxChoicebook requires wxChoice"
1080# else
1081# undef wxUSE_CHOICE
1082# define wxUSE_CHOICE 1
1083# endif
1084# endif
1085#endif /* wxUSE_CHOICEBOOK */
1086
da4486fb
VZ
1087/* don't attempt to use native status bar on the platforms not having it */
1088#ifndef wxUSE_NATIVE_STATUSBAR
1089# define wxUSE_NATIVE_STATUSBAR 0
1090#elif wxUSE_NATIVE_STATUSBAR
b08cd3bf
WS
1091# if defined(__WXUNIVERSAL__) || !( defined(__WXMSW__) || \
1092 defined(__WXMAC__) || \
1093 defined(__WXPALMOS__) )
da4486fb
VZ
1094# undef wxUSE_NATIVE_STATUSBAR
1095# define wxUSE_NATIVE_STATUSBAR 0
1096# endif
1097#endif
1098
3379ed37
VZ
1099/* wxUniv-specific dependencies */
1100#if defined(__WXUNIVERSAL__)
1101# if (wxUSE_COMBOBOX || wxUSE_MENUS) && !wxUSE_POPUPWIN
1102# ifdef wxABORT_ON_CONFIG_ERROR
1103# error "wxUSE_POPUPWIN must be defined to use comboboxes/menus"
1104# else
1105# undef wxUSE_POPUPWIN
1106# define wxUSE_POPUPWIN 1
1107# endif
1108# endif
1109
1110# if wxUSE_COMBOBOX
1111# if !wxUSE_LISTBOX
1112# ifdef wxABORT_ON_CONFIG_ERROR
1113# error "wxComboBox requires wxListBox in wxUniversal"
1114# else
1115# undef wxUSE_LISTBOX
1116# define wxUSE_LISTBOX 1
1117# endif
1118# endif
1119# endif /* wxUSE_COMBOBOX */
1120
1121# if wxUSE_RADIOBTN
1122# if !wxUSE_CHECKBOX
1123# ifdef wxABORT_ON_CONFIG_ERROR
1124# error "wxUSE_RADIOBTN requires wxUSE_CHECKBOX in wxUniversal"
1125# else
1126# undef wxUSE_CHECKBOX
1127# define wxUSE_CHECKBOX 1
1128# endif
1129# endif
1130# endif /* wxUSE_RADIOBTN */
1131
1132# if wxUSE_TEXTCTRL
1133# if !wxUSE_CARET
1134# ifdef wxABORT_ON_CONFIG_ERROR
1135# error "wxTextCtrl requires wxCaret in wxUniversal"
1136# else
1137# undef wxUSE_CARET
1138# define wxUSE_CARET 1
1139# endif
1140# endif /* wxUSE_CARET */
1141
1142# if !wxUSE_SCROLLBAR
1143# ifdef wxABORT_ON_CONFIG_ERROR
1144# error "wxTextCtrl requires wxScrollBar in wxUniversal"
1145# else
1146# undef wxUSE_SCROLLBAR
1147# define wxUSE_SCROLLBAR 1
1148# endif
1149# endif /* wxUSE_SCROLLBAR */
1150# endif /* wxUSE_TEXTCTRL */
1151#endif /* __WXUNIVERSAL__ */
1152
1153/* wxGTK-specific dependencies */
2131b89d
VZ
1154#ifdef __WXGTK__
1155# ifndef __WXUNIVERSAL__
1156# if wxUSE_MDI_ARCHITECTURE && !wxUSE_MENUS
1157# ifdef wxABORT_ON_CONFIG_ERROR
1158# error "MDI requires wxUSE_MENUS in wxGTK"
1159# else
1160# undef wxUSE_MENUS
1161# define wxUSE_MENUS 1
1162# endif
1163# endif
1164# endif /* !__WXUNIVERSAL__ */
1165
1166# if wxUSE_JOYSTICK
1167# if !wxUSE_THREADS
1168# ifdef wxABORT_ON_CONFIG_ERROR
1169# error "wxJoystick requires threads in wxGTK"
1170# else
1171# undef wxUSE_JOYSTICK
1172# define wxUSE_JOYSTICK 0
1173# endif
3379ed37
VZ
1174# endif
1175# endif
1176#endif /* wxGTK && !wxUniv */
1177
03169422
RL
1178/* wxMSW-specific dependencies */
1179#ifdef __WXMSW__
1180# ifndef wxUSE_UNICODE_MSLU
1181# ifdef wxABORT_ON_CONFIG_ERROR
1182# error "wxUSE_UNICODE_MSLU must be defined."
1183# else
1184# define wxUSE_UNICODE_MSLU 0
1185# endif
1186# endif /* wxUSE_UNICODE_MSLU */
9c7f7573
VS
1187# ifndef wxUSE_UXTHEME
1188# ifdef wxABORT_ON_CONFIG_ERROR
1189# error "wxUSE_UXTHEME must be defined."
1190# else
1191# define wxUSE_UXTHEME 0
1192# endif
1193# endif /* wxUSE_UXTHEME */
1194# ifndef wxUSE_UXTHEME_AUTO
1195# ifdef wxABORT_ON_CONFIG_ERROR
1196# error "wxUSE_UXTHEME_AUTO must be defined."
1197# else
1198# define wxUSE_UXTHEME_AUTO 0
1199# endif
1200# endif /* wxUSE_UXTHEME_AUTO */
03169422
RL
1201# ifndef wxUSE_MS_HTML_HELP
1202# ifdef wxABORT_ON_CONFIG_ERROR
1203# error "wxUSE_MS_HTML_HELP must be defined."
1204# else
1205# define wxUSE_MS_HTML_HELP 0
1206# endif
1207# endif /* !defined(wxUSE_MS_HTML_HELP) */
1208# ifndef wxUSE_DIALUP_MANAGER
1209# ifdef wxABORT_ON_CONFIG_ERROR
1210# error "wxUSE_DIALUP_MANAGER must be defined."
1211# else
1212# define wxUSE_DIALUP_MANAGER 0
1213# endif
1214# endif /* !defined(wxUSE_DIALUP_MANAGER) */
1215
19f478fd 1216# if !wxUSE_DYNAMIC_LOADER
03169422
RL
1217# if wxUSE_MS_HTML_HELP
1218# ifdef wxABORT_ON_CONFIG_ERROR
1219# error "wxUSE_MS_HTML_HELP requires wxUSE_DYNAMIC_LOADER."
1220# else
1221# define wxUSE_DYNAMIC_LOADER 1
1222# endif
1223# endif
1224# if wxUSE_DIALUP_MANAGER
1225# ifdef wxABORT_ON_CONFIG_ERROR
1226# error "wxUSE_DIALUP_MANAGER requires wxUSE_DYNAMIC_LOADER."
1227# else
1228# define wxUSE_DYNAMIC_LOADER 1
1229# endif
1230# endif
1231# endif /* wxUSE_DYNAMIC_LOADER */
7efaa702 1232
03169422
RL
1233#endif /* wxMSW */
1234
bfc4a1c1
VS
1235/* wxMGL-specific dependencies */
1236#ifdef __WXMGL__
1237# if !wxUSE_PALETTE
1238# error "wxMGL requires wxUSE_PALETTE=1"
1239# endif
1240#endif /* wxMGL */
1241
67e489c5 1242/* Hopefully we can emulate these dialogs in due course */
9b141468 1243#if defined(__SMARTPHONE__) && defined(__WXWINCE__)
b92203a8
VZ
1244# ifdef wxUSE_COLOURDLG
1245# undef wxUSE_COLOURDLG
1246# define wxUSE_COLOURDLG 0
1247# endif
9b141468 1248#endif /* __SMARTPHONE__ && __WXWINCE__ */
b92203a8
VZ
1249
1250
3379ed37
VZ
1251/* generic controls dependencies */
1252#if !defined(__WXMSW__) || defined(__WXUNIVERSAL__)
1253# if wxUSE_FONTDLG || wxUSE_FILEDLG || wxUSE_CHOICEDLG
1254 /* all common controls are needed by these dialogs */
1255# if !defined(wxUSE_CHOICE) || \
1256 !defined(wxUSE_TEXTCTRL) || \
1257 !defined(wxUSE_BUTTON) || \
1258 !defined(wxUSE_CHECKBOX) || \
1259 !defined(wxUSE_STATTEXT)
1260# ifdef wxABORT_ON_CONFIG_ERROR
1261# error "These common controls are needed by common dialogs"
1262# else
1263# undef wxUSE_CHOICE
1264# define wxUSE_CHOICE 1
1265# undef wxUSE_TEXTCTRL
1266# define wxUSE_TEXTCTRL 1
1267# undef wxUSE_BUTTON
1268# define wxUSE_BUTTON 1
1269# undef wxUSE_CHECKBOX
1270# define wxUSE_CHECKBOX 1
1271# undef wxUSE_STATTEXT
1272# define wxUSE_STATTEXT 1
1273# endif
1274# endif
1275# endif
1276#endif /* !wxMSW || wxUniv */
1277
1278/* common dependencies */
1e6feb95
VZ
1279#if wxUSE_CALENDARCTRL
1280# if !(wxUSE_SPINBTN && wxUSE_COMBOBOX)
1281# ifdef wxABORT_ON_CONFIG_ERROR
1282# error "wxCalendarCtrl requires wxSpinButton and wxComboBox"
1283# else
1284# undef wxUSE_SPINBTN
1285# undef wxUSE_COMBOBOX
1286# define wxUSE_SPINBTN 1
1287# define wxUSE_COMBOBOX 1
1288# endif
1289# endif
e2b87f38
VZ
1290
1291# if !wxUSE_DATETIME
1292# ifdef wxABORT_ON_CONFIG_ERROR
1293# error "wxCalendarCtrl requires wxUSE_DATETIME"
1294# else
1295# undef wxUSE_DATETIME
1296# define wxUSE_DATETIME 1
1297# endif
1298# endif
1e6feb95
VZ
1299#endif /* wxUSE_CALENDARCTRL */
1300
324eeecb
WS
1301#if wxUSE_DATEPICKCTRL
1302# if !wxUSE_DATETIME
1303# ifdef wxABORT_ON_CONFIG_ERROR
60bea0cf 1304# error "wxDatePickerCtrl requires wxUSE_DATETIME"
324eeecb
WS
1305# else
1306# undef wxUSE_DATETIME
1307# define wxUSE_DATETIME 1
1308# endif
1309# endif
1310#endif /* wxUSE_DATEPICKCTRL */
1311
1e6feb95
VZ
1312#if wxUSE_CHECKLISTBOX
1313# if !wxUSE_LISTBOX
1314# ifdef wxABORT_ON_CONFIG_ERROR
1315# error "wxCheckListBox requires wxListBox"
1316# else
1317# undef wxUSE_LISTBOX
1318# define wxUSE_LISTBOX 1
1319# endif
1320# endif
97e4cf6d
WS
1321#endif /* wxUSE_CHECKLISTBOX */
1322
1323#if wxUSE_CHOICEDLG
1324# if !wxUSE_LISTBOX
1325# ifdef wxABORT_ON_CONFIG_ERROR
1326# error "Choice dialogs requires wxListBox"
1327# else
1328# undef wxUSE_LISTBOX
1329# define wxUSE_LISTBOX 1
1330# endif
1331# endif
1332#endif /* wxUSE_CHOICEDLG */
1e6feb95 1333
0b4f47a3
DS
1334#if wxUSE_HELP
1335# if !wxUSE_BMPBUTTON
1336# ifdef wxABORT_ON_CONFIG_ERROR
1337# error "wxUSE_HELP requires wxUSE_BMPBUTTON"
1338# else
1339# undef wxUSE_BMPBUTTON
1340# define wxUSE_BMPBUTTON 1
1341# endif
1342# endif
adb799d6
DS
1343
1344# if !wxUSE_CHOICEDLG
1345# ifdef wxABORT_ON_CONFIG_ERROR
1346# error "wxUSE_HELP requires wxUSE_CHOICEDLG"
1347# else
1348# undef wxUSE_CHOICEDLG
1349# define wxUSE_CHOICEDLG 1
1350# endif
1351# endif
0b4f47a3
DS
1352#endif /* wxUSE_HELP */
1353
3379ed37 1354#if wxUSE_WXHTML_HELP
0e871ad0 1355# if !wxUSE_HELP || !wxUSE_HTML || !wxUSE_COMBOBOX || !wxUSE_NOTEBOOK || !wxUSE_SPINCTRL
3379ed37
VZ
1356# ifdef wxABORT_ON_CONFIG_ERROR
1357# error "Built in help controller can't be compiled"
1358# else
1359# undef wxUSE_HELP
1360# define wxUSE_HELP 1
1361# undef wxUSE_HTML
1362# define wxUSE_HTML 1
1363# undef wxUSE_COMBOBOX
1364# define wxUSE_COMBOBOX 1
730dfeb4
VS
1365# undef wxUSE_NOTEBOOK
1366# define wxUSE_NOTEBOOK 1
0e871ad0
WS
1367# undef wxUSE_SPINCTRL
1368# define wxUSE_SPINCTRL 1
3379ed37
VZ
1369# endif
1370# endif
1371#endif /* wxUSE_WXHTML_HELP */
1372
05e4fd64
DS
1373#if !wxUSE_IMAGE
1374/*
1375 The default wxUSE_IMAGE setting is 1, so if it's set to 0 we assume the
1376 user explicitly wants this and disable all other features that require
1377 wxUSE_IMAGE.
1378 */
1379# if wxUSE_DRAGIMAGE
1380# ifdef wxABORT_ON_CONFIG_ERROR
1381# error "wxUSE_DRAGIMAGE requires wxUSE_IMAGE"
1382# else
1383# undef wxUSE_DRAGIMAGE
1384# define wxUSE_DRAGIMAGE 0
1385# endif
1386# endif
1387
1388# if wxUSE_LIBPNG
1389# ifdef wxABORT_ON_CONFIG_ERROR
1390# error "wxUSE_LIBPNG requires wxUSE_IMAGE"
1391# else
1392# undef wxUSE_LIBPNG
1393# define wxUSE_LIBPNG 0
1394# endif
1395# endif
1396
1397# if wxUSE_LIBJPEG
1398# ifdef wxABORT_ON_CONFIG_ERROR
1399# error "wxUSE_LIBJPEG requires wxUSE_IMAGE"
1400# else
1401# undef wxUSE_LIBJPEG
1402# define wxUSE_LIBJPEG 0
1403# endif
1404# endif
1405
1406# if wxUSE_LIBTIFF
1407# ifdef wxABORT_ON_CONFIG_ERROR
1408# error "wxUSE_LIBTIFF requires wxUSE_IMAGE"
1409# else
1410# undef wxUSE_LIBTIFF
1411# define wxUSE_LIBTIFF 0
1412# endif
1413# endif
1414
1415# if wxUSE_GIF
1416# ifdef wxABORT_ON_CONFIG_ERROR
1417# error "wxUSE_GIF requires wxUSE_IMAGE"
1418# else
1419# undef wxUSE_GIF
1420# define wxUSE_GIF 0
1421# endif
1422# endif
1423
1424# if wxUSE_PNM
1425# ifdef wxABORT_ON_CONFIG_ERROR
1426# error "wxUSE_PNM requires wxUSE_IMAGE"
1427# else
1428# undef wxUSE_PNM
1429# define wxUSE_PNM 0
1430# endif
1431# endif
1432
1433# if wxUSE_PCX
1434# ifdef wxABORT_ON_CONFIG_ERROR
1435# error "wxUSE_PCX requires wxUSE_IMAGE"
1436# else
1437# undef wxUSE_PCX
1438# define wxUSE_PCX 0
1439# endif
1440# endif
1441
1442# if wxUSE_IFF
1443# ifdef wxABORT_ON_CONFIG_ERROR
1444# error "wxUSE_IFF requires wxUSE_IMAGE"
1445# else
1446# undef wxUSE_IFF
1447# define wxUSE_IFF 0
1448# endif
1449# endif
1450
1451# if wxUSE_TOOLBAR
1452# ifdef wxABORT_ON_CONFIG_ERROR
1453# error "wxUSE_TOOLBAR requires wxUSE_IMAGE"
1454# else
1455# undef wxUSE_TOOLBAR
1456# define wxUSE_TOOLBAR 0
1457# endif
1458# endif
1459
1460# if wxUSE_XPM
1461# ifdef wxABORT_ON_CONFIG_ERROR
1462# error "wxUSE_XPM requires wxUSE_IMAGE"
1463# else
1464# undef wxUSE_XPM
1465# define wxUSE_XPM 0
1466# endif
1467# endif
1468
1469#endif /* !wxUSE_IMAGE */
1470
e30285ab
VZ
1471#if wxUSE_DOC_VIEW_ARCHITECTURE
1472# if !wxUSE_MENUS
1473# ifdef wxABORT_ON_CONFIG_ERROR
1474# error "DocView requires wxUSE_MENUS"
1475# else
1476# undef wxUSE_MENUS
1477# define wxUSE_MENUS 1
1478# endif
1479# endif
1480
adb799d6
DS
1481# if !wxUSE_CHOICEDLG
1482# ifdef wxABORT_ON_CONFIG_ERROR
1483# error "DocView requires wxUSE_CHOICEDLG"
1484# else
1485# undef wxUSE_CHOICEDLG
1486# define wxUSE_CHOICEDLG 1
1487# endif
1488# endif
1489
e30285ab
VZ
1490# if !wxUSE_STREAMS && !wxUSE_STD_IOSTREAM
1491# ifdef wxABORT_ON_CONFIG_ERROR
1492# error "DocView requires wxUSE_STREAMS or wxUSE_STD_IOSTREAM"
1493# else
1494# undef wxUSE_STREAMS
1495# define wxUSE_STREAMS 1
1496# endif
1497# endif
1498#endif /* wxUSE_DOC_VIEW_ARCHITECTURE */
1499
3379ed37
VZ
1500#if wxUSE_PRINTING_ARCHITECTURE
1501# if !wxUSE_COMBOBOX
1502# ifdef wxABORT_ON_CONFIG_ERROR
1503# error "Print dialog requires wxUSE_COMBOBOX"
1504# else
1505# undef wxUSE_COMBOBOX
1506# define wxUSE_COMBOBOX 1
1507# endif
1508# endif
1509#endif /* wxUSE_PRINTING_ARCHITECTURE */
1510
e30285ab 1511#if wxUSE_MDI_ARCHITECTURE
efd17a1d
VZ
1512# if !wxUSE_MDI
1513# ifdef wxABORT_ON_CONFIG_ERROR
1514# error "MDI requires wxUSE_MDI"
1515# else
1516# undef wxUSE_MDI
1517# define wxUSE_MDI 1
1518# endif
1519# endif
1520
e30285ab 1521# if !wxUSE_DOC_VIEW_ARCHITECTURE
1e6feb95 1522# ifdef wxABORT_ON_CONFIG_ERROR
e30285ab 1523# error "MDI requires wxUSE_DOC_VIEW_ARCHITECTURE"
1e6feb95 1524# else
e30285ab
VZ
1525# undef wxUSE_DOC_VIEW_ARCHITECTURE
1526# define wxUSE_DOC_VIEW_ARCHITECTURE 1
1e6feb95
VZ
1527# endif
1528# endif
e30285ab 1529#endif /* wxUSE_MDI_ARCHITECTURE */
1e6feb95
VZ
1530
1531#if !wxUSE_FILEDLG
2119e280 1532# if wxUSE_DOC_VIEW_ARCHITECTURE || wxUSE_WXHTML_HELP
1e6feb95
VZ
1533# ifdef wxABORT_ON_CONFIG_ERROR
1534# error "wxFileDialog must be compiled as well"
1535# else
1536# undef wxUSE_FILEDLG
1537# define wxUSE_FILEDLG 1
1538# endif
1539# endif
e421922f 1540#endif /* wxUSE_FILEDLG */
1e6feb95 1541
555f645a
WS
1542#if !wxUSE_GAUGE || !wxUSE_BUTTON
1543# if wxUSE_PROGRESSDLG && !defined(__WXPALMOS__)
063b752e 1544# ifdef wxABORT_ON_CONFIG_ERROR
555f645a 1545# error "Generic progress dialog requires wxUSE_GAUGE and wxUSE_BUTTON"
063b752e
WS
1546# else
1547# undef wxUSE_GAUGE
555f645a 1548# undef wxUSE_BUTTON
063b752e 1549# define wxUSE_GAUGE 1
555f645a 1550# define wxUSE_BUTTON 1
063b752e
WS
1551# endif
1552# endif
1553#endif /* !wxUSE_GAUGE */
1554
0b4f47a3 1555#if !wxUSE_BUTTON
555f645a 1556# if wxUSE_FONTDLG || \
0b4f47a3
DS
1557 wxUSE_FILEDLG || \
1558 wxUSE_CHOICEDLG || \
1559 wxUSE_NUMBERDLG || \
1560 wxUSE_TEXTDLG || \
1561 wxUSE_DIRDLG || \
1562 wxUSE_STARTUP_TIPS || \
1563 wxUSE_WIZARDDLG
1564# ifdef wxABORT_ON_CONFIG_ERROR
1565# error "Common and generic dialogs require wxUSE_BUTTON"
1566# else
1567# undef wxUSE_BUTTON
1568# define wxUSE_BUTTON 1
1569# endif
1570# endif
063b752e 1571#endif /* !wxUSE_BUTTON */
0b4f47a3 1572
12491c1f
JS
1573#if !wxUSE_TOOLBAR
1574# if wxUSE_TOOLBAR_NATIVE
1575# ifdef wxABORT_ON_CONFIG_ERROR
1576# error "wxUSE_TOOLBAR is set to 0 but wxUSE_TOOLBAR_NATIVE is set to 1"
1577# else
1578# undef wxUSE_TOOLBAR_NATIVE
1579# define wxUSE_TOOLBAR_NATIVE 0
1580# endif
1581# endif
1582
1583# if wxUSE_TOOLBAR_SIMPLE
1584# ifdef wxABORT_ON_CONFIG_ERROR
1585# error "wxUSE_TOOLBAR is set to 0 but wxUSE_TOOLBAR_SIMPLE is set to 1"
1586# else
1587# undef wxUSE_TOOLBAR_SIMPLE
1588# define wxUSE_TOOLBAR_SIMPLE 0
1589# endif
1590# endif
1591#endif
1592
1e6feb95
VZ
1593#if !wxUSE_IMAGLIST
1594# if wxUSE_TREECTRL || wxUSE_NOTEBOOK || wxUSE_LISTCTRL
1595# ifdef wxABORT_ON_CONFIG_ERROR
1596# error "wxImageList must be compiled as well"
1597# else
1598# undef wxUSE_IMAGLIST
1599# define wxUSE_IMAGLIST 1
1600# endif
1601# endif
1602#endif /* !wxUSE_IMAGLIST */
1603
e421922f
VZ
1604#if !wxUSE_MSGDLG
1605# ifdef wxABORT_ON_CONFIG_ERROR
1606 /* FIXME: should compile without it, of course, but doesn't */
1607# error "wxMessageBox is always needed"
1608# else
1609# undef wxUSE_MSGDLG
1610# define wxUSE_MSGDLG 1
1611# endif
1612#endif
1613
1e6feb95 1614#if wxUSE_RADIOBOX
9a727a3b 1615# if !wxUSE_RADIOBTN
1e6feb95 1616# ifdef wxABORT_ON_CONFIG_ERROR
9a727a3b 1617# error "wxUSE_RADIOBOX requires wxUSE_RADIOBTN"
1e6feb95
VZ
1618# else
1619# undef wxUSE_RADIOBTN
1e6feb95 1620# define wxUSE_RADIOBTN 1
9a727a3b
WS
1621# endif
1622# endif
1623# if !wxUSE_STATBOX && !defined(__WXPALMOS__)
1624# ifdef wxABORT_ON_CONFIG_ERROR
1625# error "wxUSE_RADIOBOX requires wxUSE_STATBOX"
1626# else
1627# undef wxUSE_STATBOX
1e6feb95
VZ
1628# define wxUSE_STATBOX 1
1629# endif
1630# endif
1631#endif /* wxUSE_RADIOBOX */
1632
3379ed37
VZ
1633#if wxUSE_LOGWINDOW
1634# if !wxUSE_TEXTCTRL
1635# ifdef wxABORT_ON_CONFIG_ERROR
1636# error "wxUSE_LOGWINDOW requires wxUSE_TEXTCTRL"
1637# else
1638# undef wxUSE_TEXTCTRL
1639# define wxUSE_TEXTCTRL 1
1640# endif
1641# endif
1642#endif /* wxUSE_LOGWINDOW */
1e6feb95 1643
3e6e2754 1644#if wxUSE_LOG_DIALOG
0b4f47a3 1645# if !wxUSE_LISTCTRL || !wxUSE_BUTTON
3e6e2754 1646# ifdef wxABORT_ON_CONFIG_ERROR
0b4f47a3 1647# error "wxUSE_LOG_DIALOG requires wxUSE_LISTCTRL and wxUSE_BUTTON"
3e6e2754
JS
1648# else
1649# undef wxUSE_LISTCTRL
1650# define wxUSE_LISTCTRL 1
0b4f47a3
DS
1651# undef wxUSE_BUTTON
1652# define wxUSE_BUTTON 1
3e6e2754
JS
1653# endif
1654# endif
1655#endif /* wxUSE_LOG_DIALOG */
1656
1e6feb95 1657#if wxUSE_CLIPBOARD && !wxUSE_DATAOBJ
3379ed37 1658# ifdef wxABORT_ON_CONFIG_ERROR
1e6feb95
VZ
1659# error "wxClipboard requires wxDataObject"
1660# else
1661# undef wxUSE_DATAOBJ
1662# define wxUSE_DATAOBJ 1
1663# endif
1664#endif /* wxUSE_CLIPBOARD */
1665
2b5f62a0
VZ
1666#if wxUSE_WX_RESOURCES && !wxUSE_PROLOGIO
1667# ifdef wxABORT_ON_CONFIG_ERROR
1668# error "wxr resources require PrologIO"
1669# else
1670# undef wxUSE_PROLOGIO
1671# define wxUSE_PROLOGIO 1
1672# endif
1673#endif /* wxUSE_WX_RESOURCES */
1674
d2ebf0b7
VS
1675#if wxUSE_XRC && !wxUSE_XML
1676# ifdef wxABORT_ON_CONFIG_ERROR
1677# error "wxUSE_XRC requires wxUSE_XML"
1678# else
1679# undef wxUSE_XRC
1680# define wxUSE_XRC 0
1681# endif
5a017695 1682#endif /* wxUSE_XRC */
d2ebf0b7 1683
4669dcb2
RN
1684#if wxUSE_SOCKETS && !wxUSE_STOPWATCH
1685# ifdef wxABORT_ON_CONFIG_ERROR
1686# error "wxUSE_SOCKETS requires wxUSE_STOPWATCH"
1687# else
1688# undef wxUSE_SOCKETS
1689# define wxUSE_SOCKETS 0
1690# endif
1691#endif /* wxUSE_SOCKETS */
1692
1e6feb95
VZ
1693#endif /* wxUSE_GUI */
1694