1 // (C) Copyright John Maddock 2001 - 2003.
\r
2 // (C) Copyright David Abrahams 2002 - 2003.
\r
3 // (C) Copyright Aleksey Gurtovoy 2002.
\r
4 // Use, modification and distribution are subject to the
\r
5 // Boost Software License, Version 1.0. (See accompanying file
\r
6 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
\r
8 // See http://www.boost.org for most recent version.
\r
10 // Borland C++ compiler setup:
\r
14 // we don't support Borland prior to version 5.4:
\r
15 #if __BORLANDC__ < 0x540
\r
16 # error "Compiler not supported or configured - please reconfigure"
\r
19 // last known compiler version:
\r
20 #if (__BORLANDC__ > 0x613)
\r
21 //# if defined(BOOST_ASSERT_CONFIG)
\r
22 # error "Unknown compiler version - please run the configure tests and report the results"
\r
24 //# pragma message( "Unknown compiler version - please run the configure tests and report the results")
\r
26 #elif (__BORLANDC__ == 0x600)
\r
27 # error "CBuilderX preview compiler is no longer supported"
\r
31 // Support macros to help with standard library detection
\r
32 #if (__BORLANDC__ < 0x560) || defined(_USE_OLD_RW_STL)
\r
33 # define BOOST_BCB_WITH_ROGUE_WAVE
\r
34 #elif __BORLANDC__ < 0x570
\r
35 # define BOOST_BCB_WITH_STLPORT
\r
37 # define BOOST_BCB_WITH_DINKUMWARE
\r
41 // Version 5.0 and below:
\r
42 # if __BORLANDC__ <= 0x0550
\r
43 // Borland C++Builder 4 and 5:
\r
44 # define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
\r
45 # if __BORLANDC__ == 0x0550
\r
46 // Borland C++Builder 5, command-line compiler 5.5:
\r
47 # define BOOST_NO_OPERATORS_IN_NAMESPACE
\r
51 // Version 5.51 and below:
\r
52 #if (__BORLANDC__ <= 0x551)
\r
53 # define BOOST_NO_CV_SPECIALIZATIONS
\r
54 # define BOOST_NO_CV_VOID_SPECIALIZATIONS
\r
55 # define BOOST_NO_DEDUCED_TYPENAME
\r
56 // workaround for missing WCHAR_MAX/WCHAR_MIN:
\r
60 # define WCHAR_MAX 0xffff
\r
63 # define WCHAR_MIN 0
\r
67 // Borland C++ Builder 6 and below:
\r
68 #if (__BORLANDC__ <= 0x564)
\r
71 // fix broken <cstring> so that Boost.test works:
\r
75 // fix broken errno declaration:
\r
78 # define errno errno
\r
85 #if (__BORLANDC__ >= 0x561) && (__BORLANDC__ <= 0x580)
\r
86 // this seems to be needed by the command line compiler, but not the IDE:
\r
87 # define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
\r
90 // Borland C++ Builder 2006 Update 2 and below:
\r
91 #if (__BORLANDC__ <= 0x582)
\r
92 # define BOOST_NO_SFINAE
\r
93 # define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG
\r
94 # define BOOST_NO_TEMPLATE_TEMPLATES
\r
96 # define BOOST_NO_PRIVATE_IN_AGGREGATE
\r
99 # define BOOST_NO_SWPRINTF
\r
100 # elif defined(linux) || defined(__linux__) || defined(__linux)
\r
101 // we should really be able to do without this
\r
102 // but the wcs* functions aren't imported into std::
\r
103 # define BOOST_NO_STDC_NAMESPACE
\r
104 // _CPPUNWIND doesn't get automatically set for some reason:
\r
105 # pragma defineonoption BOOST_CPPUNWIND -x
\r
109 #if (__BORLANDC__ <= 0x613) // Beman has asked Alisdair for more info
\r
110 // we shouldn't really need this - but too many things choke
\r
111 // without it, this needs more investigation:
\r
112 # define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
\r
113 # define BOOST_NO_IS_ABSTRACT
\r
114 # define BOOST_NO_FUNCTION_TYPE_SPECIALIZATIONS
\r
115 # define BOOST_NO_USING_TEMPLATE
\r
116 # define BOOST_SP_NO_SP_CONVERTIBLE
\r
118 // Temporary workaround
\r
119 #define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
\r
122 // Borland C++ Builder 2008 and below:
\r
123 # define BOOST_NO_INTEGRAL_INT64_T
\r
124 # define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
\r
125 # define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
\r
126 # define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
\r
127 # define BOOST_NO_TWO_PHASE_NAME_LOOKUP
\r
128 # define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
\r
129 # define BOOST_NO_NESTED_FRIENDSHIP
\r
130 # define BOOST_NO_TYPENAME_WITH_CTOR
\r
131 #if (__BORLANDC__ < 0x600)
\r
132 # define BOOST_ILLEGAL_CV_REFERENCES
\r
136 // Positive Feature detection
\r
138 // Borland C++ Builder 2008 and below:
\r
139 #if (__BORLANDC__ >= 0x599)
\r
140 # pragma defineonoption BOOST_CODEGEAR_0X_SUPPORT -Ax
\r
145 #if !defined( BOOST_CODEGEAR_0X_SUPPORT ) || (__BORLANDC__ < 0x610)
\r
146 # define BOOST_NO_CHAR16_T
\r
147 # define BOOST_NO_CHAR32_T
\r
148 # define BOOST_NO_DECLTYPE
\r
149 # define BOOST_NO_EXPLICIT_CONVERSION_OPERATORS
\r
150 # define BOOST_NO_EXTERN_TEMPLATE
\r
151 # define BOOST_NO_RVALUE_REFERENCES
\r
152 # define BOOST_NO_SCOPED_ENUMS
\r
153 # define BOOST_NO_STATIC_ASSERT
\r
155 # define BOOST_HAS_ALIGNOF
\r
156 # define BOOST_HAS_CHAR16_T
\r
157 # define BOOST_HAS_CHAR32_T
\r
158 # define BOOST_HAS_DECLTYPE
\r
159 # define BOOST_HAS_EXPLICIT_CONVERSION_OPS
\r
160 # define BOOST_HAS_REF_QUALIFIER
\r
161 # define BOOST_HAS_RVALUE_REFS
\r
162 # define BOOST_HAS_STATIC_ASSERT
\r
165 #define BOOST_NO_AUTO_DECLARATIONS
\r
166 #define BOOST_NO_AUTO_MULTIDECLARATIONS
\r
167 #define BOOST_NO_CONCEPTS
\r
168 #define BOOST_NO_CONSTEXPR
\r
169 #define BOOST_NO_DEFAULTED_FUNCTIONS
\r
170 #define BOOST_NO_DELETED_FUNCTIONS
\r
171 #define BOOST_NO_FUNCTION_TEMPLATE_DEFAULT_ARGS
\r
172 #define BOOST_NO_INITIALIZER_LISTS
\r
173 #define BOOST_NO_LAMBDAS
\r
174 #define BOOST_NO_NULLPTR
\r
175 #define BOOST_NO_RAW_LITERALS
\r
176 #define BOOST_NO_RVALUE_REFERENCES
\r
177 #define BOOST_NO_SCOPED_ENUMS
\r
178 #define BOOST_NO_SFINAE_EXPR
\r
179 #define BOOST_NO_TEMPLATE_ALIASES
\r
180 #define BOOST_NO_UNICODE_LITERALS // UTF-8 still not supported
\r
181 #define BOOST_NO_VARIADIC_TEMPLATES
\r
183 #if __BORLANDC__ >= 0x590
\r
184 # define BOOST_HAS_TR1_HASH
\r
186 # define BOOST_HAS_MACRO_USE_FACET
\r
190 // Post 0x561 we have long long and stdint.h:
\r
191 #if __BORLANDC__ >= 0x561
\r
192 # ifndef __NO_LONG_LONG
\r
193 # define BOOST_HAS_LONG_LONG
\r
195 # define BOOST_NO_LONG_LONG
\r
197 // On non-Win32 platforms let the platform config figure this out:
\r
199 # define BOOST_HAS_STDINT_H
\r
203 // Borland C++Builder 6 defaults to using STLPort. If _USE_OLD_RW_STL is
\r
204 // defined, then we have 0x560 or greater with the Rogue Wave implementation
\r
205 // which presumably has the std::DBL_MAX bug.
\r
206 #if defined( BOOST_BCB_WITH_ROGUE_WAVE )
\r
207 // <climits> is partly broken, some macros define symbols that are really in
\r
208 // namespace std, so you end up having to use illegal constructs like
\r
209 // std::DBL_MAX, as a fix we'll just include float.h and have done with:
\r
215 #if (__BORLANDC__ >= 0x530) && !defined(__STRICT_ANSI__)
\r
216 # define BOOST_HAS_MS_INT64
\r
219 // check for exception handling support:
\r
221 #if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS)
\r
222 # define BOOST_NO_EXCEPTIONS
\r
225 // all versions have a <dirent.h>:
\r
227 #ifndef __STRICT_ANSI__
\r
228 # define BOOST_HAS_DIRENT_H
\r
231 // all versions support __declspec:
\r
233 #ifndef __STRICT_ANSI__
\r
234 # define BOOST_HAS_DECLSPEC
\r
237 // ABI fixing headers:
\r
239 #if __BORLANDC__ != 0x600 // not implemented for version 6 compiler yet
\r
240 #ifndef BOOST_ABI_PREFIX
\r
241 # define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp"
\r
243 #ifndef BOOST_ABI_SUFFIX
\r
244 # define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp"
\r
248 // Disable Win32 support in ANSI mode:
\r
250 #if __BORLANDC__ < 0x600
\r
251 # pragma defineonoption BOOST_DISABLE_WIN32 -A
\r
252 #elif defined(__STRICT_ANSI__)
\r
253 # define BOOST_DISABLE_WIN32
\r
256 // MSVC compatibility mode does some nasty things:
\r
257 // TODO: look up if this doesn't apply to the whole 12xx range
\r
259 #if defined(_MSC_VER) && (_MSC_VER <= 1200)
\r
260 # define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
\r
261 # define BOOST_NO_VOID_RETURNS
\r
264 #define BOOST_COMPILER "Borland C++ version " BOOST_STRINGIZE(__BORLANDC__)
\r