Chris@16
|
1 // (C) Copyright John Maddock 2001 - 2003.
|
Chris@16
|
2 // (C) Copyright Darin Adler 2001 - 2002.
|
Chris@16
|
3 // (C) Copyright Peter Dimov 2001.
|
Chris@16
|
4 // (C) Copyright Aleksey Gurtovoy 2002.
|
Chris@16
|
5 // (C) Copyright David Abrahams 2002 - 2003.
|
Chris@16
|
6 // (C) Copyright Beman Dawes 2002 - 2003.
|
Chris@16
|
7 // Use, modification and distribution are subject to the
|
Chris@16
|
8 // Boost Software License, Version 1.0. (See accompanying file
|
Chris@16
|
9 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
Chris@16
|
10
|
Chris@16
|
11 // See http://www.boost.org for most recent version.
|
Chris@16
|
12 //
|
Chris@16
|
13 // Microsoft Visual C++ compiler setup:
|
Chris@16
|
14 //
|
Chris@16
|
15 // We need to be careful with the checks in this file, as contrary
|
Chris@16
|
16 // to popular belief there are versions with _MSC_VER with the final
|
Chris@16
|
17 // digit non-zero (mainly the MIPS cross compiler).
|
Chris@16
|
18 //
|
Chris@16
|
19 // So we either test _MSC_VER >= XXXX or else _MSC_VER < XXXX.
|
Chris@16
|
20 // No other comparisons (==, >, or <=) are safe.
|
Chris@16
|
21 //
|
Chris@16
|
22
|
Chris@16
|
23 #define BOOST_MSVC _MSC_VER
|
Chris@16
|
24
|
Chris@16
|
25 //
|
Chris@16
|
26 // Helper macro BOOST_MSVC_FULL_VER for use in Boost code:
|
Chris@16
|
27 //
|
Chris@16
|
28 #if _MSC_FULL_VER > 100000000
|
Chris@16
|
29 # define BOOST_MSVC_FULL_VER _MSC_FULL_VER
|
Chris@16
|
30 #else
|
Chris@16
|
31 # define BOOST_MSVC_FULL_VER (_MSC_FULL_VER * 10)
|
Chris@16
|
32 #endif
|
Chris@16
|
33
|
Chris@16
|
34 // Attempt to suppress VC6 warnings about the length of decorated names (obsolete):
|
Chris@16
|
35 #pragma warning( disable : 4503 ) // warning: decorated name length exceeded
|
Chris@16
|
36
|
Chris@16
|
37 #define BOOST_HAS_PRAGMA_ONCE
|
Chris@16
|
38
|
Chris@16
|
39 //
|
Chris@16
|
40 // versions check:
|
Chris@16
|
41 // we don't support Visual C++ prior to version 7.1:
|
Chris@16
|
42 #if _MSC_VER < 1310
|
Chris@16
|
43 # error "Compiler not supported or configured - please reconfigure"
|
Chris@16
|
44 #endif
|
Chris@16
|
45
|
Chris@16
|
46 #if _MSC_FULL_VER < 180020827
|
Chris@16
|
47 # define BOOST_NO_FENV_H
|
Chris@16
|
48 #endif
|
Chris@16
|
49
|
Chris@16
|
50 #if _MSC_VER < 1400
|
Chris@16
|
51 // although a conforming signature for swprint exists in VC7.1
|
Chris@16
|
52 // it appears not to actually work:
|
Chris@16
|
53 # define BOOST_NO_SWPRINTF
|
Chris@16
|
54 // Our extern template tests also fail for this compiler:
|
Chris@16
|
55 # define BOOST_NO_CXX11_EXTERN_TEMPLATE
|
Chris@16
|
56 // Variadic macros do not exist for VC7.1 and lower
|
Chris@16
|
57 # define BOOST_NO_CXX11_VARIADIC_MACROS
|
Chris@16
|
58 #endif
|
Chris@16
|
59
|
Chris@16
|
60 #if _MSC_VER < 1500 // 140X == VC++ 8.0
|
Chris@16
|
61 # define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
|
Chris@16
|
62 #endif
|
Chris@16
|
63
|
Chris@16
|
64 #if _MSC_VER < 1600 // 150X == VC++ 9.0
|
Chris@16
|
65 // A bug in VC9:
|
Chris@16
|
66 # define BOOST_NO_ADL_BARRIER
|
Chris@16
|
67 #endif
|
Chris@16
|
68
|
Chris@16
|
69
|
Chris@16
|
70 // MSVC (including the latest checked version) has not yet completely
|
Chris@16
|
71 // implemented value-initialization, as is reported:
|
Chris@16
|
72 // "VC++ does not value-initialize members of derived classes without
|
Chris@16
|
73 // user-declared constructor", reported in 2009 by Sylvester Hesp:
|
Chris@16
|
74 // https://connect.microsoft.com/VisualStudio/feedback/details/484295
|
Chris@16
|
75 // "Presence of copy constructor breaks member class initialization",
|
Chris@16
|
76 // reported in 2009 by Alex Vakulenko:
|
Chris@16
|
77 // https://connect.microsoft.com/VisualStudio/feedback/details/499606
|
Chris@16
|
78 // "Value-initialization in new-expression", reported in 2005 by
|
Chris@16
|
79 // Pavel Kuznetsov (MetaCommunications Engineering):
|
Chris@16
|
80 // https://connect.microsoft.com/VisualStudio/feedback/details/100744
|
Chris@16
|
81 // See also: http://www.boost.org/libs/utility/value_init.htm#compiler_issues
|
Chris@16
|
82 // (Niels Dekker, LKEB, May 2010)
|
Chris@16
|
83 # define BOOST_NO_COMPLETE_VALUE_INITIALIZATION
|
Chris@16
|
84
|
Chris@16
|
85 #ifndef _NATIVE_WCHAR_T_DEFINED
|
Chris@16
|
86 # define BOOST_NO_INTRINSIC_WCHAR_T
|
Chris@16
|
87 #endif
|
Chris@16
|
88
|
Chris@16
|
89 //
|
Chris@16
|
90 // check for exception handling support:
|
Chris@16
|
91 #if !defined(_CPPUNWIND) && !defined(BOOST_NO_EXCEPTIONS)
|
Chris@16
|
92 # define BOOST_NO_EXCEPTIONS
|
Chris@16
|
93 #endif
|
Chris@16
|
94
|
Chris@16
|
95 //
|
Chris@16
|
96 // __int64 support:
|
Chris@16
|
97 //
|
Chris@16
|
98 #define BOOST_HAS_MS_INT64
|
Chris@16
|
99 #if defined(_MSC_EXTENSIONS) || (_MSC_VER >= 1400)
|
Chris@16
|
100 # define BOOST_HAS_LONG_LONG
|
Chris@16
|
101 #else
|
Chris@16
|
102 # define BOOST_NO_LONG_LONG
|
Chris@16
|
103 #endif
|
Chris@16
|
104 #if (_MSC_VER >= 1400) && !defined(_DEBUG)
|
Chris@16
|
105 # define BOOST_HAS_NRVO
|
Chris@16
|
106 #endif
|
Chris@101
|
107 #if _MSC_VER >= 1600 // 160X == VC++ 10.0
|
Chris@101
|
108 # define BOOST_HAS_PRAGMA_DETECT_MISMATCH
|
Chris@101
|
109 #endif
|
Chris@16
|
110 //
|
Chris@101
|
111 // disable Win32 API's if compiler extensions are
|
Chris@16
|
112 // turned off:
|
Chris@16
|
113 //
|
Chris@16
|
114 #if !defined(_MSC_EXTENSIONS) && !defined(BOOST_DISABLE_WIN32)
|
Chris@16
|
115 # define BOOST_DISABLE_WIN32
|
Chris@16
|
116 #endif
|
Chris@16
|
117 #if !defined(_CPPRTTI) && !defined(BOOST_NO_RTTI)
|
Chris@16
|
118 # define BOOST_NO_RTTI
|
Chris@16
|
119 #endif
|
Chris@16
|
120
|
Chris@16
|
121 //
|
Chris@16
|
122 // TR1 features:
|
Chris@16
|
123 //
|
Chris@16
|
124 #if _MSC_VER >= 1700
|
Chris@16
|
125 // # define BOOST_HAS_TR1_HASH // don't know if this is true yet.
|
Chris@16
|
126 // # define BOOST_HAS_TR1_TYPE_TRAITS // don't know if this is true yet.
|
Chris@16
|
127 # define BOOST_HAS_TR1_UNORDERED_MAP
|
Chris@16
|
128 # define BOOST_HAS_TR1_UNORDERED_SET
|
Chris@16
|
129 #endif
|
Chris@16
|
130
|
Chris@16
|
131 //
|
Chris@16
|
132 // C++0x features
|
Chris@16
|
133 //
|
Chris@16
|
134 // See above for BOOST_NO_LONG_LONG
|
Chris@16
|
135
|
Chris@16
|
136 // C++ features supported by VC++ 10 (aka 2010)
|
Chris@16
|
137 //
|
Chris@16
|
138 #if _MSC_VER < 1600
|
Chris@16
|
139 # define BOOST_NO_CXX11_AUTO_DECLARATIONS
|
Chris@16
|
140 # define BOOST_NO_CXX11_AUTO_MULTIDECLARATIONS
|
Chris@16
|
141 # define BOOST_NO_CXX11_LAMBDAS
|
Chris@16
|
142 # define BOOST_NO_CXX11_RVALUE_REFERENCES
|
Chris@16
|
143 # define BOOST_NO_CXX11_STATIC_ASSERT
|
Chris@16
|
144 # define BOOST_NO_CXX11_NULLPTR
|
Chris@16
|
145 # define BOOST_NO_CXX11_DECLTYPE
|
Chris@16
|
146 #endif // _MSC_VER < 1600
|
Chris@16
|
147
|
Chris@16
|
148 #if _MSC_VER >= 1600
|
Chris@16
|
149 # define BOOST_HAS_STDINT_H
|
Chris@16
|
150 #endif
|
Chris@16
|
151
|
Chris@16
|
152 // C++11 features supported by VC++ 11 (aka 2012)
|
Chris@16
|
153 //
|
Chris@16
|
154 #if _MSC_VER < 1700
|
Chris@101
|
155 # define BOOST_NO_CXX11_FINAL
|
Chris@16
|
156 # define BOOST_NO_CXX11_RANGE_BASED_FOR
|
Chris@16
|
157 # define BOOST_NO_CXX11_SCOPED_ENUMS
|
Chris@16
|
158 #endif // _MSC_VER < 1700
|
Chris@16
|
159
|
Chris@16
|
160 // C++11 features supported by VC++ 12 (aka 2013).
|
Chris@16
|
161 //
|
Chris@16
|
162 #if _MSC_FULL_VER < 180020827
|
Chris@16
|
163 # define BOOST_NO_CXX11_DEFAULTED_FUNCTIONS
|
Chris@16
|
164 # define BOOST_NO_CXX11_DELETED_FUNCTIONS
|
Chris@16
|
165 # define BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS
|
Chris@16
|
166 # define BOOST_NO_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGS
|
Chris@16
|
167 # define BOOST_NO_CXX11_RAW_LITERALS
|
Chris@16
|
168 # define BOOST_NO_CXX11_TEMPLATE_ALIASES
|
Chris@16
|
169 # define BOOST_NO_CXX11_TRAILING_RESULT_TYPES
|
Chris@16
|
170 # define BOOST_NO_CXX11_VARIADIC_TEMPLATES
|
Chris@16
|
171 # define BOOST_NO_CXX11_UNIFIED_INITIALIZATION_SYNTAX
|
Chris@101
|
172 # define BOOST_NO_CXX11_DECLTYPE_N3276
|
Chris@101
|
173 #endif
|
Chris@101
|
174
|
Chris@101
|
175 // C++11 features supported by VC++ 14 (aka 2015) Preview
|
Chris@101
|
176 //
|
Chris@101
|
177 #if (_MSC_FULL_VER < 190022310)
|
Chris@101
|
178 # define BOOST_NO_CXX11_NOEXCEPT
|
Chris@101
|
179 # define BOOST_NO_CXX11_REF_QUALIFIERS
|
Chris@101
|
180 # define BOOST_NO_CXX11_USER_DEFINED_LITERALS
|
Chris@101
|
181 # define BOOST_NO_CXX11_ALIGNAS
|
Chris@101
|
182 # define BOOST_NO_CXX11_INLINE_NAMESPACES
|
Chris@101
|
183 # define BOOST_NO_CXX11_CHAR16_T
|
Chris@101
|
184 # define BOOST_NO_CXX11_CHAR32_T
|
Chris@101
|
185 # define BOOST_NO_CXX11_UNICODE_LITERALS
|
Chris@101
|
186 # define BOOST_NO_CXX14_DECLTYPE_AUTO
|
Chris@101
|
187 # define BOOST_NO_CXX14_INITIALIZED_LAMBDA_CAPTURES
|
Chris@101
|
188 # define BOOST_NO_CXX14_RETURN_TYPE_DEDUCTION
|
Chris@101
|
189 # define BOOST_NO_CXX14_BINARY_LITERALS
|
Chris@101
|
190 # define BOOST_NO_CXX14_GENERIC_LAMBDAS
|
Chris@16
|
191 #endif
|
Chris@16
|
192
|
Chris@16
|
193 // C++11 features not supported by any versions
|
Chris@16
|
194 #define BOOST_NO_CXX11_CONSTEXPR
|
Chris@16
|
195 #define BOOST_NO_SFINAE_EXPR
|
Chris@16
|
196 #define BOOST_NO_TWO_PHASE_NAME_LOOKUP
|
Chris@101
|
197
|
Chris@101
|
198 // C++ 14:
|
Chris@101
|
199 #if !defined(__cpp_aggregate_nsdmi) || (__cpp_aggregate_nsdmi < 201304)
|
Chris@101
|
200 # define BOOST_NO_CXX14_AGGREGATE_NSDMI
|
Chris@101
|
201 #endif
|
Chris@101
|
202 #if !defined(__cpp_constexpr) || (__cpp_constexpr < 201304)
|
Chris@101
|
203 # define BOOST_NO_CXX14_CONSTEXPR
|
Chris@101
|
204 #endif
|
Chris@101
|
205 #if (__cplusplus < 201304) // There's no SD6 check for this....
|
Chris@101
|
206 # define BOOST_NO_CXX14_DIGIT_SEPARATORS
|
Chris@101
|
207 #endif
|
Chris@101
|
208 #if !defined(__cpp_variable_templates) || (__cpp_variable_templates < 201304)
|
Chris@101
|
209 # define BOOST_NO_CXX14_VARIABLE_TEMPLATES
|
Chris@101
|
210 #endif
|
Chris@16
|
211
|
Chris@16
|
212 //
|
Chris@16
|
213 // prefix and suffix headers:
|
Chris@16
|
214 //
|
Chris@16
|
215 #ifndef BOOST_ABI_PREFIX
|
Chris@16
|
216 # define BOOST_ABI_PREFIX "boost/config/abi/msvc_prefix.hpp"
|
Chris@16
|
217 #endif
|
Chris@16
|
218 #ifndef BOOST_ABI_SUFFIX
|
Chris@16
|
219 # define BOOST_ABI_SUFFIX "boost/config/abi/msvc_suffix.hpp"
|
Chris@16
|
220 #endif
|
Chris@16
|
221
|
Chris@16
|
222 #ifndef BOOST_COMPILER
|
Chris@16
|
223 // TODO:
|
Chris@16
|
224 // these things are mostly bogus. 1200 means version 12.0 of the compiler. The
|
Chris@16
|
225 // artificial versions assigned to them only refer to the versions of some IDE
|
Chris@16
|
226 // these compilers have been shipped with, and even that is not all of it. Some
|
Chris@16
|
227 // were shipped with freely downloadable SDKs, others as crosscompilers in eVC.
|
Chris@16
|
228 // IOW, you can't use these 'versions' in any sensible way. Sorry.
|
Chris@16
|
229 # if defined(UNDER_CE)
|
Chris@16
|
230 # if _MSC_VER < 1400
|
Chris@16
|
231 // Note: I'm not aware of any CE compiler with version 13xx
|
Chris@16
|
232 # if defined(BOOST_ASSERT_CONFIG)
|
Chris@16
|
233 # error "Unknown EVC++ compiler version - please run the configure tests and report the results"
|
Chris@16
|
234 # else
|
Chris@16
|
235 # pragma message("Unknown EVC++ compiler version - please run the configure tests and report the results")
|
Chris@16
|
236 # endif
|
Chris@16
|
237 # elif _MSC_VER < 1500
|
Chris@16
|
238 # define BOOST_COMPILER_VERSION evc8
|
Chris@16
|
239 # elif _MSC_VER < 1600
|
Chris@16
|
240 # define BOOST_COMPILER_VERSION evc9
|
Chris@16
|
241 # elif _MSC_VER < 1700
|
Chris@16
|
242 # define BOOST_COMPILER_VERSION evc10
|
Chris@16
|
243 # elif _MSC_VER < 1800
|
Chris@16
|
244 # define BOOST_COMPILER_VERSION evc11
|
Chris@16
|
245 # elif _MSC_VER < 1900
|
Chris@16
|
246 # define BOOST_COMPILER_VERSION evc12
|
Chris@101
|
247 # elif _MSC_VER < 2000
|
Chris@101
|
248 # define BOOST_COMPILER_VERSION evc14
|
Chris@16
|
249 # else
|
Chris@16
|
250 # if defined(BOOST_ASSERT_CONFIG)
|
Chris@16
|
251 # error "Unknown EVC++ compiler version - please run the configure tests and report the results"
|
Chris@16
|
252 # else
|
Chris@16
|
253 # pragma message("Unknown EVC++ compiler version - please run the configure tests and report the results")
|
Chris@16
|
254 # endif
|
Chris@16
|
255 # endif
|
Chris@16
|
256 # else
|
Chris@16
|
257 # if _MSC_VER < 1310
|
Chris@16
|
258 // Note: Versions up to 7.0 aren't supported.
|
Chris@16
|
259 # define BOOST_COMPILER_VERSION 5.0
|
Chris@16
|
260 # elif _MSC_VER < 1300
|
Chris@16
|
261 # define BOOST_COMPILER_VERSION 6.0
|
Chris@16
|
262 # elif _MSC_VER < 1310
|
Chris@16
|
263 # define BOOST_COMPILER_VERSION 7.0
|
Chris@16
|
264 # elif _MSC_VER < 1400
|
Chris@16
|
265 # define BOOST_COMPILER_VERSION 7.1
|
Chris@16
|
266 # elif _MSC_VER < 1500
|
Chris@16
|
267 # define BOOST_COMPILER_VERSION 8.0
|
Chris@16
|
268 # elif _MSC_VER < 1600
|
Chris@16
|
269 # define BOOST_COMPILER_VERSION 9.0
|
Chris@16
|
270 # elif _MSC_VER < 1700
|
Chris@16
|
271 # define BOOST_COMPILER_VERSION 10.0
|
Chris@16
|
272 # elif _MSC_VER < 1800
|
Chris@16
|
273 # define BOOST_COMPILER_VERSION 11.0
|
Chris@16
|
274 # elif _MSC_VER < 1900
|
Chris@16
|
275 # define BOOST_COMPILER_VERSION 12.0
|
Chris@101
|
276 # elif _MSC_VER < 2000
|
Chris@101
|
277 # define BOOST_COMPILER_VERSION 14.0
|
Chris@16
|
278 # else
|
Chris@16
|
279 # define BOOST_COMPILER_VERSION _MSC_VER
|
Chris@16
|
280 # endif
|
Chris@16
|
281 # endif
|
Chris@16
|
282
|
Chris@16
|
283 # define BOOST_COMPILER "Microsoft Visual C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION)
|
Chris@16
|
284 #endif
|
Chris@16
|
285
|
Chris@16
|
286 //
|
Chris@101
|
287 // last known and checked version is 19.00.22129 (VC14 Preview):
|
Chris@101
|
288 #if (_MSC_VER > 1800 && _MSC_FULL_VER > 190022310)
|
Chris@16
|
289 # if defined(BOOST_ASSERT_CONFIG)
|
Chris@16
|
290 # error "Unknown compiler version - please run the configure tests and report the results"
|
Chris@16
|
291 # else
|
Chris@16
|
292 # pragma message("Unknown compiler version - please run the configure tests and report the results")
|
Chris@16
|
293 # endif
|
Chris@16
|
294 #endif
|