From 67bd6910efa009b8a48f7853f22bdb8d07974ff9 Mon Sep 17 00:00:00 2001 From: Stefan Strogin Date: Sat, 28 Mar 2020 07:06:40 +0200 Subject: [PATCH] mail-filter/imapfilter: add patch for LibreSSL Closes: https://bugs.gentoo.org/714882 Package-Manager: Portage-2.3.96, Repoman-2.3.22 Signed-off-by: Stefan Strogin --- .../files/imapfilter-2.6.16-libressl.patch | 29 +++++++++++++++++++ .../imapfilter/imapfilter-2.6.16.ebuild | 2 ++ 2 files changed, 31 insertions(+) create mode 100644 mail-filter/imapfilter/files/imapfilter-2.6.16-libressl.patch diff --git a/mail-filter/imapfilter/files/imapfilter-2.6.16-libressl.patch b/mail-filter/imapfilter/files/imapfilter-2.6.16-libressl.patch new file mode 100644 index 000000000000..2454fc3ffb98 --- /dev/null +++ b/mail-filter/imapfilter/files/imapfilter-2.6.16-libressl.patch @@ -0,0 +1,29 @@ +From bf69bdbf674269e84b22461c50ce1016182b56d3 Mon Sep 17 00:00:00 2001 +From: Stefan Strogin +Date: Sat, 28 Mar 2020 06:56:07 +0200 +Subject: [PATCH] Fix build with LibreSSL + +Bug: https://bugs.gentoo.org/714882 +Upstream-Status: Submitted +[https://github.com/lefcha/imapfilter/pull/204] +Signed-off-by: Stefan Strogin +--- + src/socket.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/socket.c b/src/socket.c +index 0a1874f..03e0d21 100644 +--- a/src/socket.c ++++ b/src/socket.c +@@ -143,7 +143,7 @@ open_secure_connection(session *ssn) + goto fail; + + if (get_option_boolean("certificates")) { +-#if OPENSSL_VERSION_NUMBER >= 0x10100000L ++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER) + SSL_set_hostflags(ssn->sslconn, + X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS); + if (!SSL_set1_host(ssn->sslconn, ssn->server)) { +-- +2.26.0 + diff --git a/mail-filter/imapfilter/imapfilter-2.6.16.ebuild b/mail-filter/imapfilter/imapfilter-2.6.16.ebuild index 0afa3d7ef359..2717687e7e40 100644 --- a/mail-filter/imapfilter/imapfilter-2.6.16.ebuild +++ b/mail-filter/imapfilter/imapfilter-2.6.16.ebuild @@ -24,6 +24,8 @@ DEPEND="${RDEPEND}" DOCS="AUTHORS NEWS README samples/*" +PATCHES=( "${FILESDIR}"/${P}-libressl.patch ) + src_prepare() { default sed -i -e "/^PREFIX/s:/usr/local:${EPREFIX}/usr:" \ -- 2.26.2