Fast DDS  Version 3.6.1.0
Fast DDS
config.hpp
1 // Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 #ifndef FASTDDS__CONFIG_H
16 #define FASTDDS__CONFIG_H
17 
18 #define FASTDDS_VERSION_MAJOR 3
19 #define FASTDDS_VERSION_MINOR 6
20 #define FASTDDS_VERSION_MICRO 1
21 #define FASTDDS_VERSION_TWEAK 0
22 #define FASTDDS_VERSION_STR "3.6.1.0"
23 
24 #define FASTDDS_GEN_API_VER 3
25 
26 // C++20 support defines
27 #ifndef HAVE_CXX20
28 #define HAVE_CXX20 0
29 #endif /* ifndef HAVE_CXX20 */
30 
31 // C++17 support defines
32 #ifndef HAVE_CXX17
33 #define HAVE_CXX17 0
34 #endif /* ifndef HAVE_CXX17 */
35 
36 // C++14 support defines
37 #ifndef HAVE_CXX14
38 #define HAVE_CXX14 0
39 #endif /* ifndef HAVE_CXX14 */
40 
41 // C++1Y support defines
42 #ifndef HAVE_CXX1Y
43 #define HAVE_CXX1Y 0
44 #endif /* ifndef HAVE_CXX1Y */
45 
46 // C++11 support defines
47 #ifndef HAVE_CXX11
48 #define HAVE_CXX11 1
49 #endif /* ifndef HAVE_CXX11 */
50 
51 // Endianness defines
52 #ifndef FASTDDS_IS_BIG_ENDIAN_TARGET
53 #define FASTDDS_IS_BIG_ENDIAN_TARGET 0
54 #endif /* ifndef FASTDDS_IS_BIG_ENDIAN_TARGET */
55 
56 // Security
57 #ifndef HAVE_SECURITY
58 #define HAVE_SECURITY 0
59 #endif /* ifndef HAVE_SECURITY */
60 
61 //Sqlite3 support
62 #ifndef HAVE_SQLITE3
63 #define HAVE_SQLITE3 1
64 #endif /* ifndef HAVE_SQLITE3 */
65 
66 // Using thirdparty shared_mutex
67 #define USE_THIRDPARTY_SHARED_MUTEX 1
68 
69 // TLS support
70 #ifndef TLS_FOUND
71 #define TLS_FOUND 1
72 #endif /* ifndef TLS_FOUND */
73 
74 // Strict real-time
75 #ifndef HAVE_STRICT_REALTIME
76 #define HAVE_STRICT_REALTIME 0
77 #endif /* ifndef HAVE_STRICT_REALTIME */
78 
79 /* Log Macros */
80 
81 // Enable compilation for eProsima Log Macros
82 #ifndef ENABLE_OLD_LOG_MACROS_
83 #define ENABLE_OLD_LOG_MACROS_ 1
84 #endif /* ifndef ENABLE_OLD_LOG_MACROS_ */
85 
86 // Log Info
87 #ifndef FASTDDS_ENFORCE_LOG_INFO
88 /* #undef FASTDDS_ENFORCE_LOG_INFO */
89 #endif // ifndef FASTDDS_ENFORCE_LOG_INFO
90 #ifndef HAVE_LOG_NO_INFO
91 #define HAVE_LOG_NO_INFO 1
92 #endif /* ifndef HAVE_LOG_NO_INFO */
93 
94 // Log Warning
95 #ifndef HAVE_LOG_NO_WARNING
96 #define HAVE_LOG_NO_WARNING 0
97 #endif /* ifndef HAVE_LOG_NO_WARNING */
98 
99 // Log Error
100 #ifndef HAVE_LOG_NO_ERROR
101 #define HAVE_LOG_NO_ERROR 0
102 #endif /* ifndef HAVE_LOG_NO_ERROR */
103 
104 // Statistics
105 #define FASTDDS_STATISTICS
106 
107 // Deprecated macro
108 #if __cplusplus >= 201402L
109 #define FASTDDS_DEPRECATED(msg) [[ deprecated(msg) ]]
110 #elif defined(__GNUC__) || defined(__clang__)
111 #define FASTDDS_DEPRECATED(msg) __attribute__ ((deprecated(msg)))
112 #elif defined(_MSC_VER)
113 #define FASTDDS_DEPRECATED(msg) __declspec(deprecated(msg))
114 #else
115 #define FASTDDS_DEPRECATED(msg)
116 #endif /* if __cplusplus >= 201402L */
117 
118 // Deprecation with version
119 #define FASTDDS_DEPRECATED_UNTIL(major, entity_name, msg) \
120  static_assert(FASTDDS_VERSION_MAJOR < major, #entity_name " reached deprecation version " #major); \
121  FASTDDS_DEPRECATED(#entity_name " has been deprecated and will be removed on major version " #major ". " msg)
122 
123 #define FASTDDS_TODO_BEFORE(major, minor, msg) \
124  static_assert((FASTDDS_VERSION_MAJOR < major) || \
125  (FASTDDS_VERSION_MAJOR == major && FASTDDS_VERSION_MINOR < minor), \
126  "TODO before version " #major "." #minor " : " #msg)
127 
128 #if defined(_MSC_VER) && !defined(__clang__)
129 # define FASTDDS_UNREACHABLE() __assume(0)
130 #elif defined(__GNUC__) || defined(__clang__)
131 # define FASTDDS_UNREACHABLE() __builtin_unreachable()
132 #else
133 # include <cstdlib>
134 # define FASTDDS_UNREACHABLE() std::abort()
135 #endif // if defined(_MSC_VER) && !defined(__clang__)
136 
137 #endif // FASTDDS__CONFIG_H