5 // Created by Martin Baulig on 3/23/16.
6 // Copyright © 2016 Xamarin. All rights reserved.
9 #ifndef __btls__btls_util__
10 #define __btls__btls_util__
15 #include <openssl/ssl.h>
19 #if !defined(MONO_DLL_IMPORT) && !defined(MONO_DLL_EXPORT)
20 #define MONO_DLL_EXPORT
25 #define MONO_API_EXPORT __declspec(dllexport)
26 #define MONO_API_IMPORT __declspec(dllimport)
30 #if defined (__clang__) || defined (__GNUC__)
31 #define MONO_API_EXPORT __attribute__ ((__visibility__ ("default")))
33 #define MONO_API_EXPORT
35 #define MONO_API_IMPORT
40 #define MONO_EXTERN_C extern "C"
42 #define MONO_EXTERN_C /* nothing */
45 #if defined(MONO_DLL_EXPORT)
46 #define MONO_API_NO_EXTERN_C MONO_API_EXPORT
47 #elif defined(MONO_DLL_IMPORT)
48 #define MONO_API_NO_EXTERN_C MONO_API_IMPORT
50 #define MONO_API_NO_EXTERN_C /* nothing */
53 #define MONO_API MONO_EXTERN_C MONO_API_NO_EXTERN_C
57 mono_btls_free (void *data
);
60 mono_btls_util_asn1_time_to_ticks (ASN1_TIME
*time
);
63 mono_btls_debug_printf (BIO
*bio
, const char *format
, va_list args
);
65 OPENSSL_EXPORT
void CRYPTO_refcount_inc(CRYPTO_refcount_t
*count
);
66 OPENSSL_EXPORT
int CRYPTO_refcount_dec_and_test_zero(CRYPTO_refcount_t
*count
);
68 #endif /* __btls__btls_util__ */