Date: Tue, 23 Aug 2016 15:38:11 +0000 (UTC) From: Raphael Kubo da Costa <rakuco@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org Subject: svn commit: r420703 - branches/2016Q3/net/qt5-network/files Message-ID: <201608231538.u7NFcBfL037456@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rakuco Date: Tue Aug 23 15:38:11 2016 New Revision: 420703 URL: https://svnweb.freebsd.org/changeset/ports/420703 Log: MFH: r420681 Fix the build with LibreSSL. LibreSSL does not define SSL_CTRL_SET_CURVES, so check for the macro's existence before using it. I'm committing this mostly to get it into the 2016Q3 branch so it lives a bit longer: starting with Qt 5.6, upstream explicitly does not support LibreSSL and fails at configuration time if it is detected (the rationale being that they do not want to make the OpenSSL backend code even more confusing with additional checks and code paths for LibreSSL; patches adding a separate LibreSSL backend are more than welcome, but someone needs to write the code and maintain it). PORTREVISION is not being bumped because the LibreSSL build was simply broken before, and the patch does not change anything for OpenSSL users. PR: 211832 Submitted by: matthew@reztek.cz Approved by: ports-secteam (feld) Added: branches/2016Q3/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp - copied unchanged from r420681, head/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp Modified: Directory Properties: branches/2016Q3/ (props changed) Copied: branches/2016Q3/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp (from r420681, head/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/2016Q3/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp Tue Aug 23 15:38:11 2016 (r420703, copy of r420681, head/net/qt5-network/files/patch-src_network_ssl_qsslcontext__openssl.cpp) @@ -0,0 +1,29 @@ +Obtained from: https://github.com/libressl-portable/openbsd/issues/33 + +From 81494e67eccba04fc3fe554d76a9ca6fe7f2250e Mon Sep 17 00:00:00 2001 +From: hasufell <hasufell@gentoo.org> +Date: Sat, 10 Oct 2015 01:15:01 +0200 +Subject: [PATCH] Fix compilation with libressl + +By additionally checking for defined(SSL_CTRL_SET_CURVES), which +is defined in openssl, but not in libressl. +--- src/network/ssl/qsslcontext_openssl.cpp.orig 2015-10-13 04:35:28 UTC ++++ src/network/ssl/qsslcontext_openssl.cpp +@@ -338,7 +338,7 @@ init_context: + + const QVector<QSslEllipticCurve> qcurves = sslContext->sslConfiguration.ellipticCurves(); + if (!qcurves.isEmpty()) { +-#if OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(OPENSSL_NO_EC) ++#if OPENSSL_VERSION_NUMBER >= 0x10002000L && defined(SSL_CTRL_SET_CURVES) && !defined(OPENSSL_NO_EC) + // Set the curves to be used + if (q_SSLeay() >= 0x10002000L) { + // SSL_CTX_ctrl wants a non-const pointer as last argument, +@@ -352,7 +352,7 @@ init_context: + return sslContext; + } + } else +-#endif // OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(OPENSSL_NO_EC) ++#endif // OPENSSL_VERSION_NUMBER >= 0x10002000L && defined(SSL_CTRL_SET_CURVES) && !defined(OPENSSL_NO_EC) + { + // specific curves requested, but not possible to set -> error + sslContext->errorStr = msgErrorSettingEllipticCurves(QSslSocket::tr("OpenSSL version too old, need at least v1.0.2"));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608231538.u7NFcBfL037456>