Kea  2.3.5-git
asio_wrapper.h
Go to the documentation of this file.
1 // Copyright (C) 2016-2022 Internet Systems Consortium, Inc. ("ISC")
2 //
3 // This Source Code Form is subject to the terms of the Mozilla Public
4 // License, v. 2.0. If a copy of the MPL was not distributed with this
5 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 #ifndef ASIO_WRAPPER_H
7 #define ASIO_WRAPPER_H 1
8 
62 
63 // Some boost headers need the <utility> header to be included for some Boost versions under C++20.
64 // Include it in all situations for simplicity.
65 #include <utility>
66 
67 #define GNU_CC_VERSION (__GNUC__ * 10000 \
68  + __GNUC_MINOR__ * 100 \
69  + __GNUC_PATCHLEVEL__)
70 
71 #if (defined(__GNUC__) && \
72  ((GNU_CC_VERSION >= 50200) && (GNU_CC_VERSION < 60000)) \
73  && defined(BOOST_ERROR_CODE_HEADER_ONLY))
74 #pragma GCC push_options
75 #pragma GCC optimize ("O0")
76 #include <boost/asio.hpp>
77 #pragma GCC pop_options
78 #else
79 #include <boost/asio.hpp>
80 #endif
81 
82 #endif // ASIO_WRAPPER_H