Fast RTPS  Version 2.6.0
Fast RTPS
config.h
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 _FASTRTPS_CONFIG_H_
16 #define _FASTRTPS_CONFIG_H_
17 
18 #define FASTRTPS_VERSION_MAJOR 2
19 #define FASTRTPS_VERSION_MINOR 6
20 #define FASTRTPS_VERSION_MICRO 0
21 #define FASTRTPS_VERSION_STR "2.6.0"
22 
23 #define GEN_API_VER 1
24 
25 // C++20 support defines
26 #ifndef HAVE_CXX20
27 #define HAVE_CXX20 0
28 #endif /* ifndef HAVE_CXX20 */
29 
30 // C++17 support defines
31 #ifndef HAVE_CXX17
32 #define HAVE_CXX17 0
33 #endif /* ifndef HAVE_CXX17 */
34 
35 // C++14 support defines
36 #ifndef HAVE_CXX14
37 #define HAVE_CXX14 0
38 #endif /* ifndef HAVE_CXX14 */
39 
40 // C++1Y support defines
41 #ifndef HAVE_CXX1Y
42 #define HAVE_CXX1Y 0
43 #endif /* ifndef HAVE_CXX1Y */
44 
45 // C++11 support defines
46 #ifndef HAVE_CXX11
47 #define HAVE_CXX11 1
48 #endif /* ifndef HAVE_CXX11 */
49 
50 // C++0x support defines
51 #ifndef HAVE_CXX0X
52 #define HAVE_CXX0X 1
53 #endif /* ifndef HAVE_CXX0X */
54 
55 // C++ constexpr support
56 #ifndef HAVE_CXX_CONSTEXPR
57 #define HAVE_CXX_CONSTEXPR 1
58 #endif /* ifndef HAVE_CXX_CONSTEXPR */
59 
60 #if HAVE_CXX_CONSTEXPR
61 #define CONSTEXPR constexpr
62 #else
63 #define CONSTEXPR const
64 #endif /* if HAVE_CXX_CONSTEXPR */
65 
66 // Endianness defines
67 #ifndef FASTDDS_IS_BIG_ENDIAN_TARGET
68 #define FASTDDS_IS_BIG_ENDIAN_TARGET 0
69 #endif /* ifndef FASTDDS_IS_BIG_ENDIAN_TARGET */
70 
71 // Security
72 #ifndef HAVE_SECURITY
73 #define HAVE_SECURITY 0
74 #endif /* ifndef HAVE_SECURITY */
75 
76 //Sqlite3 support
77 #ifndef HAVE_SQLITE3
78 #define HAVE_SQLITE3 1
79 #endif /* ifndef HAVE_SQLITE3 */
80 
81 
82 // TLS support
83 #ifndef TLS_FOUND
84 #define TLS_FOUND 1
85 #endif /* ifndef TLS_FOUND */
86 
87 // Strict real-time
88 #ifndef HAVE_STRICT_REALTIME
89 #define HAVE_STRICT_REALTIME 0
90 #endif /* ifndef HAVE_STRICT_REALTIME */
91 
92 /* Log Macros */
93 
94 // Log Info
95 /* #undef FASTDDS_ENFORCE_LOG_INFO */
96 #ifndef HAVE_LOG_NO_INFO
97 #define HAVE_LOG_NO_INFO 1
98 #endif /* ifndef HAVE_LOG_NO_INFO */
99 
100 // Log Warning
101 #ifndef HAVE_LOG_NO_WARNING
102 #define HAVE_LOG_NO_WARNING 0
103 #endif /* ifndef HAVE_LOG_NO_WARNING */
104 
105 // Log Error
106 #ifndef HAVE_LOG_NO_ERROR
107 #define HAVE_LOG_NO_ERROR 0
108 #endif /* ifndef HAVE_LOG_NO_ERROR */
109 
110 // Statistics
111 /* #undef FASTDDS_STATISTICS */
112 
113 // Deprecated macro
114 #if __cplusplus >= 201402L
115 #define FASTRTPS_DEPRECATED(msg) [[ deprecated(msg) ]]
116 #elif defined(__GNUC__) || defined(__clang__)
117 #define FASTRTPS_DEPRECATED(msg) __attribute__ ((deprecated(msg)))
118 #elif defined(_MSC_VER)
119 #define FASTRTPS_DEPRECATED(msg) __declspec(deprecated(msg))
120 #else
121 #define FASTRTPS_DEPRECATED(msg)
122 #endif /* if __cplusplus >= 201402L */
123 
124 // Deprecation with version
125 #define FASTDDS_DEPRECATED_UNTIL(major, entity_name, msg) \
126  static_assert(FASTRTPS_VERSION_MAJOR < major, #entity_name " reached deprecation version " #major); \
127  FASTRTPS_DEPRECATED(#entity_name " has been deprecated and will be removed on major version " #major ". " msg)
128 
129 #define FASTDDS_TODO_BEFORE(major, minor, msg) \
130  static_assert((FASTRTPS_VERSION_MAJOR < major) || \
131  (FASTRTPS_VERSION_MAJOR == major && FASTRTPS_VERSION_MINOR < minor), \
132  "TODO before version " #major "." #minor " : " #msg);
133 
134 #endif // _FASTRTPS_CONFIG_H_