Use XMRIG_FEATURE_TLS instead of XMRIG_NO_TLS

This commit is contained in:
XMRig 2019-03-28 22:13:27 +07:00
parent 5db458efd4
commit 034720e888
8 changed files with 19 additions and 31 deletions

View file

@ -27,7 +27,7 @@
#include <uv.h>
#ifndef XMRIG_NO_TLS
#ifdef XMRIG_FEATURE_TLS
# include <openssl/ssl.h>
# include <openssl/err.h>
#endif
@ -41,7 +41,7 @@ xmrig::String Platform::m_userAgent;
void Platform::init(const char *userAgent)
{
# ifndef XMRIG_NO_TLS
# ifdef XMRIG_FEATURE_TLS
SSL_library_init();
SSL_load_error_strings();
ERR_load_BIO_strings();

View file

@ -35,7 +35,7 @@
#endif
#ifndef XMRIG_NO_TLS
#ifdef XMRIG_FEATURE_TLS
# include <openssl/opensslv.h>
#endif
@ -131,12 +131,12 @@ void xmrig::CommonConfig::printVersions()
# else
memset(buf, 0, 16);
# if !defined(XMRIG_NO_HTTPD) || !defined(XMRIG_NO_TLS)
# if !defined(XMRIG_NO_HTTPD) || defined(XMRIG_FEATURE_TLS)
int length = 0;
# endif
# endif
# if !defined(XMRIG_NO_TLS) && defined(OPENSSL_VERSION_TEXT)
# if defined(XMRIG_FEATURE_TLS) && defined(OPENSSL_VERSION_TEXT)
{
constexpr const char *v = OPENSSL_VERSION_TEXT + 8;
length += snprintf(buf + length, (sizeof buf) - length, "OpenSSL/%.*s ", static_cast<int>(strchr(v, ' ') - v), v);

View file

@ -29,16 +29,6 @@
#include <uv.h>
#ifndef XMRIG_NO_HTTPD
# include <microhttpd.h>
#endif
#ifndef XMRIG_NO_TLS
# include <openssl/opensslv.h>
#endif
#include "base/io/Json.h"
#include "base/kernel/interfaces/IConfigListener.h"
#include "base/kernel/Process.h"