+#undef wxUSE_MS_HTML_HELP
+#define wxUSE_MS_HTML_HELP 0
+
+#undef wxUSE_WCHAR_T
+#define wxUSE_WCHAR_T 0
+
+#endif // Win16
+
+// ----------------------------------------------------------------------------
+// undef the things which don't make sense for wxBase build
+// ----------------------------------------------------------------------------
+
+#if !wxUSE_GUI
+
+#undef wxUSE_HTML
+#define wxUSE_HTML 0
+
+#endif // !wxUSE_GUI
+
+// ----------------------------------------------------------------------------
+// check the settings consistency: do it here to abort compilation immediately
+// and not almost in the very end when the relevant file fails to compile and
+// you need to modify setup.h and rebuild everything
+// ----------------------------------------------------------------------------
+
+#if wxUSE_TIMEDATE && !wxUSE_LONGLONG
+ #error wxDateTime requires wxLongLong
+#endif
+
+#if wxUSE_TEXTFILE && !wxUSE_FILE
+ #error You cannot compile wxTextFile without wxFile
+#endif
+
+#if wxUSE_FILESYSTEM && !wxUSE_STREAMS
+ #error You cannot compile virtual file systems without wxUSE_STREAMS
+#endif
+
+#if wxUSE_HTML && !wxUSE_FILESYSTEM
+ #error You cannot compile wxHTML without virtual file systems