blob: 76b7eae9ec4d74b52fa009221ecf1c3a665cd174 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
// file : odb/details/config.hxx
// copyright : Copyright (c) 2005-2018 Code Synthesis Tools CC
// license : GNU GPL v2; see accompanying LICENSE file
#ifndef ODB_DETAILS_CONFIG_HXX
#define ODB_DETAILS_CONFIG_HXX
// no pre
// C++11 support.
//
#ifdef _MSC_VER
# if _MSC_VER >= 1600 // VC++10 and later have C++11 always enabled.
# define ODB_CXX11
# define ODB_CXX11_NULLPTR
# if _MSC_VER >= 1700
# define ODB_CXX11_ENUM
# if _MSC_VER >= 1800
# define ODB_CXX11_DELETED_FUNCTION
# define ODB_CXX11_EXPLICIT_CONVERSION_OPERATOR
# define ODB_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGUMENT
# define ODB_CXX11_VARIADIC_TEMPLATE
# define ODB_CXX11_INITIALIZER_LIST
# if _MSC_VER >= 1900
# define ODB_CXX11_NOEXCEPT
# endif
# endif
# endif
# endif
#else
# if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L
# define ODB_CXX11
# ifdef __clang__ // Pretends to be a really old __GNUC__ on some platforms.
# define ODB_CXX11_NULLPTR
# define ODB_CXX11_NOEXCEPT
# elif defined(__GNUC__)
# if (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4
# define ODB_CXX11_NULLPTR
# define ODB_CXX11_NOEXCEPT
# endif
# else
# define ODB_CXX11_NULLPTR
# define ODB_CXX11_NOEXCEPT
# endif
# define ODB_CXX11_DELETED_FUNCTION
# define ODB_CXX11_EXPLICIT_CONVERSION_OPERATOR
# define ODB_CXX11_FUNCTION_TEMPLATE_DEFAULT_ARGUMENT
# define ODB_CXX11_VARIADIC_TEMPLATE
# define ODB_CXX11_INITIALIZER_LIST
# define ODB_CXX11_ENUM // GCC 4.4 (forward -- 4.6), Clang 2.9 (3.1).
# endif
#endif
#ifdef ODB_CXX11_NOEXCEPT
# define ODB_NOTHROW_NOEXCEPT noexcept
#else
# define ODB_NOTHROW_NOEXCEPT throw()
#endif
// Once we drop support for C++98, we can probably get rid of config.h except
// for the autotools case by fixing ODB_THREADS_CXX11 (and perhaps supporting
// the ODB_THREADS_NONE case via a "global" (command line) define).
//
#ifdef ODB_COMPILER
# define ODB_THREADS_NONE
# define LIBODB_STATIC_LIB
#elif defined(LIBODB_BUILD2)
# if defined(_MSC_VER)
# include <odb/details/build2/config-vc.h>
# else
# include <odb/details/build2/config.h>
# endif
#elif defined(_MSC_VER)
# include <odb/details/config-vc.h>
#else
# include <odb/details/config.h>
#endif
// no post
#endif // ODB_DETAILS_CONFIG_HXX
|