]> git.saurik.com Git - wxWidgets.git/blame - include/msvc/wx/setup.h
Fixed wxBORDER_THEME breakage
[wxWidgets.git] / include / msvc / wx / setup.h
CommitLineData
e5099bdf
VZ
1/////////////////////////////////////////////////////////////////////////////
2// Name: msvc/wx/msw/setup.h
3// Purpose: wrapper around the real wx/setup.h for Visual C++
4// Author: Vadim Zeitlin
5// Modified by:
6// Created: 2004-12-12
7// RCS-ID: $Id$
8// Copyright: (c) 2004 Vadim Zeitlin <vadim@wxwindows.org>
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
c82c5274
VZ
12#ifndef _MSC_VER
13 #error "This file should only be included when using Microsoft Visual C++"
14#endif
15
e5099bdf
VZ
16// VC++ IDE predefines _DEBUG and _UNICODE for the new projects itself, but
17// the other symbols (WXUSINGDLL, __WXUNIVERSAL__, ...) should be defined
3103e8a9 18// explicitly!
e5099bdf 19
c82c5274
VZ
20#include "wx/version.h"
21#include "wx/cpp.h"
22
23// notice that wxSUFFIX_DEBUG is a string but wxSUFFIX itself must be an
24// identifier as string concatenation is not done inside #include where we
25// need it
26#ifdef _DEBUG
27 #define wxSUFFIX_DEBUG "d"
28 #ifdef _UNICODE
29 #define wxSUFFIX ud
30 #else // !_UNICODE
31 #define wxSUFFIX d
32 #endif // _UNICODE/!_UNICODE
33#else
34 #define wxSUFFIX_DEBUG ""
35 #ifdef _UNICODE
36 #define wxSUFFIX u
37 #else // !_UNICODE
38 #define wxSUFFIX
39 #endif // _UNICODE/!_UNICODE
40#endif
d57b7160 41
c82c5274
VZ
42#ifdef WXUSINGDLL
43 #define wxLIB_SUBDIR vc_dll
44#else // !DLL
45 #define wxLIB_SUBDIR vc_lib
46#endif // DLL/!DLL
d57b7160
VZ
47
48
c82c5274
VZ
49// the real setup.h header file we need is in the build-specific directory,
50// construct the path to it
51#define wxSETUPH_PATH \
52 wxCONCAT5(../../../lib/, wxLIB_SUBDIR, /msw, wxSUFFIX, /wx/setup.h)
53#define wxSETUPH_PATH_STR wxSTRINGIZE(wxSETUPH_PATH)
d57b7160 54
c82c5274 55#include wxSETUPH_PATH_STR
d57b7160
VZ
56
57
c82c5274
VZ
58// the library names depend on the build, these macro builds the correct
59// library name for the given base name
60#define wxSUFFIX_STR wxSTRINGIZE(wxSUFFIX)
61#define wxSHORT_VERSION_STRING \
62 wxSTRINGIZE(wxMAJOR_VERSION) wxSTRINGIZE(wxMINOR_VERSION)
d57b7160 63
c82c5274
VZ
64#define wxWX_LIB_NAME(name, subname) \
65 "wx" name wxSHORT_VERSION_STRING wxSUFFIX_STR subname
d57b7160 66
c82c5274
VZ
67#define wxBASE_LIB_NAME(name) wxWX_LIB_NAME("base", "_" name)
68#define wxMSW_LIB_NAME(name) wxWX_LIB_NAME("msw", "_" name)
d57b7160 69
c82c5274
VZ
70// this one is for 3rd party libraries: they don't have the version number
71// in their names and usually exist in ANSI version only (except for regex)
72#define wx3RD_PARTY_LIB_NAME(name) "wx" name wxSUFFIX_DEBUG
d57b7160 73
c82c5274
VZ
74// special version for regex as it does have a Unicode version
75#define wx3RD_PARTY_LIB_NAME_U(name) "wx" name wxSUFFIX_STR
d57b7160 76
c82c5274 77#pragma comment(lib, wxWX_LIB_NAME("base", ""))
3fb26cf2 78
c82c5274
VZ
79#ifndef wxNO_NET_LIB
80 #pragma comment(lib, wxBASE_LIB_NAME("net"))
81#endif
82#ifndef wxNO_XML_LIB
83 #pragma comment(lib, wxBASE_LIB_NAME("xml"))
84#endif
85#if wxUSE_REGEX && !defined(wxNO_REGEX_LIB)
86 #pragma comment(lib, wx3RD_PARTY_LIB_NAME_U("regex"))
87#endif
88
89#if wxUSE_GUI
90 #if wxUSE_XML && !defined(wxNO_EXPAT_LIB)
91 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("expat"))
3fb26cf2 92 #endif
c82c5274
VZ
93 #if wxUSE_LIBJPEG && !defined(wxNO_JPEG_LIB)
94 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("jpeg"))
3fb26cf2 95 #endif
c82c5274
VZ
96 #if wxUSE_LIBPNG && !defined(wxNO_PNG_LIB)
97 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("png"))
98 #endif
99 #if wxUSE_LIBTIFF && !defined(wxNO_TIFF_LIB)
100 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("tiff"))
101 #endif
102 #if wxUSE_ZLIB && !defined(wxNO_ZLIB_LIB)
103 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("zlib"))
d57b7160
VZ
104 #endif
105
c82c5274
VZ
106 #pragma comment(lib, wxMSW_LIB_NAME("core"))
107
108 #ifndef wxNO_ADV_LIB
109 #pragma comment(lib, wxMSW_LIB_NAME("adv"))
110 #endif
e5099bdf 111
c82c5274
VZ
112 #ifndef wxNO_HTML_LIB
113 #pragma comment(lib, wxMSW_LIB_NAME("html"))
114 #endif
115 #if wxUSE_GLCANVAS && !defined(wxNO_GL_LIB)
116 #pragma comment(lib, wxMSW_LIB_NAME("gl"))
117 #endif
118 #if wxUSE_DEBUGREPORT && !defined(wxNO_QA_LIB)
119 #pragma comment(lib, wxMSW_LIB_NAME("qa"))
120 #endif
121 #if wxUSE_XRC && !defined(wxNO_XRC_LIB)
122 #pragma comment(lib, wxMSW_LIB_NAME("xrc"))
123 #endif
124 #if wxUSE_AUI && !defined(wxNO_AUI_LIB)
125 #pragma comment(lib, wxMSW_LIB_NAME("aui"))
126 #endif
127 #if wxUSE_PROPGRID && !defined(wxNO_PROPGRID_LIB)
128 #pragma comment(lib, wxMSW_LIB_NAME("propgrid"))
129 #endif
130 #if wxUSE_RICHTEXT && !defined(wxNO_RICHTEXT_LIB)
131 #pragma comment(lib, wxMSW_LIB_NAME("richtext"))
132 #endif
133 #if wxUSE_MEDIACTRL && !defined(wxNO_MEDIA_LIB)
134 #pragma comment(lib, wxMSW_LIB_NAME("media"))
135 #endif
136 #if wxUSE_STC && !defined(wxNO_STC_LIB)
137 #pragma comment(lib, wxMSW_LIB_NAME("stc"))
138 #pragma comment(lib, wx3RD_PARTY_LIB_NAME("scintilla"))
139 #endif
140#endif // wxUSE_GUI