summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
authorRobin Gloster <mail@glob.in>2015-11-29 17:01:20 +0000
committerRobin Gloster <mail@glob.in>2015-12-23 22:08:33 +0000
commit4b5cb624889f614990ccd9b9eef808e476ef8095 (patch)
tree7d3213814a7fffdfb5018f2df8e46e94fcc7b438 /pkgs/development
parentbdfc4efd670bdccba4e5f4969b72639aefdfe7d2 (diff)
downloadnixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar.gz
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar.bz2
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar.lz
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar.xz
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.tar.zst
nixpkgs-4b5cb624889f614990ccd9b9eef808e476ef8095.zip
qt4: add patch to build with libressl 2.3
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/libraries/qt-4.x/4.8/default.nix1
-rw-r--r--pkgs/development/libraries/qt-4.x/4.8/libressl.patch64
2 files changed, 65 insertions, 0 deletions
diff --git a/pkgs/development/libraries/qt-4.x/4.8/default.nix b/pkgs/development/libraries/qt-4.x/4.8/default.nix
index e4d1bae636c..25b547bf1cf 100644
--- a/pkgs/development/libraries/qt-4.x/4.8/default.nix
+++ b/pkgs/development/libraries/qt-4.x/4.8/default.nix
@@ -50,6 +50,7 @@ stdenv.mkDerivation rec {
 
   patches =
     [ ./glib-2.32.patch
+      ./libressl.patch
       (substituteAll {
         src = ./dlopen-absolute-paths.diff;
         inherit cups icu libXfixes;
diff --git a/pkgs/development/libraries/qt-4.x/4.8/libressl.patch b/pkgs/development/libraries/qt-4.x/4.8/libressl.patch
new file mode 100644
index 00000000000..5432610d9dc
--- /dev/null
+++ b/pkgs/development/libraries/qt-4.x/4.8/libressl.patch
@@ -0,0 +1,64 @@
+$OpenBSD: patch-src_network_ssl_qsslsocket_openssl_symbols_cpp,v 1.3 2015/09/17 12:24:42 dcoppa Exp $
+--- a/src/network/ssl/qsslsocket_openssl_symbols.cpp	Wed Sep 16 13:27:39 2015
++++ b/src/network/ssl/qsslsocket_openssl_symbols.cpp	Wed Sep 16 13:33:06 2015
+@@ -228,13 +228,17 @@ DEFINEFUNC(int, SSL_shutdown, SSL *a, a, return -1, re
+ #ifndef OPENSSL_NO_SSL2
+ DEFINEFUNC(const SSL_METHOD *, SSLv2_client_method, DUMMYARG, DUMMYARG, return 0, return)
+ #endif
++#ifndef OPENSSL_NO_SSL3
+ DEFINEFUNC(const SSL_METHOD *, SSLv3_client_method, DUMMYARG, DUMMYARG, return 0, return)
++#endif
+ DEFINEFUNC(const SSL_METHOD *, SSLv23_client_method, DUMMYARG, DUMMYARG, return 0, return)
+ DEFINEFUNC(const SSL_METHOD *, TLSv1_client_method, DUMMYARG, DUMMYARG, return 0, return)
+ #ifndef OPENSSL_NO_SSL2
+ DEFINEFUNC(const SSL_METHOD *, SSLv2_server_method, DUMMYARG, DUMMYARG, return 0, return)
+ #endif
++#ifndef OPENSSL_NO_SSL3
+ DEFINEFUNC(const SSL_METHOD *, SSLv3_server_method, DUMMYARG, DUMMYARG, return 0, return)
++#endif
+ DEFINEFUNC(const SSL_METHOD *, SSLv23_server_method, DUMMYARG, DUMMYARG, return 0, return)
+ DEFINEFUNC(const SSL_METHOD *, TLSv1_server_method, DUMMYARG, DUMMYARG, return 0, return)
+ #else
+@@ -822,13 +826,17 @@ bool q_resolveOpenSslSymbols()
+ #ifndef OPENSSL_NO_SSL2
+     RESOLVEFUNC(SSLv2_client_method)
+ #endif
++#ifndef OPENSSL_NO_SSL3
+     RESOLVEFUNC(SSLv3_client_method)
++#endif
+     RESOLVEFUNC(SSLv23_client_method)
+     RESOLVEFUNC(TLSv1_client_method)
+ #ifndef OPENSSL_NO_SSL2
+     RESOLVEFUNC(SSLv2_server_method)
+ #endif
++#ifndef OPENSSL_NO_SSL3
+     RESOLVEFUNC(SSLv3_server_method)
++#endif
+     RESOLVEFUNC(SSLv23_server_method)
+     RESOLVEFUNC(TLSv1_server_method)
+     RESOLVEFUNC(X509_NAME_entry_count)
+--- a/src/network/ssl/qsslsocket_openssl.cpp	Thu May  7 16:14:44 2015
++++ b/src/network/ssl/qsslsocket_openssl.cpp	Wed Sep 16 13:30:03 2015
+@@ -267,15 +267,19 @@ init_context:
+ #endif
+         break;
+     case QSsl::SslV3:
++#ifndef OPENSSL_NO_SSL3
+         ctx = q_SSL_CTX_new(client ? q_SSLv3_client_method() : q_SSLv3_server_method());
++#else
++        ctx = 0; // SSL 3 not supported by the system, but chosen deliberately -> error
++#endif
+         break;
+-    case QSsl::SecureProtocols: // SslV2 will be disabled below
+-    case QSsl::TlsV1SslV3: // SslV2 will be disabled below
+     case QSsl::AnyProtocol:
+-    default:
+         ctx = q_SSL_CTX_new(client ? q_SSLv23_client_method() : q_SSLv23_server_method());
+         break;
+     case QSsl::TlsV1:
++    case QSsl::SecureProtocols:
++    case QSsl::TlsV1SslV3:
++    default:
+         ctx = q_SSL_CTX_new(client ? q_TLSv1_client_method() : q_TLSv1_server_method());
+         break;
+     }