OGLplus  (0.59.0) a C++ wrapper for rendering APIs

config.hpp
Go to the documentation of this file.
1 #ifndef EAGINE_SSL_API_CONFIG_HPP
9 #define EAGINE_SSL_API_CONFIG_HPP
10 
11 #include "../config/basic.hpp"
12 #include <eagine/maybe_unused.hpp>
13 
14 #ifndef EAGINE_HAS_SSL
15 #if defined(OPENSSL_VERSION_NUMBER)
16 #define EAGINE_HAS_SSL 1
17 #else
18 #define EAGINE_HAS_SSL 0
19 #endif
20 #endif // EAGINE_HAS_SSL
21 
22 #if !EAGINE_HAS_SSL
23 #include <eagine/nothing.hpp>
24 #endif
25 
26 namespace eagine::sslp {
27 //------------------------------------------------------------------------------
28 struct ssl_types {
29 #if EAGINE_HAS_SSL
30  static constexpr bool has_api = true;
31  using ui_method_type = ::UI_METHOD;
32  using engine_type = ::ENGINE;
33  using bio_method_type = ::BIO_METHOD;
34  using bio_type = ::BIO;
35  using evp_pkey_ctx_type = ::EVP_PKEY_CTX;
36  using evp_pkey_type = ::EVP_PKEY;
37  using evp_cipher_ctx_type = ::EVP_CIPHER_CTX;
38  using evp_cipher_type = ::EVP_CIPHER;
39  using evp_md_ctx_type = ::EVP_MD_CTX;
40  using evp_md_type = ::EVP_MD;
41  using x509_lookup_method_type = ::X509_LOOKUP_METHOD;
42  using x509_lookup_type = ::X509_LOOKUP;
43  using x509_store_ctx_type = ::X509_STORE_CTX;
44  using x509_store_type = ::X509_STORE;
45  using x509_crl_type = ::X509_CRL;
46  using x509_type = ::X509;
47  using x509_stack_type = STACK_OF(X509);
48 #else
49  static constexpr bool has_api = false;
50  using engine_type = nothing_t;
51  using bio_method_type = nothing_t;
52  using bio_type = nothing_t;
53  using evp_pkey_ctx_type = nothing_t;
54  using evp_pkey_type = nothing_t;
55  using evp_cipher_ctx_type = nothing_t;
56  using evp_cipher_type = nothing_t;
57  using evp_md_ctx_type = nothing_t;
58  using evp_md_type = nothing_t;
59  using x509_lookup_method_type = nothing_t;
60  using x509_lookup_type = nothing_t;
61  using x509_store_ctx_type = nothing_t;
62  using x509_store_type = nothing_t;
63  using x509_crl_type = nothing_t;
64  using x509_type = nothing_t;
65  using x509_stack_type = nothing_t;
66 #endif
67 };
68 //------------------------------------------------------------------------------
69 } // namespace eagine::sslp
70 
71 #endif // EAGINE_SSL_API_CONFIG_HPP

Copyright © 2015-2021 Matúš Chochlík.
<chochlik -at -gmail.com>
Documentation generated on Tue Apr 13 2021 by Doxygen (version 1.8.17).