aboutsummaryrefslogtreecommitdiff
path: root/devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp')
-rw-r--r--devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp78
1 files changed, 75 insertions, 3 deletions
diff --git a/devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp b/devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp
index a239d042f9e3..82af12b7bd8a 100644
--- a/devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp
+++ b/devel/ice/files/patch-cpp-src-IceSSL-OpenSSLEngine.cpp
@@ -1,6 +1,51 @@
---- cpp/src/IceSSL/OpenSSLEngine.cpp.orig 2015-09-14 23:12:17.842563990 +0000
-+++ cpp/src/IceSSL/OpenSSLEngine.cpp 2015-09-14 23:13:21.929560990 +0000
-@@ -267,7 +267,9 @@
+--- cpp/src/IceSSL/OpenSSLEngine.cpp.orig 2016-10-05 16:59:08.000000000 +0200
++++ cpp/src/IceSSL/OpenSSLEngine.cpp 2016-10-12 01:59:40.150375902 +0200
+@@ -43,7 +43,7 @@
+ int instanceCount = 0;
+ bool initOpenSSL = false;
+
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ IceUtil::Mutex* locks = 0;
+ #endif
+
+@@ -62,7 +62,7 @@
+ // OpenSSL 1.1.0 introduces a new thread API and removes
+ // the need to use a custom thread callback.
+ //
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ CRYPTO_set_locking_callback(0);
+ CRYPTO_set_id_callback(0);
+
+@@ -87,7 +87,7 @@
+ // OpenSSL 1.1.0 introduces a new thread API and removes
+ // the need to use a custom thread callback.
+ //
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ //
+ // OpenSSL mutex callback.
+ //
+@@ -158,7 +158,7 @@
+ DH*
+ IceSSL_opensslDHCallback(SSL* ssl, int /*isExport*/, int keyLength)
+ {
+-# if OPENSSL_VERSION_NUMBER >= 0x10100000L
++# if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
+ SSL_CTX* ctx = SSL_get_SSL_CTX(ssl);
+ # else
+ SSL_CTX* ctx = ssl->ctx;
+@@ -219,7 +219,7 @@
+ //
+ // OpenSSL 1.1.0 remove the need for library initialization and cleanup.
+ //
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ //
+ // Create the mutexes and set the callbacks.
+ //
+@@ -292,7 +292,9 @@
string entropyDaemon = properties->getProperty("IceSSL.EntropyDaemon");
if(!entropyDaemon.empty())
{
@@ -10,3 +55,30 @@
{
throw PluginInitializationException(__FILE__, __LINE__,
"IceSSL: EGD failure using file " + entropyDaemon);
+@@ -326,7 +328,7 @@
+ //
+ // OpenSSL 1.1.0 remove the need for library initialization and cleanup.
+ //
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ //
+ // Clean up OpenSSL resources.
+ //
+@@ -399,7 +401,7 @@
+ "IceSSL: unable to create SSL context:\n" + sslErrors());
+ }
+
+-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
+ int securityLevel = properties->getPropertyAsIntWithDefault(propPrefix + "SecurityLevel", -1);
+ if(securityLevel != -1)
+ {
+@@ -954,7 +956,7 @@
+ SSL_METHOD*
+ OpenSSLEngine::getMethod(int /*protocols*/)
+ {
+-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
+ SSL_METHOD* meth = const_cast<SSL_METHOD*>(TLS_method());
+ #else
+ //