29 #ifndef CRYPTOPP_CONFIG_CXX_H
30 #define CRYPTOPP_CONFIG_CXX_H
42 #if (defined(_MSC_VER) && _MSC_VER <= 1300) || defined(__MWERKS__) || (defined(_STLPORT_VERSION) && ((_STLPORT_VERSION < 0x450) || defined(_STLP_NO_UNCAUGHT_EXCEPT_SUPPORT)))
43 #define CRYPTOPP_DISABLE_UNCAUGHT_EXCEPTION
47 #ifndef CRYPTOPP_DISABLE_UNCAUGHT_EXCEPTION
48 # define CRYPTOPP_UNCAUGHT_EXCEPTION_AVAILABLE 1
49 # define CRYPTOPP_CXX98_UNCAUGHT_EXCEPTION 1
54 # define __has_feature(x) 0
58 #if ((_MSC_VER >= 1600) || (__cplusplus >= 201103L)) && !defined(_STLPORT_VERSION)
59 # define CRYPTOPP_CXX11 1
68 #if defined(__APPLE__) && defined(__clang__)
69 # if !(defined(__has_include) && __has_include(<forward_list>))
70 # undef CRYPTOPP_CXX11
75 #if defined(CRYPTOPP_CXX11) && !defined(CRYPTOPP_NO_CXX14)
76 # if ((_MSC_VER >= 1900) || (__cplusplus >= 201402L)) && !defined(_STLPORT_VERSION)
77 # define CRYPTOPP_CXX14 1
82 #if defined(CRYPTOPP_CXX14) && !defined(CRYPTOPP_NO_CXX17)
83 # if ((_MSC_VER >= 1900) || (__cplusplus >= 201703L)) && !defined(_STLPORT_VERSION)
84 # define CRYPTOPP_CXX17 1
90 #if defined(CRYPTOPP_CXX11)
93 #if (CRYPTOPP_MSC_VERSION >= 1700) || __has_feature(cxx_atomic) || \
94 (__INTEL_COMPILER >= 1300) || (CRYPTOPP_GCC_VERSION >= 40400) || (__SUNPRO_CC >= 0x5140)
95 # define CRYPTOPP_CXX11_ATOMIC 1
100 #if (CRYPTOPP_MSC_VERSION >= 1700) || (CRYPTOPP_LLVM_CLANG_VERSION >= 30300) || \
101 (CRYPTOPP_APPLE_CLANG_VERSION >= 50000) || (__INTEL_COMPILER >= 1200) || \
102 (CRYPTOPP_GCC_VERSION >= 40400) || (__SUNPRO_CC >= 0x5130)
109 # if !defined(__GLIBCXX__) || defined(_GLIBCXX_HAS_GTHREADS)
110 # define CRYPTOPP_CXX11_SYNCHRONIZATION 1
119 #if (__cpp_threadsafe_static_init >= 200806) || \
120 (CRYPTOPP_MSC_VERSION >= 1900) && ((WINVER >= 0x0600) || (_WIN32_WINNT >= 0x0600)) || \
121 (CRYPTOPP_LLVM_CLANG_VERSION >= 20900) || (CRYPTOPP_APPLE_CLANG_VERSION >= 40000) || \
122 (__INTEL_COMPILER >= 1110) || (CRYPTOPP_GCC_VERSION >= 40300) || (__SUNPRO_CC >= 0x5130)
123 # define CRYPTOPP_CXX11_STATIC_INIT 1
127 #if (CRYPTOPP_MSC_VERSION >= 1800) || (CRYPTOPP_LLVM_CLANG_VERSION >= 20900) || \
128 (CRYPTOPP_APPLE_CLANG_VERSION >= 40000) || (__INTEL_COMPILER >= 1210) || \
129 (CRYPTOPP_GCC_VERSION >= 40300) || (__SUNPRO_CC >= 0x5130)
130 # define CRYPTOPP_CXX11_DELETED_FUNCTIONS 1
134 #if (CRYPTOPP_MSC_VERSION >= 1900) || __has_feature(cxx_alignas) || \
135 (__INTEL_COMPILER >= 1500) || (CRYPTOPP_GCC_VERSION >= 40800) || (__SUNPRO_CC >= 0x5130)
136 # define CRYPTOPP_CXX11_ALIGNAS 1
140 #if (CRYPTOPP_MSC_VERSION >= 1900) || __has_feature(cxx_alignof) || \
141 (__INTEL_COMPILER >= 1500) || (CRYPTOPP_GCC_VERSION >= 40500) || (__SUNPRO_CC >= 0x5130)
142 # define CRYPTOPP_CXX11_ALIGNOF 1
146 #if (CRYPTOPP_MSC_VERSION >= 1800) || (CRYPTOPP_LLVM_CLANG_VERSION >= 30100) || \
147 (CRYPTOPP_APPLE_CLANG_VERSION >= 40000) || (__INTEL_COMPILER >= 1400) || \
148 (CRYPTOPP_GCC_VERSION >= 40400) || (__SUNPRO_CC >= 0x5130)
149 # define CRYPTOPP_CXX11_INITIALIZER_LIST 1
153 #if (CRYPTOPP_MSC_VERSION >= 1700) || __has_feature(cxx_lambdas) || \
154 (__INTEL_COMPILER >= 1200) || (CRYPTOPP_GCC_VERSION >= 40900) || (__SUNPRO_CC >= 0x5140)
155 # define CRYPTOPP_CXX11_LAMBDA 1
159 #if (CRYPTOPP_MSC_VERSION >= 1900) || __has_feature(cxx_noexcept) || \
160 (__INTEL_COMPILER >= 1400) || (CRYPTOPP_GCC_VERSION >= 40600) || (__SUNPRO_CC >= 0x5130)
161 # define CRYPTOPP_CXX11_NOEXCEPT 1
165 #if (__cpp_variadic_templates >= 200704) || __has_feature(cxx_variadic_templates) || \
166 (CRYPTOPP_MSC_VERSION >= 1800) || (__INTEL_COMPILER >= 1210) || \
167 (CRYPTOPP_GCC_VERSION >= 40300) || (__SUNPRO_CC >= 0x5130)
168 # define CRYPTOPP_CXX11_VARIADIC_TEMPLATES 1
173 #if (__cpp_constexpr >= 200704) || __has_feature(cxx_constexpr) || \
174 (CRYPTOPP_MSC_VERSION >= 1900) || (__INTEL_COMPILER >= 1600) || \
175 (CRYPTOPP_GCC_VERSION >= 40600) || (__SUNPRO_CC >= 0x5130)
176 # define CRYPTOPP_CXX11_CONSTEXPR 1
181 #if (CRYPTOPP_MSC_VERSION >= 1700) || __has_feature(cxx_strong_enums) || \
182 (__INTEL_COMPILER >= 1400) || (CRYPTOPP_GCC_VERSION >= 40400) || (__SUNPRO_CC >= 0x5120)
183 # define CRYPTOPP_CXX11_STRONG_ENUM 1
187 #if (CRYPTOPP_MSC_VERSION >= 1600) || __has_feature(cxx_nullptr) || \
188 (__INTEL_COMPILER >= 1000) || (CRYPTOPP_GCC_VERSION >= 40600) || \
189 (__SUNPRO_CC >= 0x5130) || defined(__IBMCPP_NULLPTR)
190 # define CRYPTOPP_CXX11_NULLPTR 1
197 #if defined(CRYPTOPP_CXX14)
201 #if (__cpp_static_assert >= 201411)
202 # define CRYPTOPP_CXX17_STATIC_ASSERT 1
210 #if defined(CRYPTOPP_CXX17)
217 #if defined(__clang__)
218 # if __EXCEPTIONS && __has_feature(cxx_exceptions)
219 # if __cpp_lib_uncaught_exceptions >= 201411L
220 # define CRYPTOPP_CXX17_UNCAUGHT_EXCEPTIONS 1
223 #elif (CRYPTOPP_MSC_VERSION >= 1900) || (__INTEL_COMPILER >= 1800) || \
224 (CRYPTOPP_GCC_VERSION >= 60000) || (__cpp_lib_uncaught_exceptions >= 201411L)
225 # define CRYPTOPP_CXX17_UNCAUGHT_EXCEPTIONS 1
232 #if defined(CRYPTOPP_CXX11_NOEXCEPT)
233 # define CRYPTOPP_THROW noexcept(false)
234 # define CRYPTOPP_NO_THROW noexcept(true)
236 # define CRYPTOPP_THROW
237 # define CRYPTOPP_NO_THROW
241 #if defined(CRYPTOPP_CXX11_NULLPTR) && !defined(NULLPTR)
242 # define NULLPTR nullptr
243 #elif !defined(NULLPTR)
244 # define NULLPTR NULL
Library configuration file.
Library configuration file.
Library configuration file.