summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Bauman <bman@gentoo.org>2018-04-24 17:47:02 -0400
committerAaron Bauman <bman@gentoo.org>2018-04-24 17:47:26 -0400
commitf86a8d85eb397e678ade2974fb1c62c6de7dafa0 (patch)
treee000888dfa900df9c1d5a43c310bd316ad41dba1 /sys-block/open-isns
parentdev-python/markupsafe: Bump to 1.0 (diff)
downloadgentoo-f86a8d85eb397e678ade2974fb1c62c6de7dafa0.tar.gz
gentoo-f86a8d85eb397e678ade2974fb1c62c6de7dafa0.tar.bz2
gentoo-f86a8d85eb397e678ade2974fb1c62c6de7dafa0.zip
sys-block/open-isns: add LibreSSL support
This patch was slightly modified from the original reporter as the LibreSSL 2.7.x API does not need it. As such, the appropriate version checks were added for LibreSSL. Additionally, add slot/subslot operators to openssl. Closes: https://bugs.gentoo.org/645684 Package-Manager: Portage-2.3.31, Repoman-2.3.9
Diffstat (limited to 'sys-block/open-isns')
-rw-r--r--sys-block/open-isns/files/open-isns-0.98-libressl-compatibility.patch11
-rw-r--r--sys-block/open-isns/open-isns-0.98.ebuild9
2 files changed, 17 insertions, 3 deletions
diff --git a/sys-block/open-isns/files/open-isns-0.98-libressl-compatibility.patch b/sys-block/open-isns/files/open-isns-0.98-libressl-compatibility.patch
new file mode 100644
index 000000000000..b4d5ae63786d
--- /dev/null
+++ b/sys-block/open-isns/files/open-isns-0.98-libressl-compatibility.patch
@@ -0,0 +1,11 @@
+--- a/pki.c.orig
++++ b/pki.c
+@@ -30,7 +30,7 @@
+ #endif
+ /* OpenSSL 1.1 made a lot of structures opaque, so we need to
+ * define the 1.1 wrappers in previous versions. */
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2070000fL)
+ #define EVP_PKEY_base_id(o) ((o)->type)
+ #define EVP_PKEY_get0_DSA(o) ((o)->pkey.dsa)
+ static EVP_MD_CTX *EVP_MD_CTX_new(void)
diff --git a/sys-block/open-isns/open-isns-0.98.ebuild b/sys-block/open-isns/open-isns-0.98.ebuild
index 32abc8f10814..3b96e86c226d 100644
--- a/sys-block/open-isns/open-isns-0.98.ebuild
+++ b/sys-block/open-isns/open-isns-0.98.ebuild
@@ -12,14 +12,17 @@ SRC_URI="https://github.com/open-iscsi/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.g
LICENSE="LGPL-2.1"
SLOT="0"
KEYWORDS="~alpha amd64 arm ~arm64 ia64 ~mips ppc ppc64 sparc ~x86"
-IUSE="debug slp ssl static"
+IUSE="debug libressl slp ssl static"
DEPEND="
- ssl? ( dev-libs/openssl:= )
+ ssl? (
+ !libressl? ( dev-libs/openssl:0= )
+ libressl? ( dev-libs/libressl:0= )
+ )
slp? ( net-libs/openslp )"
RDEPEND="${DEPEND}"
-PATCHES=()
+PATCHES=( "${FILESDIR}/${P}-libressl-compatibility.patch" )
src_configure() {
use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI