21 #define SEQAN3_STR_HELPER(x) #x
22 #define SEQAN3_STR(x) SEQAN3_STR_HELPER(x)
31 static_assert(__cplusplus >= 201703,
"SeqAn3 requires C++17, make sure that you have set -std=c++17.");
33 # error "This is not a C++ compiler."
36 #if __has_include(<version>)
42 # if __cpp_concepts == 201507
43 # define SEQAN3_CONCEPT concept bool
45 static_assert(__cpp_concepts >= 201507,
"Your compiler supports Concepts, but the support is not recent enough.");
46 # define SEQAN3_CONCEPT concept
49 # error "SeqAn3 requires C++ Concepts, either via the TS (flag: -fconcepts) or via C++20 (flag: -std=c++2a / -std=c++20)."
53 #if defined(__GNUC__) && (__GNUC__ < 10)
54 # define SEQAN3_RETURN_TYPE_CONSTRAINT(expression, concept_name, ...) \
55 {expression}; requires concept_name<decltype(expression), __VA_ARGS__>
57 # define SEQAN3_RETURN_TYPE_CONSTRAINT(expression, concept_name, ...) \
58 {expression} -> concept_name<__VA_ARGS__>
62 #if !__has_include(<filesystem>)
63 # if !__has_include(<experimental/filesystem>)
64 # error SeqAn3 requires C++17 filesystem support, but it was not found.
73 #if __has_include(<seqan3/version.hpp>)
76 # error SeqAn3 include directory not set correctly. Forgot to add -I ${INSTALLDIR}/include to your CXXFLAGS?
80 #if __has_include(<range/v3/version.hpp>)
81 # define RANGE_V3_MINVERSION 1100
82 # define RANGE_V3_MAXVERSION 1199
84 # define SEQAN3_MSG "Your version: " SEQAN3_STR(RANGE_V3_VERSION) \
85 "; minimum version: " SEQAN3_STR(RANGE_V3_MINVERSION) \
86 "; expected maximum version: " SEQAN3_STR(RANGE_V3_MAXVERSION)
87 # include <range/v3/version.hpp>
88 # if RANGE_V3_VERSION < RANGE_V3_MINVERSION
89 # error Your range-v3 library is too old.
90 # pragma message(SEQAN3_MSG)
91 # elif RANGE_V3_VERSION > RANGE_V3_MAXVERSION
92 # pragma GCC warning "Your range-v3 library is possibly too new. Some features might not work correctly."
93 # pragma message(SEQAN3_MSG)
97 # error The range-v3 library was not included correctly. Forgot to add -I ${INSTALLDIR}/include to your CXXFLAGS?
101 #if __has_include(<sdsl/version.hpp>)
102 # include <sdsl/version.hpp>
103 static_assert(sdsl::sdsl_version_major == 3,
"Only version 3 of the SDSL is supported by SeqAn3.");
105 # error The sdsl library was not included correctly. Forgot to add -I ${INSTALLDIR}/include to your CXXFLAGS?
113 #ifndef SEQAN3_WITH_CEREAL
114 # if __has_include(<cereal/cereal.hpp>)
115 # define SEQAN3_WITH_CEREAL 1
117 # define SEQAN3_WITH_CEREAL 0
119 #elif SEQAN3_WITH_CEREAL != 0
120 # if ! __has_include(<cereal/cereal.hpp>)
121 # error Cereal was marked as required, but not found!
125 #if !SEQAN3_WITH_CEREAL
134 # define CEREAL_SERIALIZE_FUNCTION_NAME serialize
136 # define CEREAL_LOAD_FUNCTION_NAME load
138 # define CEREAL_SAVE_FUNCTION_NAME save
140 # define CEREAL_LOAD_MINIMAL_FUNCTION_NAME load_minimal
142 # define CEREAL_SAVE_MINIMAL_FUNCTION_NAME save_minimal
153 #ifndef SEQAN3_WITH_LEMON
154 # if __has_include(<lemon/config.h>)
155 # define SEQAN3_WITH_LEMON 1
157 # define SEQAN3_WITH_LEMON 0
159 #elif SEQAN3_WITH_LEMON != 0
160 # if !__has_include(<lemon/config.h>)
161 # error Lemon was marked as required, but not found!
164 #if SEQAN3_WITH_LEMON == 1
165 # define LEMON_HAVE_LONG_LONG 1
166 # define LEMON_CXX11 1
167 # if defined(__unix__) || defined(__APPLE__)
168 # define LEMON_USE_PTHREAD 1
169 # define LEMON_USE_WIN32_THREADS 0
170 # define LEMON_WIN32 0
172 # define LEMON_USE_PTHREAD 0
173 # define LEMON_USE_WIN32_THREADS 1
174 # define LEMON_WIN32 1
186 #ifndef SEQAN3_DOXYGEN_ONLY
187 # define SEQAN3_DOXYGEN_ONLY(x)
195 #ifndef SEQAN3_PRAGMA
196 # define SEQAN3_PRAGMA(non_string_literal) _Pragma(#non_string_literal)
200 #ifndef SEQAN3_DEPRECATED_HEADER
201 # ifndef SEQAN3_DISABLE_DEPRECATED_WARNINGS
202 # define SEQAN3_DEPRECATED_HEADER(message) SEQAN3_PRAGMA(GCC warning message)
204 # define SEQAN3_DEPRECATED_HEADER(message)
218 #if defined(__GNUC__) && (__GNUC__ == 10 && __GNUC_MINOR__ <= 1)
219 # pragma GCC warning "Be aware that gcc 10.0 and 10.1 are known to have several bugs that might make SeqAn3 fail to compile. Please use gcc >= 10.2."
222 #ifndef SEQAN3_WORKAROUND_VIEW_PERFORMANCE
224 # define SEQAN3_WORKAROUND_VIEW_PERFORMANCE 1
228 #ifndef SEQAN3_WORKAROUND_ISSUE_286
229 # if defined(__GNUC__) && (__GNUC__ <= 9)
230 # define SEQAN3_WORKAROUND_ISSUE_286 1
232 # define SEQAN3_WORKAROUND_ISSUE_286 0
237 #ifndef SEQAN3_WORKAROUND_GCC_83328
238 # if defined(__GNUC__) && (__GNUC__ <= 8)
239 # define SEQAN3_WORKAROUND_GCC_83328 1
241 # define SEQAN3_WORKAROUND_GCC_83328 0
246 #ifndef SEQAN3_WORKAROUND_GCC_87113
247 # if defined(__GNUC_MINOR__) && ((__GNUC__ == 7) || ((__GNUC__ == 8) && (__GNUC_MINOR__ < 3)))
248 # define SEQAN3_WORKAROUND_GCC_87113 1
250 # define SEQAN3_WORKAROUND_GCC_87113 0
255 #ifndef SEQAN3_WORKAROUND_GCC_89953
256 # if defined(__GNUC_MINOR__) && (__GNUC__ == 9 && __GNUC_MINOR__ < 3)
257 # define SEQAN3_WORKAROUND_GCC_89953 1
259 # define SEQAN3_WORKAROUND_GCC_89953 0
264 #ifndef SEQAN3_WORKAROUND_GCC_90897
265 # if defined(__GNUC__) && (__GNUC__ == 8 && __GNUC_MINOR__ < 4)
266 # define SEQAN3_WORKAROUND_GCC_90897 1
268 # define SEQAN3_WORKAROUND_GCC_90897 0
273 #ifndef SEQAN3_WORKAROUND_GCC7_AND_8_CONCEPT_ISSUES
274 # if defined(__GNUC__) && ((__GNUC__ == 7) || (__GNUC__ == 8))
275 # define SEQAN3_WORKAROUND_GCC7_AND_8_CONCEPT_ISSUES 1
277 # define SEQAN3_WORKAROUND_GCC7_AND_8_CONCEPT_ISSUES 0
282 #ifndef SEQAN3_WORKAROUND_GCC_93467
283 # if defined(__GNUC__) && ((__GNUC__ <= 9) || (__GNUC__ == 10 && __GNUC_MINOR__ < 2))
284 # define SEQAN3_WORKAROUND_GCC_93467 1
286 # define SEQAN3_WORKAROUND_GCC_93467 0
292 #ifndef SEQAN3_WORKAROUND_GCC_94967
293 # if defined(__GNUC__) && (__GNUC__ <= 7)
294 # define SEQAN3_WORKAROUND_GCC_94967 1
296 # define SEQAN3_WORKAROUND_GCC_94967 0
301 #ifndef SEQAN3_WORKAROUND_GCC_96070
302 # if defined(__GNUC__) && (__GNUC__ == 10 && __GNUC_MINOR__ < 4)
303 # define SEQAN3_WORKAROUND_GCC_96070 1
305 # define SEQAN3_WORKAROUND_GCC_96070 0
310 #ifndef SEQAN3_WORKAROUND_GCC_99318
311 # if defined(__GNUC__) && (__GNUC__ == 10 && __GNUC_MINOR__ < 3)
312 # define SEQAN3_WORKAROUND_GCC_99318 1
314 # define SEQAN3_WORKAROUND_GCC_99318 0
320 #ifndef SEQAN3_WORKAROUND_GCC_100139
321 # if defined(__GNUC__)
322 # define SEQAN3_WORKAROUND_GCC_100139 1
324 # define SEQAN3_WORKAROUND_GCC_100139 0
338 #ifndef SEQAN3_WORKAROUND_GCC_NO_CXX11_ABI
339 # if defined(_GLIBCXX_USE_CXX11_ABI) && _GLIBCXX_USE_CXX11_ABI == 0
340 # define SEQAN3_WORKAROUND_GCC_NO_CXX11_ABI 1
342 # define SEQAN3_WORKAROUND_GCC_NO_CXX11_ABI 0
346 #if SEQAN3_DOXYGEN_ONLY(1)0
348 #define SEQAN3_DISABLE_LEGACY_STD_DIAGNOSTIC
351 #if defined(_GLIBCXX_USE_CXX11_ABI) && _GLIBCXX_USE_CXX11_ABI == 0
352 # ifndef SEQAN3_DISABLE_LEGACY_STD_DIAGNOSTIC
353 # pragma GCC warning "We do not actively support compiler that have -D_GLIBCXX_USE_CXX11_ABI=0 set, and it might be that SeqAn does not compile due to this. It is known that all compiler of CentOS 7 / RHEL 7 set this flag by default (and that it cannot be overridden!). Note that these versions of the OSes are community-supported (see https://docs.seqan.de/seqan/3-master-user/about_api.html#platform_stability for more details). You can disable this warning by setting -DSEQAN3_DISABLE_LEGACY_STD_DIAGNOSTIC."
360 #ifndef SEQAN3_WORKAROUND_GCC_NON_TEMPLATE_REQUIRES
361 # if defined(__GNUC_MINOR__) && (__GNUC__ < 10)
362 # define SEQAN3_WORKAROUND_GCC_NON_TEMPLATE_REQUIRES 1
364 # define SEQAN3_WORKAROUND_GCC_NON_TEMPLATE_REQUIRES 0
370 #ifndef SEQAN3_WORKAROUND_GCC_PIPEABLE_CONFIG_CONCEPT
371 # if defined(__GNUC__) && (__GNUC__ < 11)
372 # define SEQAN3_WORKAROUND_GCC_PIPEABLE_CONFIG_CONCEPT 1
374 # define SEQAN3_WORKAROUND_GCC_PIPEABLE_CONFIG_CONCEPT 0
379 #ifndef SEQAN3_WORKAROUND_GCC_INCOMPLETE_FILESYSTEM
380 # if defined(__GNUC__) && (__GNUC__ == 7)
381 # define SEQAN3_WORKAROUND_GCC_INCOMPLETE_FILESYSTEM 1
383 # define SEQAN3_WORKAROUND_GCC_INCOMPLETE_FILESYSTEM 0
394 #undef SEQAN3_STR_HELPER
Provides SeqAn version macros and global variables.