public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2015-12-18  0:00 Mike Frysinger
  0 siblings, 0 replies; 11+ messages in thread
From: Mike Frysinger @ 2015-12-18  0:00 UTC (permalink / raw
  To: gentoo-commits

commit:     5eafff1506f58a1e7844b806f93dd9e93f9e271e
Author:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 17 23:55:29 2015 +0000
Commit:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Fri Dec 18 00:00:05 2015 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5eafff15

sys-block/open-iscsi: fix incorrect memset call

 .../files/open-iscsi-2.0.873-memset.patch          | 24 ++++++
 sys-block/open-iscsi/open-iscsi-2.0.873-r1.ebuild  | 95 ++++++++++++++++++++++
 2 files changed, 119 insertions(+)

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.873-memset.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.873-memset.patch
new file mode 100644
index 0000000..c566691
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.873-memset.patch
@@ -0,0 +1,24 @@
+clear the size of the storage, not the size of the pointer
+
+--- a/usr/md5.c
++++ b/usr/md5.c
+@@ -127,7 +127,7 @@ MD5Final(md5byte digest[16], struct MD5Context *ctx)
+ 
+ 	byteSwap(ctx->buf, 4);
+ 	memcpy(digest, ctx->buf, 16);
+-	memset(ctx, 0, sizeof(ctx));	/* In case it's sensitive */
++	memset(ctx, 0, sizeof(*ctx));	/* In case it's sensitive */
+ }
+ 
+ #ifndef ASM_MD5
+--- a/utils/md5.c
++++ b/utils/md5.c
+@@ -133,7 +133,7 @@ MD5Final(md5byte digest[16], struct MD5Context *ctx)
+ 
+ 	byteSwap(ctx->buf, 4);
+ 	memcpy(digest, ctx->buf, 16);
+-	memset(ctx, 0, sizeof (ctx));	/* In case it's sensitive */
++	memset(ctx, 0, sizeof (*ctx));	/* In case it's sensitive */
+ }
+ 
+ #ifndef ASM_MD5

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.873-r1.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.873-r1.ebuild
new file mode 100644
index 0000000..4392860
--- /dev/null
+++ b/sys-block/open-iscsi/open-iscsi-2.0.873-r1.ebuild
@@ -0,0 +1,95 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator linux-info eutils flag-o-matic toolchain-funcs
+
+MY_P="${PN}-$(replace_version_separator 2 "-")"
+
+DESCRIPTION="Open-iSCSI is a high performance, transport independent, multi-platform implementation of RFC3720"
+HOMEPAGE="http://www.open-iscsi.org/"
+SRC_URI="http://www.open-iscsi.org/bits/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug slp"
+
+DEPEND="slp? ( net-libs/openslp )"
+RDEPEND="${DEPEND}
+	sys-fs/lsscsi
+	sys-apps/util-linux"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+	linux-info_pkg_setup
+
+	if kernel_is -lt 2 6 16; then
+		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
+	fi
+
+	# Needs to be done, as iscsid currently only starts, when having the iSCSI
+	# support loaded as module. Kernel builtion options don't work. See this for
+	# more information:
+	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
+	# If there's a new release, check whether this is still valid!
+	CONFIG_CHECK_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
+	if linux_config_exists; then
+		for module in ${CONFIG_CHECK_MODULES}; do
+			linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+	fi
+}
+
+src_prepare() {
+	epatch "${FILESDIR}"/${P}-Makefiles.patch
+	epatch "${FILESDIR}"/${P}-memset.patch
+
+	sed -i -e 's:^\(iscsid.startup\)\s*=.*:\1 = /usr/sbin/iscsid:' etc/iscsid.conf || die
+}
+
+src_configure() {
+	cd utils/open-isns || die
+
+	# SSL (--with-security) is broken
+	econf $(use_with slp) \
+		--without-security
+}
+
+src_compile() {
+	use debug && append-flags -DDEBUG_TCP -DDEBUG_SCSI
+
+	KSRC="${KV_DIR}" CFLAGS="" \
+	emake \
+		OPTFLAGS="${CFLAGS}" \
+		AR="$(tc-getAR)" CC="$(tc-getCC)" \
+		user
+}
+
+src_install() {
+	emake DESTDIR="${ED}" sbindir="/usr/sbin" install
+
+	dodoc README THANKS
+
+	docinto test/
+	dodoc test/*
+
+	insinto /etc/iscsi
+	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
+
+	# udev pieces
+	insinto /lib/udev/rules.d
+	doins "${FILESDIR}"/99-iscsi.rules
+	exeinto /etc/udev/scripts
+	doexe "${FILESDIR}"/iscsidev.sh
+
+	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
+	newinitd "${FILESDIR}"/iscsid-init.d iscsid
+
+	keepdir /var/db/iscsi
+	fperms 700 /var/db/iscsi
+	fperms 600 /etc/iscsi/iscsid.conf
+}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2017-01-02 16:55 Matt Thode
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Thode @ 2017-01-02 16:55 UTC (permalink / raw
  To: gentoo-commits

commit:     47fd69ecdf0411ae786a83ed41e4dae74f9e4af4
Author:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
AuthorDate: Mon Jan  2 16:53:25 2017 +0000
Commit:     Matt Thode <prometheanfire <AT> gentoo <DOT> org>
CommitDate: Mon Jan  2 16:55:15 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=47fd69ec

sys-block/open-iscsi: bup to fix musl breakage

Package-Manager: portage-2.3.0

 sys-block/open-iscsi/files/musl-fixes.patch       |  64 ++++++++++++
 sys-block/open-iscsi/open-iscsi-2.0.873-r3.ebuild | 115 ++++++++++++++++++++++
 2 files changed, 179 insertions(+)

diff --git a/sys-block/open-iscsi/files/musl-fixes.patch b/sys-block/open-iscsi/files/musl-fixes.patch
new file mode 100644
index 00000000..f101eda
--- /dev/null
+++ b/sys-block/open-iscsi/files/musl-fixes.patch
@@ -0,0 +1,64 @@
+--- ./utils/open-isns/isns.h.orig
++++ ./utils/open-isns/isns.h
+@@ -13,6 +13,7 @@
+ #include <sys/socket.h>
+ #include <netinet/in.h>
+ #include <stdio.h>
++#include <time.h>
+ 
+ #include <isns-proto.h>
+ #include "types.h"
+--- ./utils/fwparam_ibft/fwparam_ppc.c.orig
++++ ./utils/fwparam_ibft/fwparam_ppc.c
+@@ -356,7 +356,7 @@
+ 	 * Sort the nics into "natural" order.	The proc fs
+ 	 * device-tree has them in somewhat random, or reversed order.
+ 	 */
+-	qsort(niclist, nic_count, sizeof(char *), (__compar_fn_t)nic_cmp);
++	qsort(niclist, nic_count, sizeof(char *), (int (*)(const void *, const void *))nic_cmp);
+ 
+ 	snprintf(prefix, sizeof(prefix), "%s/%s", devtree, "aliases");
+ 	dev_count = 0;
+--- ./usr/idbm.c.orig
++++ ./usr/idbm.c
+@@ -25,6 +25,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <errno.h>
++#include <fcntl.h>
+ #include <dirent.h>
+ #include <limits.h>
+ #include <sys/stat.h>
+--- ./usr/iscsiadm.c.orig	2012-05-21 02:59:24.000000000 +0200
++++ ./usr/iscsiadm.c	2016-07-20 22:00:54.430451701 +0200
+@@ -2403,6 +2403,7 @@ main(int argc, char **argv)
+ 	int tpgt = PORTAL_GROUP_TAG_UNKNOWN, killiscsid=-1, do_show=0;
+ 	int packet_size=32, ping_count=1, ping_interval=0;
+ 	int do_discover = 0, sub_mode = -1;
++	int argerror = 0;
+ 	struct sigaction sa_old;
+ 	struct sigaction sa_new;
+ 	struct list_head ifaces;
+@@ -2553,7 +2554,11 @@ main(int argc, char **argv)
+ 			return 0;
+ 		case 'h':
+ 			usage(0);
+-		}
++
++		case '?':
++			log_error("unrecognized character '%c'", optopt);
++			argerror = 1;
++		}	
+ 
+ 		if (name && value) {
+ 			param = idbm_alloc_user_param(name, value);
+@@ -2568,8 +2573,7 @@ main(int argc, char **argv)
+ 		}
+ 	}
+ 
+-	if (optopt) {
+-		log_error("unrecognized character '%c'", optopt);
++	if (argerror) {
+ 		rc = ISCSI_ERR_INVAL;
+ 		goto free_ifaces;
+ 	

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.873-r3.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.873-r3.ebuild
new file mode 100644
index 00000000..9581963
--- /dev/null
+++ b/sys-block/open-iscsi/open-iscsi-2.0.873-r3.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit versionator linux-info eutils flag-o-matic toolchain-funcs udev
+
+MY_P="${PN}-$(replace_version_separator 2 "-")"
+
+DESCRIPTION="Open-iSCSI is a high performance, transport independent, multi-platform implementation of RFC3720"
+HOMEPAGE="http://www.open-iscsi.org/"
+SRC_URI="http://www.open-iscsi.org/bits/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug slp +tcp infiniband rdma"
+
+DEPEND="slp? ( net-libs/openslp ) infiniband? ( sys-fabric/ofed )"
+RDEPEND="${DEPEND}
+	sys-fs/lsscsi
+	sys-apps/util-linux"
+REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+	linux-info_pkg_setup
+
+	if kernel_is -lt 2 6 16; then
+		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
+	fi
+
+	# Needs to be done, as iscsid currently only starts, when having the iSCSI
+	# support loaded as module. Kernel builtin options don't work. See this for
+	# more information:
+	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
+	# If there's a new release, check whether this is still valid!
+	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
+	RDMA_MODULES="INFINIBAND_ISER"
+	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
+	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
+	if linux_config_exists; then
+		if use tcp; then
+			for module in ${TCP_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use infiniband; then
+			for module in ${INFINIBAND_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use rdma; then
+			for module in ${RDMA_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
+			done
+		fi
+	fi
+}
+
+src_prepare() {
+	epatch "${FILESDIR}"/${P}-Makefiles.patch
+	epatch "${FILESDIR}"/${P}-memset.patch
+	epatch "${FILESDIR}"/musl-fixes.patch
+
+	epatch_user
+
+	sed -i -e 's:^\(iscsid.startup\)\s*=.*:\1 = /usr/sbin/iscsid:' etc/iscsid.conf || die
+}
+
+src_configure() {
+	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
+	append-lfs-flags
+
+	cd utils/open-isns || die
+
+	# SSL (--with-security) is broken
+	econf $(use_with slp) \
+		--without-security
+}
+
+src_compile() {
+	# Stuffing CPPFLAGS into CFLAGS isn't entirely correct, but the build
+	# is messed up already here, so it's not making it that much worse.
+	KSRC="${KV_DIR}" CFLAGS="" \
+	emake \
+		OPTFLAGS="${CFLAGS} ${CPPFLAGS}" \
+		AR="$(tc-getAR)" CC="$(tc-getCC)" \
+		user
+}
+
+src_install() {
+	emake DESTDIR="${ED}" sbindir="/usr/sbin" install
+
+	dodoc README THANKS
+
+	docinto test/
+	dodoc test/*
+
+	insinto /etc/iscsi
+	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
+
+	# udev pieces
+	udev_dorules "${FILESDIR}"/99-iscsi.rules
+	exeinto /etc/udev/scripts
+	doexe "${FILESDIR}"/iscsidev.sh
+
+	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
+	newinitd "${FILESDIR}"/iscsid-init.d iscsid
+
+	keepdir /var/db/iscsi
+	fperms 700 /var/db/iscsi
+	fperms 600 /etc/iscsi/iscsid.conf
+}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2017-01-02 18:50 Matt Thode
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Thode @ 2017-01-02 18:50 UTC (permalink / raw
  To: gentoo-commits

commit:     8ccdb781a9296e090b48e0ab1c18f802a4461c8b
Author:     Matthew Thode <prometheanfire <AT> gentoo <DOT> org>
AuthorDate: Mon Jan  2 18:48:15 2017 +0000
Commit:     Matt Thode <prometheanfire <AT> gentoo <DOT> org>
CommitDate: Mon Jan  2 18:49:51 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8ccdb781

sys-block/open-iscsi: bup

Package-Manager: portage-2.3.0

 sys-block/open-iscsi/Manifest                      |   1 +
 .../files/open-iscsi-2.0.874-Makefiles.patch       | 116 +++++++++++++++++++++
 .../files/open-iscsi-2.0.874-musl-fixes.patch      |  51 +++++++++
 sys-block/open-iscsi/open-iscsi-2.0.874.ebuild     | 106 +++++++++++++++++++
 4 files changed, 274 insertions(+)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index 10492fa..b9fdb58 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -1,2 +1,3 @@
 DIST open-iscsi-2.0-872.tar.gz 900081 SHA256 37753697a170223ac02a292b3a23a315a3c747b490c42480e4057b676c9f8d4f SHA512 d26c87772b0b1d13a8bd2eea9db86b3c61af83efbb788116c01ab6a914ff3de634a7b1bff56c1161b28965315543edbfc2735b6c7fbd3f7797471fde63b69cc0 WHIRLPOOL 4b04c8481c6c5f094ca6f7761828006a84eda7a22a6b3a4d65e7b3e4b39e73ef839ec710b491e7ca731b047fa8c74a9c03a17e85519a62dfbeb95222cfbdd935
 DIST open-iscsi-2.0-873.tar.gz 667069 SHA256 7dd9f2f97da417560349a8da44ea4fcfe98bfd5ef284240a2cc4ff8e88ac7cd9 SHA512 4e67116cb7dd49381c9279645e5a661f05596ae6be3b832772089828b3764ca2d04b5dea1bcc337071efb52c3c75a6fb943136c659ee59500f3a198ed0dcea6b WHIRLPOOL 05af106f11da9f9f02c10edd5412d0f99816349e06e192059700eb1ae24a36027c3f0d7ed423aa7bb1c0b9d8b3aa1b6aa72a2aadb00f27762edf16b7f7d08c09
+DIST open-iscsi-2.0.874.tar.gz 625039 SHA256 d0071bf00fdf6591cd6ea5caf89fa57ada03d263da1f80f17deff76acf7419e1 SHA512 66d8a52b6401229d51873f1ee0f4e7259a8ed584800403a41741c7eeedc0ec21a2b116671cb7259f60918d083ffb46d76860236a1b10fbb94a4c1d61bddae1ae WHIRLPOOL 488aea5551a299bbb15118efc52d7c228836e9cc7973a99ee4b8dfcfea4b7b14e86791e65230d25c244b6b5fe8ffaf1ae3df01f5a7b223b93c15aeb035a12852

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch
new file mode 100644
index 00000000..33c5d8a
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch
@@ -0,0 +1,116 @@
+diff -dur a/Makefile b/Makefile
+--- a/Makefile	2016-09-29 13:33:24.000000000 -0500
++++ b/Makefile	2017-01-02 11:25:04.606549073 -0600
+@@ -14,8 +14,8 @@
+ etcdir = /etc
+ initddir = $(etcdir)/init.d
+ 
+-MANPAGES = doc/iscsid.8 doc/iscsiadm.8 doc/iscsi_discovery.8 iscsiuio/docs/iscsiuio.8
+-PROGRAMS = usr/iscsid usr/iscsiadm utils/iscsi_discovery utils/iscsi-iname iscsiuio/src/unix/iscsiuio
++MANPAGES = doc/iscsid.8 doc/iscsiadm.8 doc/iscsi_discovery.8 doc/iscsistart.8 doc/iscsi-iname.8
++PROGRAMS = usr/iscsid usr/iscsiadm utils/iscsi_discovery utils/iscsi-iname usr/iscsistart
+ INSTALL = install
+ ETCFILES = etc/iscsid.conf
+ IFACEFILES = etc/iface.example
+@@ -99,11 +99,11 @@
+ # ugh, auto-detection is evil
+ # Gentoo maintains their own init.d stuff
+ install_initd:
+-	if [ -f /etc/debian_version ]; then \
++	if [ -f $(DESTDIR)$(etcdir)/debian_version ]; then \
+ 		$(MAKE) install_initd_debian ; \
+-	elif [ -f /etc/redhat-release ]; then \
++	elif [ -f $(DESTDIR)$(etcdir)/redhat-release ]; then \
+ 		$(MAKE) install_initd_redhat ; \
+-	elif [ -f /etc/SuSE-release ]; then \
++	elif [ -f $(DESTDIR)$(etcdir)/SuSE-release ]; then \
+ 		$(MAKE) install_initd_suse ; \
+ 	fi
+ 
+@@ -130,7 +130,7 @@
+ 	$(INSTALL) -m 644 $^ $(DESTDIR)$(etcdir)/iscsi/ifaces
+ 
+ install_etc: $(ETCFILES)
+-	if [ ! -f $(DESTDIR)/etc/iscsi/iscsid.conf ]; then \
++	if [ ! -f $(DESTDIR)$(etcdir)/iscsi/iscsid.conf ]; then \
+ 		$(INSTALL) -d $(DESTDIR)$(etcdir)/iscsi ; \
+ 		$(INSTALL) -m 644 $^ $(DESTDIR)$(etcdir)/iscsi ; \
+ 	fi
+@@ -143,11 +143,11 @@
+ 	$(MAKE) -C kernel install_kernel
+ 
+ install_iname:
+-	if [ ! -f $(DESTDIR)/etc/iscsi/initiatorname.iscsi ]; then \
+-		echo "InitiatorName=`$(DESTDIR)/sbin/iscsi-iname`" > $(DESTDIR)/etc/iscsi/initiatorname.iscsi ; \
++	if [ ! -f $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi ]; then \
++		echo "InitiatorName=`$(DESTDIR)$(sbindir)/iscsi-iname`" > $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi ; \
+ 		echo "***************************************************" ; \
+-		echo "Setting InitiatorName to `cat $(DESTDIR)/etc/iscsi/initiatorname.iscsi`" ; \
+-		echo "To override edit $(DESTDIR)/etc/iscsi/initiatorname.iscsi" ; \
++		echo "Setting InitiatorName to `cat $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi`" ; \
++		echo "To override edit $(etcdir)/iscsi/initiatorname.iscsi" ; \
+ 		echo "***************************************************" ; \
+ 	fi
+ 
+diff -dur a/usr/Makefile b/usr/Makefile
+--- a/usr/Makefile	2016-09-29 13:33:24.000000000 -0500
++++ b/usr/Makefile	2017-01-02 11:27:55.417297639 -0600
+@@ -63,9 +63,9 @@
+ 		iscsistart.o statics.o
+ 	$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ -lrt
+ clean:
+-	rm -f *.o $(PROGRAMS) .depend $(LIBSYS)
++	$(RM) *.o $(PROGRAMS) .depend $(LIBSYS)
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+diff -dur a/utils/fwparam_ibft/Makefile b/utils/fwparam_ibft/Makefile
+--- a/utils/fwparam_ibft/Makefile	2016-09-29 13:33:24.000000000 -0500
++++ b/utils/fwparam_ibft/Makefile	2017-01-02 11:30:42.358440507 -0600
+@@ -33,11 +33,11 @@
+ all: $(OBJS)
+ 
+ clean:
+-	rm -f *.o $(CLEANFILES) .depend
++	$(RM) *.o $(CLEANFILES) .depend
+ 
+ $(OBJS): prom_parse.tab.h prom_parse.h fwparam_ibft.h
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+diff -dur a/utils/Makefile b/utils/Makefile
+--- a/utils/Makefile	2016-09-29 13:33:24.000000000 -0500
++++ b/utils/Makefile	2017-01-02 11:29:24.193611039 -0600
+@@ -10,9 +10,9 @@
+ 	$(CC) $(CFLAGS) $(LDFLAGS) $^ $(DBM_LIB) -o $@
+ 
+ clean:
+-	rm -f *.o $(PROGRAMS) .depend
++	$(RM) *.o $(PROGRAMS) .depend
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(GCC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+diff -dur a/utils/sysdeps/Makefile b/utils/sysdeps/Makefile
+--- a/utils/sysdeps/Makefile	2016-09-29 13:33:24.000000000 -0500
++++ b/utils/sysdeps/Makefile	2017-01-02 11:31:24.219926338 -0600
+@@ -8,9 +8,9 @@
+ all: $(SYSDEPS_OBJS)
+ 
+ clean:
+-	rm -f *.o .depend
++	$(RM) *.o .depend
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch
new file mode 100644
index 00000000..cf8b762
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch
@@ -0,0 +1,51 @@
+--- ./utils/fwparam_ibft/fwparam_ppc.c	2016-09-29 13:33:24.000000000 -0500
++++ ./utils/fwparam_ibft/fwparam_ppc.c	2017-01-02 11:37:32.738351217 -0600
+@@ -356,7 +356,7 @@
+ 	 * Sort the nics into "natural" order.	The proc fs
+ 	 * device-tree has them in somewhat random, or reversed order.
+ 	 */
+-	qsort(niclist, nic_count, sizeof(char *), (__compar_fn_t)nic_cmp);
++	qsort(niclist, nic_count, sizeof(char *), (int (*)(const void *, const void *))nic_cmp);
+ 
+ 	snprintf(prefix, sizeof(prefix), "%s/%s", devtree, "aliases");
+ 	dev_count = 0;
+--- ./usr/idbm.c.orig
++++ ./usr/idbm.c
+@@ -25,6 +25,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <errno.h>
++#include <fcntl.h>
+ #include <dirent.h>
+ #include <limits.h>
+ #include <sys/stat.h>
+--- a/usr/iscsiadm.c	2016-09-29 13:33:24.000000000 -0500
++++ b/usr/iscsiadm.c	2017-01-02 11:46:37.643506953 -0600
+@@ -3262,6 +3262,7 @@
+ 	int tpgt = PORTAL_GROUP_TAG_UNKNOWN, killiscsid=-1, do_show=0;
+ 	int packet_size=32, ping_count=1, ping_interval=0;
+ 	int do_discover = 0, sub_mode = -1;
++	int argerror = 0;
+ 	int portal_type = -1;
+ 	struct sigaction sa_old;
+ 	struct sigaction sa_new;
+@@ -3426,6 +3427,9 @@
+ 			break;
+ 		case 'h':
+ 			usage(0);
++		case '?':
++			log_error("unrecognized character '%c'", optopt);
++			argerror = 1;
+ 		}
+ 
+ 		if (name && value) {
+@@ -3441,8 +3445,7 @@
+ 		}
+ 	}
+ 
+-	if (optopt) {
+-		log_error("unrecognized character '%c'", optopt);
++	if (argerror) {
+ 		rc = ISCSI_ERR_INVAL;
+ 		goto free_ifaces;
+ 	}

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.874.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.874.ebuild
new file mode 100644
index 00000000..61e16f0
--- /dev/null
+++ b/sys-block/open-iscsi/open-iscsi-2.0.874.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit versionator linux-info eutils flag-o-matic toolchain-funcs udev
+
+DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
+HOMEPAGE="http://www.open-iscsi.org/"
+SRC_URI="http://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug infiniband slp +tcp rdma"
+
+DEPEND="sys-block/open-isns:=
+	slp? ( net-libs/openslp )
+	infiniband? ( sys-fabric/ofed )"
+RDEPEND="${DEPEND}
+	sys-fs/lsscsi
+	sys-apps/util-linux"
+REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
+
+pkg_setup() {
+	linux-info_pkg_setup
+
+	if kernel_is -lt 2 6 16; then
+		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
+	fi
+
+	# Needs to be done, as iscsid currently only starts, when having the iSCSI
+	# support loaded as module. Kernel builtin options don't work. See this for
+	# more information:
+	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
+	# If there's a new release, check whether this is still valid!
+	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
+	RDMA_MODULES="INFINIBAND_ISER"
+	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
+	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
+	if linux_config_exists; then
+		if use tcp; then
+			for module in ${TCP_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use infiniband; then
+			for module in ${INFINIBAND_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use rdma; then
+			for module in ${RDMA_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
+			done
+		fi
+	fi
+}
+
+src_prepare() {
+	epatch "${FILESDIR}"/${P}-Makefiles.patch
+	epatch "${FILESDIR}"/${P}-musl-fixes.patch
+	eapply_user
+
+	sed -i -e 's:^\(iscsid.startup\)\s*=.*:\1 = /usr/sbin/iscsid:' etc/iscsid.conf || die
+}
+
+src_configure() {
+	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
+	append-lfs-flags
+}
+
+src_compile() {
+	# Stuffing CPPFLAGS into CFLAGS isn't entirely correct, but the build
+	# is messed up already here, so it's not making it that much worse.
+	KSRC="${KV_DIR}" CFLAGS="" \
+	emake \
+		OPTFLAGS="${CFLAGS} ${CPPFLAGS}" \
+		AR="$(tc-getAR)" CC="$(tc-getCC)" \
+		user
+}
+
+src_install() {
+	emake DESTDIR="${ED}" sbindir="/usr/sbin" install
+
+	dodoc README THANKS
+
+	docinto test/
+	dodoc test/*
+
+	insinto /etc/iscsi
+	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
+
+	# udev pieces
+	udev_dorules "${FILESDIR}"/99-iscsi.rules
+	exeinto /etc/udev/scripts
+	doexe "${FILESDIR}"/iscsidev.sh
+
+	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
+	newinitd "${FILESDIR}"/iscsid-init.d iscsid
+
+	keepdir /var/db/iscsi
+	fperms 700 /var/db/iscsi
+	fperms 600 /etc/iscsi/iscsid.conf
+}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2019-05-06 12:54 Lars Wendler
  0 siblings, 0 replies; 11+ messages in thread
From: Lars Wendler @ 2019-05-06 12:54 UTC (permalink / raw
  To: gentoo-commits

commit:     949d34bf3917ec5a5f27dc8fb297c5a8a95ce1c0
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon May  6 12:50:48 2019 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon May  6 12:54:34 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=949d34bf

sys-block/open-iscsi: Revbump to fix a space issue

Bug: https://bugs.gentoo.org/685190
Package-Manager: Portage-2.3.66, Repoman-2.3.12
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 .../open-iscsi-2.0.876-space_in_node-mode.patch    | 28 ++++++++++++++++++++++
 ...uild => open-iscsi-2.0.876_p20180814-r1.ebuild} |  3 ++-
 2 files changed, 30 insertions(+), 1 deletion(-)

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.876-space_in_node-mode.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.876-space_in_node-mode.patch
new file mode 100644
index 00000000000..1b72eec7945
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.876-space_in_node-mode.patch
@@ -0,0 +1,28 @@
+From baa0cb45cfcf10a81283c191b0b236cd1a2f66ee Mon Sep 17 00:00:00 2001
+From: Lee Duncan <lduncan@suse.com>
+Date: Fri, 12 Oct 2018 09:57:20 -0700
+Subject: [PATCH] Restore space in node-mode level 0 output
+
+As part of the libopeniscsiusr update, the output
+of "iscsiadm -m node" dropped a space that needs to
+be between the portal and the target, for proper
+parsing.
+
+Fixes: 87ea50a1c3a97
+---
+ usr/iscsiadm.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/usr/iscsiadm.c b/usr/iscsiadm.c
+index e3ba03c8..25c6cdc0 100644
+--- a/usr/iscsiadm.c
++++ b/usr/iscsiadm.c
+@@ -683,7 +683,7 @@ static int login_portals(struct node_rec *pattern_rec)
+ 
+ static void print_node_flat(struct iscsi_node *node)
+ {
+-		printf("%s,%" PRIu16 "%s\n",
++		printf("%s,%" PRIu16 " %s\n",
+ 		       iscsi_node_portal_get(node),
+ 		       iscsi_node_tpgt_get(node),
+ 		       iscsi_node_target_name_get(node));

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.876_p20180814.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.876_p20180814-r1.ebuild
similarity index 97%
rename from sys-block/open-iscsi/open-iscsi-2.0.876_p20180814.ebuild
rename to sys-block/open-iscsi/open-iscsi-2.0.876_p20180814-r1.ebuild
index b111b48a68e..8d18bfc1ed4 100644
--- a/sys-block/open-iscsi/open-iscsi-2.0.876_p20180814.ebuild
+++ b/sys-block/open-iscsi/open-iscsi-2.0.876_p20180814-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI="6"
@@ -27,6 +27,7 @@ REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
 PATCHES=(
 	"${FILESDIR}/${PN}-2.0.876_p20180814-musl-fixes.patch"
 	"${FILESDIR}/${PN}-2.0.876-Makefiles.patch"
+	"${FILESDIR}/${PN}-2.0.876-space_in_node-mode.patch" #685190
 )
 
 S="${WORKDIR}/${PN}-${MY_COMMIT}"


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2019-05-23  8:09 Lars Wendler
  0 siblings, 0 replies; 11+ messages in thread
From: Lars Wendler @ 2019-05-23  8:09 UTC (permalink / raw
  To: gentoo-commits

commit:     cadef88193083edce8315d0cfd4b8c5e27e4dbc1
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Thu May 23 08:09:44 2019 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Thu May 23 08:09:44 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cadef881

sys-block/open-iscsi: Bump to version 2.0.877

Closes: https://bugs.gentoo.org/685190
Package-Manager: Portage-2.3.66, Repoman-2.3.12
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 sys-block/open-iscsi/Manifest                      |   1 +
 .../open-iscsi-2.0.877-optional_systemd.patch      |  87 ++++++++++++++
 .../files/open-iscsi-2.0.877-pkgconfig.patch       |  84 ++++++++++++++
 sys-block/open-iscsi/open-iscsi-2.0.877.ebuild     | 127 +++++++++++++++++++++
 4 files changed, 299 insertions(+)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index a76fa9eec9d..15a53b3abe4 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -2,3 +2,4 @@ DIST open-iscsi-2.0-873.tar.gz 667069 BLAKE2B edb427f8483c31499cdde644bbf8d65895
 DIST open-iscsi-2.0.875.tar.gz 635121 BLAKE2B 34a7083087c53ed0e59d293d26efe166b09c5ea18b6022869cc9ff3d2edb2fb8b69e2c1ce6c9011bd20fc590b02dafd6d7c13d8bfa1eae6408c4bace13992e5e SHA512 1709011d7d12d3dd9278a0d775af064d5f7da37357f35d6d5c5b3aa8ec16385c28b201b1261f4581dbbbbca3d815015ed8696e1694aa19f3231132f90d1e5b36
 DIST open-iscsi-2.0.876.tar.gz 576111 BLAKE2B 2fbe4f37e91730d15bad77feeb9a418a8bbf709582598571a5905080eb60649f3ece6a52e9cf94a28128f2b0bc30093e67f6a47624545243b10bcebe318750ac SHA512 f9319016bd6abf3bf675ad050b0489095a21db58c93f9baaca6adc239129ad08f8e18ed96c91c36406e5c42d35118e67dfde6d3c37e97027467c4472db3b2422
 DIST open-iscsi-2.0.876_p20180814.tar.gz 602779 BLAKE2B 8403d69ef43c868a009e1b7bf6e67ea0ecc0d10113b842e1f853a759398f56bb447f6c6ce5474bb2f4e9dfe59d9effc5eea58a1e7da9bbfd81c370eba1759edc SHA512 d79b3025888a8b6db944c86abb13940a6c75fe10166d79ab7e242fc108603e86a81c2ea3448318a45f0e51d89d45a21bda5ab43cf75ff759007e1949030ad0bf
+DIST open-iscsi-2.0.877.tar.gz 605075 BLAKE2B 85106a7137b2a70a56418e2c76df81d5bf464268b5030fef2560addd8a96a0b6ba767c811f7c8a181a7b30a902d3973f0f7dad7cd3cc0796979a8a1b2f9164ef SHA512 1e6a6772c59dd7a809938f1ef4c9fe0310d70bf0e0f7e80643bcfa22236af8a8027122cf9ff598ce70a3ff51ccb9d5ef99fc5b9c517379bf590b8da74bfeb9a6

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.877-optional_systemd.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.877-optional_systemd.patch
new file mode 100644
index 00000000000..b1f1a8f1d07
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.877-optional_systemd.patch
@@ -0,0 +1,87 @@
+From f66608aa9ce989c91f744bb2f3f34d2e01aedc87 Mon Sep 17 00:00:00 2001
+From: Lee Duncan <lduncan@suse.com>
+Date: Tue, 14 May 2019 13:11:34 -0700
+Subject: [PATCH] Make iscsid systemd usage optional
+
+You can compile without system now by using something
+like:
+
+	make OPTFLAGS="-DNO_SYSTEMD ..." NO_SYSTEMD=1
+
+This will skip systemd code for iscsid and iscsiuio.
+---
+ Makefile     | 5 +++++
+ usr/Makefile | 2 ++
+ usr/iscsid.c | 6 ++++++
+ 3 files changed, 13 insertions(+)
+
+diff --git a/Makefile b/Makefile
+index c941740c..9a337741 100644
+--- a/Makefile
++++ b/Makefile
+@@ -40,6 +40,11 @@ ifneq (,$(CFLAGS))
+ export CFLAGS
+ endif
+ 
++# export systemd disablement if set
++ifneq ($(NO_SYSTEMD),)
++export NO_SYSTEMD
++endif
++
+ # Random comments:
+ # using '$(MAKE)' instead of just 'make' allows make to run in parallel
+ # over multiple makefile.
+diff --git a/usr/Makefile b/usr/Makefile
+index f1c35aa7..0203127c 100644
+--- a/usr/Makefile
++++ b/usr/Makefile
+@@ -41,7 +41,9 @@ CFLAGS += $(WARNFLAGS) -I../include -I. -D_GNU_SOURCE \
+ CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
+ ISCSI_LIB = -L$(TOPDIR)/libopeniscsiusr -lopeniscsiusr
+ LDFLAGS += $(shell $(PKG_CONFIG) --libs libkmod)
++ifeq ($(NO_SYSTEMD),)
+ LDFLAGS += $(shell $(PKG_CONFIG) --libs libsystemd)
++endif
+ PROGRAMS = iscsid iscsiadm iscsistart
+ 
+ # libc compat files
+diff --git a/usr/iscsid.c b/usr/iscsid.c
+index 0c984409..37c13b39 100644
+--- a/usr/iscsid.c
++++ b/usr/iscsid.c
+@@ -34,7 +34,9 @@
+ #include <sys/wait.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#ifndef	NO_SYSTEMD
+ #include <systemd/sd-daemon.h>
++#endif
+ 
+ #include "iscsid.h"
+ #include "mgmt_ipc.h"
+@@ -339,6 +341,7 @@ static void missing_iname_warn(char *initiatorname_file)
+ /* called right before we enter the event loop */
+ static void set_state_to_ready(void)
+ {
++#ifndef	NO_SYSTEMD
+ 	if (sessions_to_recover)
+ 		sd_notify(0, "READY=1\n"
+ 				"RELOADING=1\n"
+@@ -346,14 +349,17 @@ static void set_state_to_ready(void)
+ 	else
+ 		sd_notify(0, "READY=1\n"
+ 				"STATUS=Ready to process requests\n");
++#endif
+ }
+ 
+ /* called when recovery process has been reaped */
+ static void set_state_done_reloading(void)
+ {
++#ifndef	NO_SYSTEMD
+ 	sessions_to_recover = 0;
+ 	sd_notifyf(0, "READY=1\n"
+ 			"STATUS=Ready to process requests\n");
++#endif
+ }
+ 
+ int main(int argc, char *argv[])

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.877-pkgconfig.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.877-pkgconfig.patch
new file mode 100644
index 00000000000..1756196e6b3
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.0.877-pkgconfig.patch
@@ -0,0 +1,84 @@
+From 623a81123c494f5c69dc6616bd72e838862e2f1f Mon Sep 17 00:00:00 2001
+From: Lee Duncan <lduncan@suse.com>
+Date: Mon, 12 Nov 2018 13:10:04 -0800
+Subject: [PATCH] Use pkg-config in Makefiles for newer libraries.
+
+These two recently-added libraries can be in different
+locations on different distros, so use pkg-config to
+added the appropriate actions in the make files.
+---
+ libopeniscsiusr/Makefile |  8 +++++++-
+ usr/Makefile             | 11 ++++++++---
+ 2 files changed, 15 insertions(+), 4 deletions(-)
+
+diff --git a/libopeniscsiusr/Makefile b/libopeniscsiusr/Makefile
+index bf7c96c7..a045a459 100644
+--- a/libopeniscsiusr/Makefile
++++ b/libopeniscsiusr/Makefile
+@@ -23,6 +23,8 @@ endif
+ INCLUDE_DIR ?= $(prefix)/include
+ PKGCONF_DIR ?= $(LIB_DIR)/pkgconfig
+ 
++PKG_CONFIG = /usr/bin/pkg-config
++
+ LIBISCSI_USR_DIR=$(TOPDIR)/libopeniscsiusr
+ 
+ LIBISCSI_USR_VERSION_MAJOR=0
+@@ -43,13 +45,17 @@ OBJS = context.o misc.o session.o sysfs.o iface.o idbm.o node.o default.o
+ 
+ CFLAGS ?= -O2 -g
+ CFLAGS += -Wall -Werror -Wextra -fvisibility=hidden -fPIC
++CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
++
++LDFLAGS += $(shell $(PKG_CONFIG) --libs libkmod)
+ 
+ LIBADD =
+ 
+ all: $(LIBS) $(LIBS_MAJOR) $(TESTS) doc
+ 
+ $(LIBS): $(OBJS)
+-	$(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname=$@ -o $@ $(OBJS) $(LIBADD)
++	@echo CFLAGS= $(CFLAGS)
++	$(CC) $(CFLAGS) -shared -Wl,-soname=$@ -o $@ $(OBJS) $(LDFLAGS) $(LIBADD)
+ 	ln -sf $@ $(DEVLIB)
+ 
+ $(LIBS_MAJOR): $(LIBS)
+diff --git a/usr/Makefile b/usr/Makefile
+index f9445ada..f1c35aa7 100644
+--- a/usr/Makefile
++++ b/usr/Makefile
+@@ -32,11 +32,16 @@ IPC_OBJ=ioctl.o
+ endif
+ endif
+ 
++PKG_CONFIG = /usr/bin/pkg-config
++
+ CFLAGS ?= -O2 -g
+ WARNFLAGS ?= -Wall -Wstrict-prototypes
+ CFLAGS += $(WARNFLAGS) -I../include -I. -D_GNU_SOURCE \
+ 	  -I$(TOPDIR)/libopeniscsiusr
++CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
+ ISCSI_LIB = -L$(TOPDIR)/libopeniscsiusr -lopeniscsiusr
++LDFLAGS += $(shell $(PKG_CONFIG) --libs libkmod)
++LDFLAGS += $(shell $(PKG_CONFIG) --libs libsystemd)
+ PROGRAMS = iscsid iscsiadm iscsistart
+ 
+ # libc compat files
+@@ -60,14 +65,14 @@ all: $(PROGRAMS)
+ 
+ iscsid: $(ISCSI_LIB_SRCS) $(INITIATOR_SRCS) $(DISCOVERY_SRCS) \
+ 	iscsid.o session_mgmt.o discoveryd.o mntcheck.o
+-	$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@  -lisns -lcrypto -lrt -lmount $(ISCSI_LIB)
++	$(CC) $(CFLAGS) $^ -o $@  -lisns -lcrypto -lrt -lmount $(LDFLAGS) $(ISCSI_LIB)
+ 
+ iscsiadm: $(ISCSI_LIB_SRCS) $(DISCOVERY_SRCS) iscsiadm.o session_mgmt.o mntcheck.o
+-	$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ -lisns -lcrypto -lmount $(ISCSI_LIB)
++	$(CC) $(CFLAGS) $^ -o $@ -lisns -lcrypto -lmount $(LDFLAGS) $(ISCSI_LIB)
+ 
+ iscsistart: $(ISCSI_LIB_SRCS) $(INITIATOR_SRCS) $(FW_BOOT_SRCS) \
+ 		iscsistart.o statics.o
+-	$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ -lrt $(ISCSI_LIB)
++	$(CC) $(CFLAGS) $^ -o $@ -lrt $(LDFLAGS) $(ISCSI_LIB)
+ clean:
+ 	rm -f *.o $(PROGRAMS) .depend $(LIBSYS)
+ 

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.877.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.877.ebuild
new file mode 100644
index 00000000000..97f3cbc9886
--- /dev/null
+++ b/sys-block/open-iscsi/open-iscsi-2.0.877.ebuild
@@ -0,0 +1,127 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools linux-info flag-o-matic toolchain-funcs udev systemd
+
+DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
+HOMEPAGE="http://www.open-iscsi.com/"
+SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0/0.2"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug infiniband +tcp rdma systemd"
+
+DEPEND="sys-block/open-isns:=
+	sys-kernel/linux-headers
+	infiniband? ( sys-fabric/ofed )
+	systemd? ( sys-apps/systemd )
+"
+RDEPEND="${DEPEND}
+	sys-fs/lsscsi
+	sys-apps/util-linux"
+BDEPEND="virtual/pkgconfig"
+
+REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-2.0.876-Makefiles.patch"
+	"${FILESDIR}/${PN}-2.0.877-pkgconfig.patch"
+	"${FILESDIR}/${PN}-2.0.877-optional_systemd.patch"
+)
+
+pkg_setup() {
+	linux-info_pkg_setup
+
+	if kernel_is -lt 2 6 16; then
+		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
+	fi
+
+	# Needs to be done, as iscsid currently only starts, when having the iSCSI
+	# support loaded as module. Kernel builtin options don't work. See this for
+	# more information:
+	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
+	# If there's a new release, check whether this is still valid!
+	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
+	RDMA_MODULES="INFINIBAND_ISER"
+	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
+	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
+	if linux_config_exists; then
+		if use tcp; then
+			for module in ${TCP_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use infiniband; then
+			for module in ${INFINIBAND_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
+		done
+		fi
+		if use rdma; then
+			for module in ${RDMA_MODULES}; do
+				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
+			done
+		fi
+	fi
+}
+
+src_prepare() {
+	sed -i -e 's:^\(iscsid.startup\)\s*=.*:\1 = /usr/sbin/iscsid:' etc/iscsid.conf || die
+	default
+
+	pushd iscsiuio >/dev/null || die
+	eautoreconf
+	popd >/dev/null || die
+}
+
+src_configure() {
+	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
+	append-lfs-flags
+}
+
+src_compile() {
+	# Stuffing CPPFLAGS into CFLAGS isn't entirely correct, but the build
+	# is messed up already here, so it's not making it that much worse.
+	KSRC="${KV_DIR}" CFLAGS="" \
+	emake \
+		OPTFLAGS="${CFLAGS} ${CPPFLAGS} $(usex systemd '' -DNO_SYSTEMD)" \
+		AR="$(tc-getAR)" CC="$(tc-getCC)" \
+		$(usex systemd '' NO_SYSTEMD=1) \
+		user
+}
+
+src_install() {
+	emake DESTDIR="${ED}" sbindir="/usr/sbin" install
+	# Upstream make is not deterministic, per bug #601514
+	rm -f "${ED}"/etc/initiatorname.iscsi
+
+	dodoc README THANKS
+
+	docinto test/
+	dodoc test/*
+
+	insinto /etc/iscsi
+	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
+
+	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
+	newinitd "${FILESDIR}"/iscsid-init.d iscsid
+
+	systemd_dounit "${S}"/etc/systemd/iscsid.service
+
+	keepdir /var/db/iscsi
+	fperms 700 /var/db/iscsi
+	fperms 600 /etc/iscsi/iscsid.conf
+}
+
+pkg_postinst() {
+	in='/etc/iscsi/initiatorname.iscsi'
+	if [ ! -f "${EROOT}${in}" -a -f "${EROOT}${in}.example" ]; then
+		{
+		  cat "${EROOT}${in}.example"
+		  echo "# InitiatorName generated by ${CATEGORY}/${PF} at $(date -uR)"
+		  echo "InitiatorName=$(${ROOT}/usr/sbin/iscsi-iname)"
+		} >> "${EROOT}${in}.tmp" && mv -f "${EROOT}${in}.tmp" "${EROOT}${in}"
+	fi
+}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2020-05-03 20:35 Thomas Deutschmann
  0 siblings, 0 replies; 11+ messages in thread
From: Thomas Deutschmann @ 2020-05-03 20:35 UTC (permalink / raw
  To: gentoo-commits

commit:     2b34abb755bf4dd2500e6a59d09a58ddee12842f
Author:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Sun May  3 20:35:36 2020 +0000
Commit:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Sun May  3 20:35:49 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2b34abb7

sys-block/open-iscsi: drop -Werror

Package-Manager: Portage-2.3.99, Repoman-2.3.22
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>

 .../files/open-iscsi-2.1.1-Makefiles.patch         | 78 ++++++++++++++++++++++
 sys-block/open-iscsi/open-iscsi-2.1.1.ebuild       |  2 +-
 2 files changed, 79 insertions(+), 1 deletion(-)

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.1-Makefiles.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.1-Makefiles.patch
new file mode 100644
index 00000000000..02e651e27c2
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.1.1-Makefiles.patch
@@ -0,0 +1,78 @@
+--- a/libopeniscsiusr/Makefile
++++ b/libopeniscsiusr/Makefile
+@@ -44,7 +44,7 @@ EXTRA_MAN_FILES = libopeniscsiusr.h.3
+ OBJS = context.o misc.o session.o sysfs.o iface.o idbm.o node.o default.o
+ 
+ CFLAGS ?= -O2 -g
+-CFLAGS += -Wall -Werror -Wextra -fvisibility=hidden -fPIC
++CFLAGS += -Wall -Wextra -fvisibility=hidden -fPIC
+ CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
+ 
+ LDFLAGS += $(shell $(PKG_CONFIG) --libs libkmod)
+--- a/usr/Makefile
++++ b/usr/Makefile
+@@ -35,7 +35,7 @@ endif
+ PKG_CONFIG = /usr/bin/pkg-config
+ 
+ CFLAGS ?= -O2 -g
+-WARNFLAGS ?= -Wall -Wextra -Werror -Wstrict-prototypes -fno-common
++WARNFLAGS ?= -Wall -Wextra -Wstrict-prototypes -fno-common
+ CFLAGS += $(WARNFLAGS) -I../include -I. -D_GNU_SOURCE \
+ 	  -I$(TOPDIR)/libopeniscsiusr
+ CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
+@@ -76,9 +76,9 @@ iscsistart: $(ISCSI_LIB_SRCS) $(INITIATOR_SRCS) $(FW_BOOT_SRCS) \
+ 		iscsistart.o statics.o
+ 	$(CC) $(CFLAGS) $^ -o $@ -lcrypto -lrt $(LDFLAGS) $(ISCSI_LIB)
+ clean:
+-	rm -f *.o $(PROGRAMS) .depend $(LIBSYS)
++	$(RM) *.o $(PROGRAMS) .depend $(LIBSYS)
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+--- a/utils/Makefile
++++ b/utils/Makefile
+@@ -10,9 +10,9 @@ iscsi-iname: md5.o iscsi-iname.o
+ 	$(CC) $(CFLAGS) $(LDFLAGS) $^ $(DBM_LIB) -o $@
+ 
+ clean:
+-	rm -f *.o $(PROGRAMS) .depend
++	$(RM) *.o $(PROGRAMS) .depend
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+--- a/utils/fwparam_ibft/Makefile
++++ b/utils/fwparam_ibft/Makefile
+@@ -41,11 +41,11 @@ LDFLAGS += -L$(TOPDIR)/libopeniscsiusr -liscsiusr
+ all: $(OBJS)
+ 
+ clean:
+-	rm -f *.o $(CLEANFILES) .depend
++	$(RM) *.o $(CLEANFILES) .depend
+ 
+ $(OBJS): prom_parse.tab.h prom_parse.h fwparam_ibft.h
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend
+--- a/utils/sysdeps/Makefile
++++ b/utils/sysdeps/Makefile
+@@ -8,9 +8,9 @@ SYSDEPS_OBJS=sysdeps.o
+ all: $(SYSDEPS_OBJS)
+ 
+ clean:
+-	rm -f *.o .depend
++	$(RM) *.o .depend
+ 
+ depend:
+-	gcc $(CFLAGS) -M `ls *.c` > .depend
++	$(CC) $(CFLAGS) -M `ls *.c` > .depend
+ 
+ -include .depend

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.1.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.1.ebuild
index 43f3ee2b89f..d7ff6b52509 100644
--- a/sys-block/open-iscsi/open-iscsi-2.1.1.ebuild
+++ b/sys-block/open-iscsi/open-iscsi-2.1.1.ebuild
@@ -31,7 +31,7 @@ BDEPEND="virtual/pkgconfig"
 REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
 
 PATCHES=(
-	"${FILESDIR}/${PN}-2.0.876-Makefiles.patch"
+	"${FILESDIR}/${PN}-2.1.1-Makefiles.patch"
 )
 
 pkg_setup() {


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2021-05-23 12:14 David Seifert
  0 siblings, 0 replies; 11+ messages in thread
From: David Seifert @ 2021-05-23 12:14 UTC (permalink / raw
  To: gentoo-commits

commit:     e46fda46397b6ba1a2cc60ee000f626355d913bd
Author:     David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Sun May 23 12:14:08 2021 +0000
Commit:     David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Sun May 23 12:14:08 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e46fda46

sys-block/open-iscsi: drop 2.0.875

Signed-off-by: David Seifert <soap <AT> gentoo.org>

 sys-block/open-iscsi/Manifest                      |   1 -
 sys-block/open-iscsi/files/99-iscsi.rules          |   1 -
 sys-block/open-iscsi/files/iscsidev.sh             |  78 -------------
 .../files/open-iscsi-2.0.874-Makefiles.patch       | 116 -------------------
 .../open-iscsi-2.0.874-musl-ethtool-compat.patch   |  69 -----------
 .../files/open-iscsi-2.0.874-musl-fixes.patch      |  51 ---------
 .../open-iscsi-2.0.875-include-sysmacros.patch     |  21 ----
 sys-block/open-iscsi/open-iscsi-2.0.875.ebuild     | 127 ---------------------
 8 files changed, 464 deletions(-)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index 9d4de0cdd17..b7cd9738e2e 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -1,3 +1,2 @@
-DIST open-iscsi-2.0.875.tar.gz 635121 BLAKE2B 34a7083087c53ed0e59d293d26efe166b09c5ea18b6022869cc9ff3d2edb2fb8b69e2c1ce6c9011bd20fc590b02dafd6d7c13d8bfa1eae6408c4bace13992e5e SHA512 1709011d7d12d3dd9278a0d775af064d5f7da37357f35d6d5c5b3aa8ec16385c28b201b1261f4581dbbbbca3d815015ed8696e1694aa19f3231132f90d1e5b36
 DIST open-iscsi-2.1.3.tar.gz 619746 BLAKE2B 884e24ae6e16578f3cbd8ccea2557e820d4bf4d20c7f88890100ca93f48df88dc7284cc4eca19d93187516fd21a2c5b71eb53f0d8fe395d2ce42fd202dc355d6 SHA512 0de417dc45b765458c5a1f09029b5df9b5c18d45d7a8fb6b38d539b7013f512a3c8731d5046f554611eccc77b93fea0df30fe4932d79cea44776ac944c398a52
 DIST open-iscsi-2.1.4.tar.gz 621247 BLAKE2B 043a999b2f397a6c740d61654079d7ab966caee6cf6cfb244ddd70eae4f5201045b371ce5fbe244216a2a210a5379c92e8c3fbe62d33707cf05e7a4a20a13a91 SHA512 ae0663a964d86e6a4c19203598b859173c93ecce550f9bc9855ff735dd51a3c45822f2bc1cc99e6891c56ef1d16c42223803f07a961558fe6e38ead2164faef3

diff --git a/sys-block/open-iscsi/files/99-iscsi.rules b/sys-block/open-iscsi/files/99-iscsi.rules
deleted file mode 100644
index 3816126264c..00000000000
--- a/sys-block/open-iscsi/files/99-iscsi.rules
+++ /dev/null
@@ -1 +0,0 @@
-KERNEL=="sd*", SUBSYSTEMS=="block", RUN{program}+="/etc/udev/scripts/iscsidev.sh"

diff --git a/sys-block/open-iscsi/files/iscsidev.sh b/sys-block/open-iscsi/files/iscsidev.sh
deleted file mode 100644
index d045fae570f..00000000000
--- a/sys-block/open-iscsi/files/iscsidev.sh
+++ /dev/null
@@ -1,78 +0,0 @@
-#!/usr/bin/env bash
-
-# KERNEL=="sd*", SUBSYSTEMS=="block", RUN{program}="/etc/udev/scripts/iscsidev.sh"
-
-# we only care about iscsi devices
-[[ $ID_VENDOR = "IET" ]] || exit 1
-
-# don't care about partitions either
-echo $DEVNAME | egrep -q "[0-9]$"
-status=$?
-[[ $status != 0 ]] || exit 1
-
-#ID_MODEL=VIRTUAL-DISK
-#ID_MODEL_ENC=VIRTUAL-DISK
-#ID_REVISION=0001
-#DEVTYPE=disk
-#ID_BUS=scsi
-#SUBSYSTEM=block
-#ID_SERIAL=1IET_00010001
-#DEVPATH=/devices/platform/host74/session68/target74:0:0/74:0:0:1/block/sde
-#ID_VENDOR_ENC=IET\x20\x20\x20\x20\x20
-#MINOR=64
-#ID_SCSI=1
-#ACTION=add
-#PWD=/
-#ID_PART_TABLE_UUID=54f71c65-a5d5-45cd-8915-5ffd5ff4fea6
-#ID_FS_TYPE=
-#USEC_INITIALIZED=999037905
-#MAJOR=8
-#ID_SCSI_SERIAL=beaf11
-#DEVLINKS=/dev/disk/by-id/scsi-1IET_00010001
-#DEVNAME=/dev/sde
-#SHLVL=1
-#ID_TYPE=disk
-#ID_PART_TABLE_TYPE=gpt
-#ID_VENDOR=IET
-#ID_SERIAL_SHORT=IET_00010001
-#SEQNUM=25775
-
-# do the removal
-if [[ $ACTION = 'remove' ]]; then
-  # nohup needed so this isn't constantly run...
-  nohup find -L /dev/disk/by-path/ -type l -lname ${DEVNAME} -exec rm "{}" + 2>/dev/null &
-  exit 0
-fi
-
-TARGET_NAME=$(lsscsi -t | grep "${DEVNAME}" | awk '{print $3}' | awk -F, '{print $1}')
-[[ $TARGET_NAME = '' ]] && exit 1
-
-# we don't know which host is correct
-declare -a POSSIBLE_HOSTS
-declare -a POSSIBLE_PORTS
-for item in $(cat /sys/class/iscsi_connection/connection*/address); do
-  POSSIBLE_HOSTS+=("${item}")
-done
-for item in $(cat /sys/class/iscsi_connection/connection*/port); do
-  POSSIBLE_PORTS+=("${item}")
-done
-
-#get correct ip and port
-for ((i=0;i<${#POSSIBLE_HOSTS[@]};++i)); do
-  printf "%s is in %s\n" "$POSSIBLE_HOSTS[i]}" "${POSSIBLE_PORTS[i]}"
-  iscsiadm --mode node --targetname "${TARGET_NAME}" -p "${POSSIBLE_HOSTS[i]}":"${POSSIBLE_PORTS[i]}"
-  status=$?
-  if [[ $status = 0 ]]; then
-    TARGET_IP="${POSSIBLE_HOSTS[i]}"
-    TARGET_PORT="${POSSIBLE_PORTS[i]}"
-    break
-  fi
-done
-
-# exit if not found
-[[ -z $TARGET_IP ]] && exit 1
-[[ -z $TARGET_PORT ]] && exit 1
-
-# actually create the link
-mkdir -p /dev/disk/by-path/
-ln -s "${DEVNAME}" "/dev/disk/by-path/ip-${TARGET_IP}:${TARGET_PORT}-iscsi-${TARGET_NAME}-lun-1"

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch
deleted file mode 100644
index 33c5d8a960d..00000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.0.874-Makefiles.patch
+++ /dev/null
@@ -1,116 +0,0 @@
-diff -dur a/Makefile b/Makefile
---- a/Makefile	2016-09-29 13:33:24.000000000 -0500
-+++ b/Makefile	2017-01-02 11:25:04.606549073 -0600
-@@ -14,8 +14,8 @@
- etcdir = /etc
- initddir = $(etcdir)/init.d
- 
--MANPAGES = doc/iscsid.8 doc/iscsiadm.8 doc/iscsi_discovery.8 iscsiuio/docs/iscsiuio.8
--PROGRAMS = usr/iscsid usr/iscsiadm utils/iscsi_discovery utils/iscsi-iname iscsiuio/src/unix/iscsiuio
-+MANPAGES = doc/iscsid.8 doc/iscsiadm.8 doc/iscsi_discovery.8 doc/iscsistart.8 doc/iscsi-iname.8
-+PROGRAMS = usr/iscsid usr/iscsiadm utils/iscsi_discovery utils/iscsi-iname usr/iscsistart
- INSTALL = install
- ETCFILES = etc/iscsid.conf
- IFACEFILES = etc/iface.example
-@@ -99,11 +99,11 @@
- # ugh, auto-detection is evil
- # Gentoo maintains their own init.d stuff
- install_initd:
--	if [ -f /etc/debian_version ]; then \
-+	if [ -f $(DESTDIR)$(etcdir)/debian_version ]; then \
- 		$(MAKE) install_initd_debian ; \
--	elif [ -f /etc/redhat-release ]; then \
-+	elif [ -f $(DESTDIR)$(etcdir)/redhat-release ]; then \
- 		$(MAKE) install_initd_redhat ; \
--	elif [ -f /etc/SuSE-release ]; then \
-+	elif [ -f $(DESTDIR)$(etcdir)/SuSE-release ]; then \
- 		$(MAKE) install_initd_suse ; \
- 	fi
- 
-@@ -130,7 +130,7 @@
- 	$(INSTALL) -m 644 $^ $(DESTDIR)$(etcdir)/iscsi/ifaces
- 
- install_etc: $(ETCFILES)
--	if [ ! -f $(DESTDIR)/etc/iscsi/iscsid.conf ]; then \
-+	if [ ! -f $(DESTDIR)$(etcdir)/iscsi/iscsid.conf ]; then \
- 		$(INSTALL) -d $(DESTDIR)$(etcdir)/iscsi ; \
- 		$(INSTALL) -m 644 $^ $(DESTDIR)$(etcdir)/iscsi ; \
- 	fi
-@@ -143,11 +143,11 @@
- 	$(MAKE) -C kernel install_kernel
- 
- install_iname:
--	if [ ! -f $(DESTDIR)/etc/iscsi/initiatorname.iscsi ]; then \
--		echo "InitiatorName=`$(DESTDIR)/sbin/iscsi-iname`" > $(DESTDIR)/etc/iscsi/initiatorname.iscsi ; \
-+	if [ ! -f $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi ]; then \
-+		echo "InitiatorName=`$(DESTDIR)$(sbindir)/iscsi-iname`" > $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi ; \
- 		echo "***************************************************" ; \
--		echo "Setting InitiatorName to `cat $(DESTDIR)/etc/iscsi/initiatorname.iscsi`" ; \
--		echo "To override edit $(DESTDIR)/etc/iscsi/initiatorname.iscsi" ; \
-+		echo "Setting InitiatorName to `cat $(DESTDIR)$(etcdir)/iscsi/initiatorname.iscsi`" ; \
-+		echo "To override edit $(etcdir)/iscsi/initiatorname.iscsi" ; \
- 		echo "***************************************************" ; \
- 	fi
- 
-diff -dur a/usr/Makefile b/usr/Makefile
---- a/usr/Makefile	2016-09-29 13:33:24.000000000 -0500
-+++ b/usr/Makefile	2017-01-02 11:27:55.417297639 -0600
-@@ -63,9 +63,9 @@
- 		iscsistart.o statics.o
- 	$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ -lrt
- clean:
--	rm -f *.o $(PROGRAMS) .depend $(LIBSYS)
-+	$(RM) *.o $(PROGRAMS) .depend $(LIBSYS)
- 
- depend:
--	gcc $(CFLAGS) -M `ls *.c` > .depend
-+	$(CC) $(CFLAGS) -M `ls *.c` > .depend
- 
- -include .depend
-diff -dur a/utils/fwparam_ibft/Makefile b/utils/fwparam_ibft/Makefile
---- a/utils/fwparam_ibft/Makefile	2016-09-29 13:33:24.000000000 -0500
-+++ b/utils/fwparam_ibft/Makefile	2017-01-02 11:30:42.358440507 -0600
-@@ -33,11 +33,11 @@
- all: $(OBJS)
- 
- clean:
--	rm -f *.o $(CLEANFILES) .depend
-+	$(RM) *.o $(CLEANFILES) .depend
- 
- $(OBJS): prom_parse.tab.h prom_parse.h fwparam_ibft.h
- 
- depend:
--	gcc $(CFLAGS) -M `ls *.c` > .depend
-+	$(CC) $(CFLAGS) -M `ls *.c` > .depend
- 
- -include .depend
-diff -dur a/utils/Makefile b/utils/Makefile
---- a/utils/Makefile	2016-09-29 13:33:24.000000000 -0500
-+++ b/utils/Makefile	2017-01-02 11:29:24.193611039 -0600
-@@ -10,9 +10,9 @@
- 	$(CC) $(CFLAGS) $(LDFLAGS) $^ $(DBM_LIB) -o $@
- 
- clean:
--	rm -f *.o $(PROGRAMS) .depend
-+	$(RM) *.o $(PROGRAMS) .depend
- 
- depend:
--	gcc $(CFLAGS) -M `ls *.c` > .depend
-+	$(GCC) $(CFLAGS) -M `ls *.c` > .depend
- 
- -include .depend
-diff -dur a/utils/sysdeps/Makefile b/utils/sysdeps/Makefile
---- a/utils/sysdeps/Makefile	2016-09-29 13:33:24.000000000 -0500
-+++ b/utils/sysdeps/Makefile	2017-01-02 11:31:24.219926338 -0600
-@@ -8,9 +8,9 @@
- all: $(SYSDEPS_OBJS)
- 
- clean:
--	rm -f *.o .depend
-+	$(RM) *.o .depend
- 
- depend:
--	gcc $(CFLAGS) -M `ls *.c` > .depend
-+	$(CC) $(CFLAGS) -M `ls *.c` > .depend
- 
- -include .depend

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-ethtool-compat.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-ethtool-compat.patch
deleted file mode 100644
index 12b82c71405..00000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-ethtool-compat.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-From: Anthony G. Basiel <blueness@gentoo.org>
-
-diff -Naur open-iscsi-2.0.874.orig/iscsiuio/src/unix/libs/bnx2x.c open-iscsi-2.0.874/iscsiuio/src/unix/libs/bnx2x.c
---- open-iscsi-2.0.874.orig/iscsiuio/src/unix/libs/bnx2x.c	2016-09-29 18:33:24.000000000 +0000
-+++ open-iscsi-2.0.874/iscsiuio/src/unix/libs/bnx2x.c	2017-01-03 21:45:47.504035833 +0000
-@@ -42,7 +42,7 @@
- #include <arpa/inet.h>
- #include <linux/types.h>	/* Needed for linux/ethtool.h on RHEL 5.x */
- #include <linux/sockios.h>
--#include <linux/ethtool.h>
-+#include "ethtool-compat.h"
- #include <sys/mman.h>
- #include <sys/ioctl.h>
- #include <sys/types.h>
-diff -Naur open-iscsi-2.0.874.orig/iscsiuio/src/unix/libs/ethtool-compat.h open-iscsi-2.0.874/iscsiuio/src/unix/libs/ethtool-compat.h
---- open-iscsi-2.0.874.orig/iscsiuio/src/unix/libs/ethtool-compat.h	1970-01-01 00:00:00.000000000 +0000
-+++ open-iscsi-2.0.874/iscsiuio/src/unix/libs/ethtool-compat.h	2017-01-03 21:45:23.016034980 +0000
-@@ -0,0 +1,51 @@
-+/*
-+ * ethtool-compat.h: adopted from
-+ # ethtool.h: Defines for Linux ethtool.
-+ *
-+ * Copyright (C) 1998 David S. Miller (davem@redhat.com)
-+ * Copyright 2001 Jeff Garzik <jgarzik@pobox.com>
-+ * Portions Copyright 2001 Sun Microsystems (thockin@sun.com)
-+ * Portions Copyright 2002 Intel (eli.kupermann@intel.com,
-+ *                                christopher.leech@intel.com,
-+ *                                scott.feldman@intel.com)
-+ * Portions Copyright (C) Sun Microsystems 2008
-+ */
-+
-+#include <linux/types.h>
-+#include <netinet/if_ether.h>
-+
-+#define ETHTOOL_FWVERS_LEN	32
-+#define ETHTOOL_BUSINFO_LEN	32
-+#define ETHTOOL_EROMVERS_LEN	32
-+
-+struct ethtool_drvinfo {
-+	__u32	cmd;
-+	char	driver[32];
-+	char	version[32];
-+	char	fw_version[ETHTOOL_FWVERS_LEN];
-+	char	bus_info[ETHTOOL_BUSINFO_LEN];
-+	char	erom_version[ETHTOOL_EROMVERS_LEN];
-+	char	reserved2[12];
-+	__u32	n_priv_flags;
-+	__u32	n_stats;
-+	__u32	testinfo_len;
-+	__u32	eedump_len;
-+	__u32	regdump_len;
-+};
-+
-+struct ethtool_tcpip4_spec {
-+	__be32	ip4src;
-+	__be32	ip4dst;
-+	__be16	psrc;
-+	__be16	pdst;
-+	__u8    tos;
-+};
-+
-+struct ethtool_ah_espip4_spec {
-+	__be32	ip4src;
-+	__be32	ip4dst;
-+	__be32	spi;
-+	__u8    tos;
-+};
-+
-+#define ETHTOOL_GDRVINFO	0x00000003 /* Get driver info. */

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch
deleted file mode 100644
index cf8b76210b9..00000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.0.874-musl-fixes.patch
+++ /dev/null
@@ -1,51 +0,0 @@
---- ./utils/fwparam_ibft/fwparam_ppc.c	2016-09-29 13:33:24.000000000 -0500
-+++ ./utils/fwparam_ibft/fwparam_ppc.c	2017-01-02 11:37:32.738351217 -0600
-@@ -356,7 +356,7 @@
- 	 * Sort the nics into "natural" order.	The proc fs
- 	 * device-tree has them in somewhat random, or reversed order.
- 	 */
--	qsort(niclist, nic_count, sizeof(char *), (__compar_fn_t)nic_cmp);
-+	qsort(niclist, nic_count, sizeof(char *), (int (*)(const void *, const void *))nic_cmp);
- 
- 	snprintf(prefix, sizeof(prefix), "%s/%s", devtree, "aliases");
- 	dev_count = 0;
---- ./usr/idbm.c.orig
-+++ ./usr/idbm.c
-@@ -25,6 +25,7 @@
- #include <stdlib.h>
- #include <string.h>
- #include <errno.h>
-+#include <fcntl.h>
- #include <dirent.h>
- #include <limits.h>
- #include <sys/stat.h>
---- a/usr/iscsiadm.c	2016-09-29 13:33:24.000000000 -0500
-+++ b/usr/iscsiadm.c	2017-01-02 11:46:37.643506953 -0600
-@@ -3262,6 +3262,7 @@
- 	int tpgt = PORTAL_GROUP_TAG_UNKNOWN, killiscsid=-1, do_show=0;
- 	int packet_size=32, ping_count=1, ping_interval=0;
- 	int do_discover = 0, sub_mode = -1;
-+	int argerror = 0;
- 	int portal_type = -1;
- 	struct sigaction sa_old;
- 	struct sigaction sa_new;
-@@ -3426,6 +3427,9 @@
- 			break;
- 		case 'h':
- 			usage(0);
-+		case '?':
-+			log_error("unrecognized character '%c'", optopt);
-+			argerror = 1;
- 		}
- 
- 		if (name && value) {
-@@ -3441,8 +3445,7 @@
- 		}
- 	}
- 
--	if (optopt) {
--		log_error("unrecognized character '%c'", optopt);
-+	if (argerror) {
- 		rc = ISCSI_ERR_INVAL;
- 		goto free_ifaces;
- 	}

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.0.875-include-sysmacros.patch b/sys-block/open-iscsi/files/open-iscsi-2.0.875-include-sysmacros.patch
deleted file mode 100644
index 7c19a1e6ba2..00000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.0.875-include-sysmacros.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From 6d68ef5871c94c6ebbbe6e6b1fe0bc2dce711052 Mon Sep 17 00:00:00 2001
-From: Lee Duncan <lduncan@suse.com>
-Date: Sat, 2 Dec 2017 14:19:26 -0800
-Subject: [PATCH] Include <sys/sysmacros.h> to properly define minor()
-
----
- iscsiuio/src/unix/libs/qedi.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/iscsiuio/src/unix/libs/qedi.c b/iscsiuio/src/unix/libs/qedi.c
-index c6ff6e77..b81fecdf 100644
---- a/iscsiuio/src/unix/libs/qedi.c
-+++ b/iscsiuio/src/unix/libs/qedi.c
-@@ -58,6 +58,7 @@
- #include <sys/user.h>
- #include <fcntl.h>
- #include <unistd.h>
-+#include <sys/sysmacros.h>
- 
- #include "config.h"
- 

diff --git a/sys-block/open-iscsi/open-iscsi-2.0.875.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.875.ebuild
deleted file mode 100644
index d92237185ef..00000000000
--- a/sys-block/open-iscsi/open-iscsi-2.0.875.ebuild
+++ /dev/null
@@ -1,127 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit autotools versionator linux-info flag-o-matic toolchain-funcs udev systemd
-
-DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
-HOMEPAGE="http://www.open-iscsi.com/"
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~mips ppc ppc64 sparc x86"
-IUSE="debug infiniband +tcp rdma"
-
-DEPEND="sys-block/open-isns:=
-	infiniband? ( sys-fabric/ofed )
-	sys-kernel/linux-headers"
-RDEPEND="${DEPEND}
-	sys-fs/lsscsi
-	sys-apps/util-linux"
-REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
-
-PATCHES=(
-	"${FILESDIR}/${PN}-2.0.874-Makefiles.patch"
-	"${FILESDIR}/${PN}-2.0.874-musl-fixes.patch"
-	"${FILESDIR}/${PN}-2.0.874-musl-ethtool-compat.patch"
-	"${FILESDIR}/${P}-include-sysmacros.patch"
-)
-
-pkg_setup() {
-	linux-info_pkg_setup
-
-	if kernel_is -lt 2 6 16; then
-		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
-	fi
-
-	# Needs to be done, as iscsid currently only starts, when having the iSCSI
-	# support loaded as module. Kernel builtin options don't work. See this for
-	# more information:
-	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
-	# If there's a new release, check whether this is still valid!
-	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
-	RDMA_MODULES="INFINIBAND_ISER"
-	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
-	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
-	if linux_config_exists; then
-		if use tcp; then
-			for module in ${TCP_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use infiniband; then
-			for module in ${INFINIBAND_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use rdma; then
-			for module in ${RDMA_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
-			done
-		fi
-	fi
-}
-
-src_prepare() {
-	sed -i -e 's:^\(iscsid.startup\)\s*=.*:\1 = /usr/sbin/iscsid:' etc/iscsid.conf || die
-	default
-
-	pushd iscsiuio >/dev/null || die
-	eautoreconf
-	popd >/dev/null || die
-}
-
-src_configure() {
-	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
-
-	# bug #643122
-	append-flags -fcommon
-
-	append-lfs-flags
-}
-
-src_compile() {
-	# Stuffing CPPFLAGS into CFLAGS isn't entirely correct, but the build
-	# is messed up already here, so it's not making it that much worse.
-	KSRC="${KV_DIR}" CFLAGS="" \
-	emake \
-		OPTFLAGS="${CFLAGS} ${CPPFLAGS}" \
-		AR="$(tc-getAR)" CC="$(tc-getCC)" \
-		user
-}
-
-src_install() {
-	emake DESTDIR="${ED}" sbindir="/usr/sbin" install
-	# Upstream make is not deterministic, per bug #601514
-	rm -f "${ED}"/etc/initiatorname.iscsi
-
-	dodoc README THANKS
-
-	docinto test/
-	dodoc test/*
-
-	insinto /etc/iscsi
-	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
-
-	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
-	newinitd "${FILESDIR}"/iscsid-init.d iscsid
-
-	systemd_dounit "${S%/}"/etc/systemd/iscsid.service
-
-	keepdir /var/db/iscsi
-	fperms 700 /var/db/iscsi
-	fperms 600 /etc/iscsi/iscsid.conf
-}
-
-pkg_postinst() {
-	in='/etc/iscsi/initiatorname.iscsi'
-	if [ ! -f "${EROOT}${in}" -a -f "${EROOT}${in}.example" ]; then
-		{
-		  cat "${EROOT}${in}.example"
-		  echo "# InitiatorName generated by ${CATEGORY}/${PF} at $(date -uR)"
-		  echo "InitiatorName=$(${ROOT}/usr/sbin/iscsi-iname)"
-		} >> "${EROOT}${in}.tmp" && mv -f "${EROOT}${in}.tmp" "${EROOT}${in}"
-	fi
-}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2022-06-02 18:21 Matthias Maier
  0 siblings, 0 replies; 11+ messages in thread
From: Matthias Maier @ 2022-06-02 18:21 UTC (permalink / raw
  To: gentoo-commits

commit:     5536cd18a01bb593e72daa0dfe54297022cb5e7a
Author:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
AuthorDate: Thu Jun  2 18:18:56 2022 +0000
Commit:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
CommitDate: Thu Jun  2 18:20:46 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5536cd18

sys-block/open-iscsi: version bump to 2.1.7, various fixes

 - drop (parts of the) old patches for 2.1.6 as they have been upstreamed

 - remove -Werror from compiler command line

 - remove hardcoded sed path

 - use __bitwise instead of __bitwise__ macro. The latter seems to be a
   typo

Bug: https://bugs.gentoo.org/847418
Signed-off-by: Matthias Maier <tamiko <AT> gentoo.org>

 sys-block/open-iscsi/Manifest                      |  1 +
 .../files/open-iscsi-2.1.7-fix_bitwise.patch       | 52 +++++++++++++++++
 .../files/open-iscsi-2.1.7-fix_sed.patch           | 67 ++++++++++++++++++++++
 .../files/open-iscsi-2.1.7-no_werror.patch         | 26 +++++++++
 sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild    |  2 +-
 ...csi-2.1.6-r1.ebuild => open-iscsi-2.1.7.ebuild} |  5 +-
 6 files changed, 150 insertions(+), 3 deletions(-)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index 29d5b970a89c..4c6d1313583c 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -1,2 +1,3 @@
 DIST open-iscsi-2.1.4.tar.gz 621247 BLAKE2B 043a999b2f397a6c740d61654079d7ab966caee6cf6cfb244ddd70eae4f5201045b371ce5fbe244216a2a210a5379c92e8c3fbe62d33707cf05e7a4a20a13a91 SHA512 ae0663a964d86e6a4c19203598b859173c93ecce550f9bc9855ff735dd51a3c45822f2bc1cc99e6891c56ef1d16c42223803f07a961558fe6e38ead2164faef3
 DIST open-iscsi-2.1.6.tar.gz 623721 BLAKE2B c7c09e38fd10bd5c2a5e8ad8030cf2338de3382fe4acae0e3c1bf3cacb6e244e411b7556403e0c43fd03035836f46cc4836683188e2f159cd7fc066aef78a868 SHA512 4a32a76c1c32d7d1a01fe3a0f88ce9616a54323ec043757be73051eb41ebae8de90ce057acce72fb6fe07aa47e814c9bc6ee88b13fa7d7769ca10c5175974f1d
+DIST open-iscsi-2.1.7.tar.gz 627848 BLAKE2B c8b572dc71046b722b9455799b4360c17963f05ce2cac48f122d40fc61bef6f01b98287003fc222bdb0dd4706218add8c41d3eb40464023b9b240a8205069dd3 SHA512 619c57b988c6972da09428b3a84ca375ca46653fbfca9cb61389c70a95871b665f93b75b8e6ff2aa993bdb89e2a078a188c0a7b45c3bf9c15a16b496e9ebc892

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_bitwise.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_bitwise.patch
new file mode 100644
index 000000000000..2ff094c83f0f
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_bitwise.patch
@@ -0,0 +1,52 @@
+From 0a6432de1a2186449d5e6557f75a9f30e487471d Mon Sep 17 00:00:00 2001
+From: Matthias Maier <tamiko@43-1.org>
+Date: Thu, 2 Jun 2022 13:12:43 -0500
+Subject: [PATCH] Use __bitwise instead of __bitwise__
+
+The iscsi_proto.h header goes into great length ensuring that the
+__bitwise macro is defined:
+
+  #if !defined(__bitwise)
+  /*
+   * If running svn modules we may need to define these.
+   * This should not go upstream since this is already properly defined there
+   */
+  #ifdef __CHECKER__
+  #define __bitwise__ __attribute__((bitwise))
+  #else
+  #define __bitwise__
+  #endif
+  #ifdef __CHECK_ENDIAN__
+  #define __bitwise __bitwise__
+  #else
+  #define __bitwise
+  #endif
+  #endif
+
+But then uses the __bitwise__ macro instead:
+
+  typedef uint32_t __bitwise__ itt_t;
+
+(This is the only occurence where the __bitwise__ (or __bitwise) macro
+is actually used). This seems to be a typo, changing this to __bitwise
+fixes compilation with gcc-11 onwards.
+---
+ include/iscsi_proto.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/iscsi_proto.h b/include/iscsi_proto.h
+index 1d14b89..3fe9018 100644
+--- a/include/iscsi_proto.h
++++ b/include/iscsi_proto.h
+@@ -63,7 +63,7 @@
+ #endif
+ 
+ /* initiator tags; opaque for target */
+-typedef uint32_t __bitwise__ itt_t;
++typedef uint32_t __bitwise itt_t;
+ /* below makes sense only for initiator that created this tag */
+ #define build_itt(itt, age) ((__force itt_t)\
+ 	((itt) | ((age) << ISCSI_AGE_SHIFT)))
+-- 
+2.35.1
+

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch
new file mode 100644
index 000000000000..ad56b823b557
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch
@@ -0,0 +1,67 @@
+From 66d76978f2ffbe276e84b03a7fac1041a7c3b4c3 Mon Sep 17 00:00:00 2001
+From: Matthias Maier <tamiko@43-1.org>
+Date: Thu, 2 Jun 2022 13:17:10 -0500
+Subject: [PATCH] Do not hardcode the path of sed
+
+---
+ doc/Makefile             | 2 +-
+ etc/Makefile             | 2 +-
+ libopeniscsiusr/Makefile | 2 +-
+ utils/Makefile           | 2 +-
+ 4 files changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/doc/Makefile b/doc/Makefile
+index 9ed025d..e121270 100644
+--- a/doc/Makefile
++++ b/doc/Makefile
+@@ -7,7 +7,7 @@ ifeq ($(TOPDIR),)
+ 	TOPDIR = ..
+ endif
+ 
+-SED = /usr/bin/sed
++SED = sed
+ INSTALL = install
+ 
+ DESTDIR ?=
+diff --git a/etc/Makefile b/etc/Makefile
+index d065319..2d98027 100644
+--- a/etc/Makefile
++++ b/etc/Makefile
+@@ -19,7 +19,7 @@ initddir ?= $(etcdir)/init.d
+ 
+ HOMEDIR ?= $(etcdir)/iscsi
+ 
+-SED = /usr/bin/sed
++SED = sed
+ INSTALL = install
+ 
+ SYSTEMD_SOURCE_FILES	= iscsid.socket iscsiuio.socket
+diff --git a/libopeniscsiusr/Makefile b/libopeniscsiusr/Makefile
+index 523518b..90903dd 100644
+--- a/libopeniscsiusr/Makefile
++++ b/libopeniscsiusr/Makefile
+@@ -29,7 +29,7 @@ PKGCONF_DIR ?= $(LIB_DIR)/pkgconfig
+ MAN_DIR = $(prefix)/share/man
+ 
+ PKG_CONFIG ?= /usr/bin/pkg-config
+-SED ?= /usr/bin/sed
++SED ?= sed
+ 
+ LIBISCSI_USR_DIR=$(TOPDIR)/libopeniscsiusr
+ 
+diff --git a/utils/Makefile b/utils/Makefile
+index a7eb352..15539eb 100644
+--- a/utils/Makefile
++++ b/utils/Makefile
+@@ -7,7 +7,7 @@
+ # from the top-level make file.
+ #
+ 
+-SED = /usr/bin/sed
++SED = sed
+ INSTALL = install
+ CHMOD = chmod
+ 
+-- 
+2.35.1
+

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.7-no_werror.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.7-no_werror.patch
new file mode 100644
index 000000000000..a94caebafb13
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.1.7-no_werror.patch
@@ -0,0 +1,26 @@
+diff --git a/libopeniscsiusr/Makefile b/libopeniscsiusr/Makefile
+index 52e453a..523518b 100644
+--- a/libopeniscsiusr/Makefile
++++ b/libopeniscsiusr/Makefile
+@@ -51,7 +51,7 @@ EXTRA_MAN_FILES = libopeniscsiusr.h.3
+ OBJS = context.o misc.o session.o sysfs.o iface.o idbm.o node.o default.o
+ 
+ CFLAGS ?= -O2 -g
+-CFLAGS += -Wall -Werror -Wextra -fvisibility=hidden -fPIC
++CFLAGS += -Wall  -Wextra -fvisibility=hidden -fPIC
+ CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)
+ CFLAGS += -DSBINDIR=\"$(SBINDIR)\"
+ CFLAGS += -DISCSI_DB_ROOT=\"$(DBROOT)\"
+diff --git a/usr/Makefile b/usr/Makefile
+index 3fc2248..c3580a3 100644
+--- a/usr/Makefile
++++ b/usr/Makefile
+@@ -44,7 +44,7 @@ HOMEDIR ?= $(etcdir)/iscsi
+ PKG_CONFIG ?= /usr/bin/pkg-config
+ 
+ CFLAGS ?= -O2 -g
+-WARNFLAGS ?= -Wall -Wextra -Werror -Wstrict-prototypes -fno-common
++WARNFLAGS ?= -Wall -Wextra  -Wstrict-prototypes -fno-common
+ CFLAGS += $(WARNFLAGS) -I../include -I. -D_GNU_SOURCE \
+ 	  -I$(TOPDIR)/libopeniscsiusr
+ CFLAGS += $(shell $(PKG_CONFIG) --cflags libkmod)

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild
index 576fdc85f330..2f006231aaa2 100644
--- a/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild
+++ b/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild
@@ -29,7 +29,7 @@ RDEPEND="${DEPEND}
 BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-2.1.1-Makefiles.patch
+	"${FILESDIR}"/${PN}-2.1.7-NoWError.patch
 	"${FILESDIR}"/open-iscsi-2.1.6-Makefiles.patch
 )
 

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.7.ebuild
similarity index 96%
copy from sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild
copy to sys-block/open-iscsi/open-iscsi-2.1.7.ebuild
index 576fdc85f330..3bf611eea398 100644
--- a/sys-block/open-iscsi/open-iscsi-2.1.6-r1.ebuild
+++ b/sys-block/open-iscsi/open-iscsi-2.1.7.ebuild
@@ -29,8 +29,9 @@ RDEPEND="${DEPEND}
 BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
-	"${FILESDIR}"/${PN}-2.1.1-Makefiles.patch
-	"${FILESDIR}"/open-iscsi-2.1.6-Makefiles.patch
+	"${FILESDIR}"/${PN}-2.1.7-fix_bitwise.patch
+	"${FILESDIR}"/${PN}-2.1.7-fix_sed.patch
+	"${FILESDIR}"/${PN}-2.1.7-no_werror.patch
 )
 
 pkg_setup() {


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2022-10-28 19:53 Sam James
  0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2022-10-28 19:53 UTC (permalink / raw
  To: gentoo-commits

commit:     fdfdde7b9167fa1d8740b2d35947aa0c9d94025b
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Oct 28 19:39:34 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Oct 28 19:50:09 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fdfdde7b

sys-block/open-iscsi: drop 2.1.7

Signed-off-by: Sam James <sam <AT> gentoo.org>

 sys-block/open-iscsi/Manifest                      |   1 -
 .../files/open-iscsi-2.1.7-fix_sed.patch           |  67 ----------
 sys-block/open-iscsi/open-iscsi-2.1.7.ebuild       | 145 ---------------------
 3 files changed, 213 deletions(-)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index cc797e94f30c..a7246276375b 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -1,3 +1,2 @@
 DIST open-iscsi-2.1.4.tar.gz 621247 BLAKE2B 043a999b2f397a6c740d61654079d7ab966caee6cf6cfb244ddd70eae4f5201045b371ce5fbe244216a2a210a5379c92e8c3fbe62d33707cf05e7a4a20a13a91 SHA512 ae0663a964d86e6a4c19203598b859173c93ecce550f9bc9855ff735dd51a3c45822f2bc1cc99e6891c56ef1d16c42223803f07a961558fe6e38ead2164faef3
-DIST open-iscsi-2.1.7.tar.gz 627848 BLAKE2B c8b572dc71046b722b9455799b4360c17963f05ce2cac48f122d40fc61bef6f01b98287003fc222bdb0dd4706218add8c41d3eb40464023b9b240a8205069dd3 SHA512 619c57b988c6972da09428b3a84ca375ca46653fbfca9cb61389c70a95871b665f93b75b8e6ff2aa993bdb89e2a078a188c0a7b45c3bf9c15a16b496e9ebc892
 DIST open-iscsi-2.1.8.tar.gz 638346 BLAKE2B 1e85b6bd75ac31e5aaa65ea8869c2e6e13190786e28e473ab8bd1ea3edb0ef835624194e2ba53718fb2a49c25af53bff9035f5109e1a569155244f03a7dccdc0 SHA512 168ce68dc495cc8b2f217ad0373851d681f9274036b8ec562ece513de493adfdbba55f2038518f246f5244f6405102b2e096a9cce15e73fce9654f06790002c1

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch
deleted file mode 100644
index ad56b823b557..000000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.1.7-fix_sed.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-From 66d76978f2ffbe276e84b03a7fac1041a7c3b4c3 Mon Sep 17 00:00:00 2001
-From: Matthias Maier <tamiko@43-1.org>
-Date: Thu, 2 Jun 2022 13:17:10 -0500
-Subject: [PATCH] Do not hardcode the path of sed
-
----
- doc/Makefile             | 2 +-
- etc/Makefile             | 2 +-
- libopeniscsiusr/Makefile | 2 +-
- utils/Makefile           | 2 +-
- 4 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/doc/Makefile b/doc/Makefile
-index 9ed025d..e121270 100644
---- a/doc/Makefile
-+++ b/doc/Makefile
-@@ -7,7 +7,7 @@ ifeq ($(TOPDIR),)
- 	TOPDIR = ..
- endif
- 
--SED = /usr/bin/sed
-+SED = sed
- INSTALL = install
- 
- DESTDIR ?=
-diff --git a/etc/Makefile b/etc/Makefile
-index d065319..2d98027 100644
---- a/etc/Makefile
-+++ b/etc/Makefile
-@@ -19,7 +19,7 @@ initddir ?= $(etcdir)/init.d
- 
- HOMEDIR ?= $(etcdir)/iscsi
- 
--SED = /usr/bin/sed
-+SED = sed
- INSTALL = install
- 
- SYSTEMD_SOURCE_FILES	= iscsid.socket iscsiuio.socket
-diff --git a/libopeniscsiusr/Makefile b/libopeniscsiusr/Makefile
-index 523518b..90903dd 100644
---- a/libopeniscsiusr/Makefile
-+++ b/libopeniscsiusr/Makefile
-@@ -29,7 +29,7 @@ PKGCONF_DIR ?= $(LIB_DIR)/pkgconfig
- MAN_DIR = $(prefix)/share/man
- 
- PKG_CONFIG ?= /usr/bin/pkg-config
--SED ?= /usr/bin/sed
-+SED ?= sed
- 
- LIBISCSI_USR_DIR=$(TOPDIR)/libopeniscsiusr
- 
-diff --git a/utils/Makefile b/utils/Makefile
-index a7eb352..15539eb 100644
---- a/utils/Makefile
-+++ b/utils/Makefile
-@@ -7,7 +7,7 @@
- # from the top-level make file.
- #
- 
--SED = /usr/bin/sed
-+SED = sed
- INSTALL = install
- CHMOD = chmod
- 
--- 
-2.35.1
-

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.7.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.7.ebuild
deleted file mode 100644
index 552d373862e7..000000000000
--- a/sys-block/open-iscsi/open-iscsi-2.1.7.ebuild
+++ /dev/null
@@ -1,145 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools linux-info flag-o-matic toolchain-funcs systemd udev
-
-DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
-HOMEPAGE="https://www.open-iscsi.com/"
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0/0.2"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86"
-IUSE="debug infiniband +tcp rdma systemd"
-REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
-
-DEPEND="
-	sys-apps/kmod
-	sys-block/open-isns:=
-	sys-kernel/linux-headers
-	infiniband? ( sys-cluster/rdma-core )
-	dev-libs/openssl:0=
-	systemd? ( sys-apps/systemd )
-"
-RDEPEND="${DEPEND}
-	sys-fs/lsscsi
-	sys-apps/util-linux"
-BDEPEND="virtual/pkgconfig"
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-2.1.7-fix_bitwise.patch
-	"${FILESDIR}"/${PN}-2.1.7-fix_sed.patch
-	"${FILESDIR}"/${PN}-2.1.7-no_werror.patch
-)
-
-pkg_setup() {
-	linux-info_pkg_setup
-
-	if kernel_is -lt 2 6 16; then
-		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
-	fi
-
-	# Needs to be done, as iscsid currently only starts, when having the iSCSI
-	# support loaded as module. Kernel builtin options don't work. See this for
-	# more information:
-	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
-	# If there's a new release, check whether this is still valid!
-	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
-	RDMA_MODULES="INFINIBAND_ISER"
-	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
-	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
-	if linux_config_exists; then
-		if use tcp; then
-			for module in ${TCP_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use infiniband; then
-			for module in ${INFINIBAND_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use rdma; then
-			for module in ${RDMA_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
-			done
-		fi
-	fi
-}
-
-src_prepare() {
-	default
-
-	pushd iscsiuio >/dev/null || die
-	eautoreconf
-	popd >/dev/null || die
-}
-
-src_configure() {
-	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
-
-	append-lfs-flags
-}
-
-src_compile() {
-	# Stuffing CPPFLAGS into CFLAGS isn't entirely correct, but the build
-	# is messed up already here, so it's not making it that much worse.
-	KSRC="${KV_DIR}" CFLAGS="" \
-	emake \
-		OPTFLAGS="${CFLAGS} ${CPPFLAGS} $(usex systemd '' -DNO_SYSTEMD)" \
-		AR="$(tc-getAR)" CC="$(tc-getCC)" \
-		$(usex systemd '' NO_SYSTEMD=1) \
-		user
-}
-
-src_install() {
-	# Force serial install to avoid race conditions
-	emake -j1 \
-		DESTDIR="${ED}" \
-		sbindir="/usr/sbin" \
-		SED="${EPREFIX}/bin/sed" \
-		systemddir="$(systemd_get_utildir)" \
-		install install_systemd
-
-	# Upstream make is not deterministic, per bug #601514
-	rm -f "${ED}"/etc/initiatorname.iscsi
-
-	# QA: install udev rule into right place
-	mkdir -p "${ED}"/lib/udev/rules.d
-	mv "${ED}"/etc/udev/rules.d/50-iscsi-firmware-login.rules \
-		"${ED}"/lib/udev/rules.d || die "mv failed"
-
-	# QA: let docompress compress man pages
-	gunzip -r "${ED}"/usr/share/man/man3/ || die "gunzip failed"
-	gunzip -r "${ED}"/usr/share/man/man8/ || die "gunzip failed"
-
-	dodoc README THANKS
-
-	docinto test/
-	dodoc $(find test -maxdepth 1 -type f ! -name ".*")
-
-	insinto /etc/iscsi
-	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
-
-	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
-	newinitd "${FILESDIR}"/iscsid-init.d iscsid
-
-	keepdir /var/db/iscsi
-	fperms 700 /var/db/iscsi
-	fperms 600 /etc/iscsi/iscsid.conf
-}
-
-pkg_postinst() {
-	in='/etc/iscsi/initiatorname.iscsi'
-	if [[ ! -f "${EROOT}${in}" ]] && [[ -f "${EROOT}${in}.example" ]] ; then
-		{
-		  cat "${EROOT}${in}.example"
-		  echo "# InitiatorName generated by ${CATEGORY}/${PF} at $(date -uR)"
-		  echo "InitiatorName=$(${ROOT}/usr/sbin/iscsi-iname)"
-		} >> "${EROOT}${in}.tmp" && mv -f "${EROOT}${in}.tmp" "${EROOT}${in}"
-	fi
-
-	udev_reload
-}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2023-12-22  8:46 Sam James
  0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2023-12-22  8:46 UTC (permalink / raw
  To: gentoo-commits

commit:     a4679a1282ec6986ce6f603bc81ab25c29ce7d49
Author:     Stijn Tintel <stijn <AT> linux-ipv6 <DOT> be>
AuthorDate: Fri Nov  3 01:09:30 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Dec 22 08:46:19 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a4679a12

sys-block/open-iscsi: fix build against musl

Add an upstream patch that fixes build on musl.

Closes: https://bugs.gentoo.org/908587
Signed-off-by: Stijn Tintel <stijn <AT> linux-ipv6.be>
Closes: https://github.com/gentoo/gentoo/pull/33657
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch | 40 ++++++++++++++++++++++
 sys-block/open-iscsi/open-iscsi-2.1.9.ebuild       |  1 +
 2 files changed, 41 insertions(+)

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch
new file mode 100644
index 000000000000..0c4a2aa13ab7
--- /dev/null
+++ b/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch
@@ -0,0 +1,40 @@
+From 11bdc17938ba648c81a853355a6bbddad69a9fc7 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Wed, 4 Oct 2023 23:18:20 +0200
+Subject: [PATCH] usr/idbm.c: fix musl build (#426)
+
+Fix the following musl build failure raised since version 2.1.9 and
+https://github.com/open-iscsi/open-iscsi/commit/7b571d76d6937a78c141630fc38c3c57c532466c:
+
+../usr/idbm.c: In function 'idbm_rec_write_old':
+../usr/idbm.c:2230:27: error: 'GLOB_ONLYDIR' undeclared (first use in this function)
+ 2230 |         rc = glob(portal, GLOB_ONLYDIR, NULL, &globbuf);
+      |                           ^~~~~~~~~~~~
+
+Fixes:
+ - http://autobuild.buildroot.org/results/14fc1c139f055b5b1eaa6e04e327863c06176a7b
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ usr/idbm.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/usr/idbm.c b/usr/idbm.c
+index ca4a4ec..c39abb6 100644
+--- a/usr/idbm.c
++++ b/usr/idbm.c
+@@ -45,6 +45,11 @@
+ #include "fw_context.h"
+ #include "iscsi_err.h"
+ 
++// GLOB_ONLYDIR is not defined under musl
++#ifndef GLOB_ONLYDIR
++#define GLOB_ONLYDIR	0x100
++#endif
++
+ #define IDBM_HIDE	0    /* Hide parameter when print. */
+ #define IDBM_SHOW	1    /* Show parameter when print. */
+ #define IDBM_MASKED	2    /* Show "stars" instead of real value when print */
+-- 
+2.41.0
+

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild
index a64f3cc0f0b1..d5126eaad442 100644
--- a/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild
+++ b/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild
@@ -34,6 +34,7 @@ BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
 	"${FILESDIR}"/${PN}-2.1.7-fix_bitwise.patch
+	"${FILESDIR}"/${P}-usr-idbm.c-fix-musl-build-426.patch
 )
 
 pkg_setup() {


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/
@ 2024-09-04 14:31 James Le Cuirot
  0 siblings, 0 replies; 11+ messages in thread
From: James Le Cuirot @ 2024-09-04 14:31 UTC (permalink / raw
  To: gentoo-commits

commit:     1ce156f0c4c38e92dc3fe8f5bd5c247b07893dcd
Author:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
AuthorDate: Mon Sep  2 10:28:21 2024 +0000
Commit:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Wed Sep  4 14:29:33 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ce156f0

sys-block/open-iscsi: Drop old 2.1.8 and 2.1.9

Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>

 sys-block/open-iscsi/Manifest                      |   2 -
 ...iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch |  43 --------
 sys-block/open-iscsi/open-iscsi-2.1.8.ebuild       | 117 --------------------
 sys-block/open-iscsi/open-iscsi-2.1.9.ebuild       | 120 ---------------------
 4 files changed, 282 deletions(-)

diff --git a/sys-block/open-iscsi/Manifest b/sys-block/open-iscsi/Manifest
index bcef9a2d7b16..4d023e607777 100644
--- a/sys-block/open-iscsi/Manifest
+++ b/sys-block/open-iscsi/Manifest
@@ -1,3 +1 @@
 DIST open-iscsi-2.1.10.tar.gz 645825 BLAKE2B 6a2e279e2dcf77e8d340c025eb59168121ee0c50bd013d0b5d9dac2fbc7116cc54904b4206eea192bd3888e3bcf3da42caeae1e428268edc6c2f7184958b6b04 SHA512 18b92d3e9a85d8de66734d95e9ca74a8acc5167a98830134c18ad5e226b29a00d358f952edfab67b643c454ec63c0a382c7ab7e7e76970f7574b46cea0d5c82d
-DIST open-iscsi-2.1.8.tar.gz 638346 BLAKE2B 1e85b6bd75ac31e5aaa65ea8869c2e6e13190786e28e473ab8bd1ea3edb0ef835624194e2ba53718fb2a49c25af53bff9035f5109e1a569155244f03a7dccdc0 SHA512 168ce68dc495cc8b2f217ad0373851d681f9274036b8ec562ece513de493adfdbba55f2038518f246f5244f6405102b2e096a9cce15e73fce9654f06790002c1
-DIST open-iscsi-2.1.9.tar.gz 641974 BLAKE2B 87570329dd5902bf96f1c11786c7a814892c851eabb63148f35b85494242f7379db1770a93549dcb871bafa148d37b320b389a98eed2ac46b7252ed22187ecd1 SHA512 25c28da5918b775ca54d3e55591eca0b4f7b5be33d803cad28fce1e9b2334b43cee1423a4e1819497b322e0f420dcd8d74226f442ca432233d1753565b11a5bb

diff --git a/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch b/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch
deleted file mode 100644
index 13215dafbb69..000000000000
--- a/sys-block/open-iscsi/files/open-iscsi-2.1.9-usr-idbm.c-fix-musl-build-426.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-https://github.com/open-iscsi/open-iscsi/commit/11bdc17938ba648c81a853355a6bbddad69a9fc7
-https://bugs.gentoo.org/908587
-
-From 11bdc17938ba648c81a853355a6bbddad69a9fc7 Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Wed, 4 Oct 2023 23:18:20 +0200
-Subject: [PATCH] usr/idbm.c: fix musl build (#426)
-
-Fix the following musl build failure raised since version 2.1.9 and
-https://github.com/open-iscsi/open-iscsi/commit/7b571d76d6937a78c141630fc38c3c57c532466c:
-
-../usr/idbm.c: In function 'idbm_rec_write_old':
-../usr/idbm.c:2230:27: error: 'GLOB_ONLYDIR' undeclared (first use in this function)
- 2230 |         rc = glob(portal, GLOB_ONLYDIR, NULL, &globbuf);
-      |                           ^~~~~~~~~~~~
-
-Fixes:
- - http://autobuild.buildroot.org/results/14fc1c139f055b5b1eaa6e04e327863c06176a7b
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
----
- usr/idbm.c | 5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/usr/idbm.c b/usr/idbm.c
-index ca4a4ec..c39abb6 100644
---- a/usr/idbm.c
-+++ b/usr/idbm.c
-@@ -45,6 +45,11 @@
- #include "fw_context.h"
- #include "iscsi_err.h"
- 
-+// GLOB_ONLYDIR is not defined under musl
-+#ifndef GLOB_ONLYDIR
-+#define GLOB_ONLYDIR	0x100
-+#endif
-+
- #define IDBM_HIDE	0    /* Hide parameter when print. */
- #define IDBM_SHOW	1    /* Show parameter when print. */
- #define IDBM_MASKED	2    /* Show "stars" instead of real value when print */
--- 
-2.41.0
-

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.8.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.8.ebuild
deleted file mode 100644
index 93b8afb21848..000000000000
--- a/sys-block/open-iscsi/open-iscsi-2.1.8.ebuild
+++ /dev/null
@@ -1,117 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit flag-o-matic linux-info meson systemd udev
-
-DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
-HOMEPAGE="https://www.open-iscsi.com/"
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="GPL-2"
-SLOT="0/0.2"
-KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~mips ppc ppc64 ~riscv sparc x86"
-IUSE="debug infiniband +tcp rdma systemd"
-REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
-# Tries to write to /run/lock/iscsi etc
-RESTRICT="test"
-
-DEPEND="
-	dev-libs/openssl:=
-	sys-apps/kmod
-	sys-block/open-isns:=
-	sys-kernel/linux-headers
-	infiniband? ( sys-cluster/rdma-core )
-	systemd? ( sys-apps/systemd:= )
-"
-RDEPEND="
-	${DEPEND}
-	sys-fs/lsscsi
-	sys-apps/util-linux
-"
-BDEPEND="virtual/pkgconfig"
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-2.1.7-fix_bitwise.patch
-)
-
-pkg_setup() {
-	linux-info_pkg_setup
-
-	if kernel_is -lt 2 6 16; then
-		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
-	fi
-
-	# Needs to be done, as iscsid currently only starts, when having the iSCSI
-	# support loaded as module. Kernel builtin options don't work. See this for
-	# more information:
-	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
-	# If there's a new release, check whether this is still valid!
-	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
-	RDMA_MODULES="INFINIBAND_ISER"
-	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
-	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
-	if linux_config_exists; then
-		if use tcp; then
-			for module in ${TCP_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use infiniband; then
-			for module in ${INFINIBAND_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use rdma; then
-			for module in ${RDMA_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
-			done
-		fi
-	fi
-}
-
-src_configure() {
-	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
-
-	local emesonargs=(
-		-Dsystemddir="$(systemd_get_utildir)"
-		-Drulesdir="$(get_udevdir)"/rules.d
-		$(meson_use !systemd no_systemd)
-	)
-
-	meson_src_configure
-}
-
-src_install() {
-	meson_src_install
-
-	# Upstream make is not deterministic, per bug #601514
-	rm -f "${ED}"/etc/initiatorname.iscsi
-
-	docinto test/
-	dodoc $(find test -maxdepth 1 -type f ! -name ".*")
-
-	insinto /etc/iscsi
-	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
-
-	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
-	newinitd "${FILESDIR}"/iscsid-init.d iscsid
-
-	keepdir /var/db/iscsi
-	fperms 700 /var/db/iscsi
-	fperms 600 /etc/iscsi/iscsid.conf
-}
-
-pkg_postinst() {
-	in='/etc/iscsi/initiatorname.iscsi'
-	if [[ ! -f "${EROOT}${in}" ]] && [[ -f "${EROOT}${in}.example" ]] ; then
-		{
-		  cat "${EROOT}${in}.example"
-		  echo "# InitiatorName generated by ${CATEGORY}/${PF} at $(date -uR)"
-		  echo "InitiatorName=$(${ROOT}/usr/sbin/iscsi-iname)"
-		} >> "${EROOT}${in}.tmp" && mv -f "${EROOT}${in}.tmp" "${EROOT}${in}"
-	fi
-
-	udev_reload
-}

diff --git a/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild b/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild
deleted file mode 100644
index d5126eaad442..000000000000
--- a/sys-block/open-iscsi/open-iscsi-2.1.9.ebuild
+++ /dev/null
@@ -1,120 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit flag-o-matic linux-info meson systemd udev
-
-DESCRIPTION="A performant, transport independent, multi-platform implementation of RFC3720"
-HOMEPAGE="https://www.open-iscsi.com/"
-SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="LGPL-3+ GPL-2+"
-SLOT="0/0.2"
-KEYWORDS="~alpha amd64 arm arm64 ~ia64 ~mips ppc ppc64 ~riscv sparc x86"
-IUSE="debug infiniband +tcp rdma systemd"
-REQUIRED_USE="infiniband? ( rdma ) || ( rdma tcp )"
-# Tries to write to /run/lock/iscsi etc
-RESTRICT="test"
-
-DEPEND="
-	dev-libs/openssl:=
-	sys-apps/kmod
-	sys-block/open-isns:=
-	sys-kernel/linux-headers
-	infiniband? ( sys-cluster/rdma-core )
-	systemd? ( sys-apps/systemd:= )
-"
-RDEPEND="
-	${DEPEND}
-	sys-fs/lsscsi
-	sys-apps/util-linux
-"
-BDEPEND="virtual/pkgconfig"
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-2.1.7-fix_bitwise.patch
-	"${FILESDIR}"/${P}-usr-idbm.c-fix-musl-build-426.patch
-)
-
-pkg_setup() {
-	linux-info_pkg_setup
-
-	if kernel_is -lt 2 6 16; then
-		die "Sorry, your kernel must be 2.6.16-rc5 or newer!"
-	fi
-
-	# Needs to be done, as iscsid currently only starts, when having the iSCSI
-	# support loaded as module. Kernel builtin options don't work. See this for
-	# more information:
-	# https://groups.google.com/group/open-iscsi/browse_thread/thread/cc10498655b40507/fd6a4ba0c8e91966
-	# If there's a new release, check whether this is still valid!
-	TCP_MODULES="SCSI_ISCSI_ATTRS ISCSI_TCP"
-	RDMA_MODULES="INFINIBAND_ISER"
-	INFINIBAND_MODULES="INFINIBAND_IPOIB INIBAND_USER_MAD INFINIBAND_USER_ACCESS"
-	CONFIG_CHECK_MODULES="tcp? ( ${TCP_MODULES} ) rdma? ( ${RDMA_MODULES} ) infiniband? ( ${INFINIBAND_MODULES} )"
-	if linux_config_exists; then
-		if use tcp; then
-			for module in ${TCP_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use infiniband; then
-			for module in ${INFINIBAND_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"
-		done
-		fi
-		if use rdma; then
-			for module in ${RDMA_MODULES}; do
-				linux_chkconfig_module ${module} || ewarn "${module} needs to be built as module (builtin doesn't work)"$
-			done
-		fi
-	fi
-}
-
-src_configure() {
-	use debug && append-cppflags -DDEBUG_TCP -DDEBUG_SCSI
-
-	# TODO: Make sys-block/open-isns optional if useful? There's an upstream
-	# build system option for this already as of 2.1.9.
-	local emesonargs=(
-		-Dsystemddir="$(systemd_get_utildir)"
-		-Drulesdir="$(get_udevdir)"/rules.d
-		$(meson_use !systemd no_systemd)
-	)
-
-	meson_src_configure
-}
-
-src_install() {
-	meson_src_install
-
-	# Upstream make is not deterministic, per bug #601514
-	rm -f "${ED}"/etc/initiatorname.iscsi
-
-	docinto test/
-	dodoc $(find test -maxdepth 1 -type f ! -name ".*")
-
-	insinto /etc/iscsi
-	newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example
-
-	newconfd "${FILESDIR}"/iscsid-conf.d iscsid
-	newinitd "${FILESDIR}"/iscsid-init.d iscsid
-
-	keepdir /var/db/iscsi
-	fperms 700 /var/db/iscsi
-	fperms 600 /etc/iscsi/iscsid.conf
-}
-
-pkg_postinst() {
-	in='/etc/iscsi/initiatorname.iscsi'
-	if [[ ! -f "${EROOT}${in}" ]] && [[ -f "${EROOT}${in}.example" ]] ; then
-		{
-		  cat "${EROOT}${in}.example"
-		  echo "# InitiatorName generated by ${CATEGORY}/${PF} at $(date -uR)"
-		  echo "InitiatorName=$(${ROOT}/usr/sbin/iscsi-iname)"
-		} >> "${EROOT}${in}.tmp" && mv -f "${EROOT}${in}.tmp" "${EROOT}${in}"
-	fi
-
-	udev_reload
-}


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2024-09-04 14:31 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-28 19:53 [gentoo-commits] repo/gentoo:master commit in: sys-block/open-iscsi/, sys-block/open-iscsi/files/ Sam James
  -- strict thread matches above, loose matches on Subject: below --
2024-09-04 14:31 James Le Cuirot
2023-12-22  8:46 Sam James
2022-06-02 18:21 Matthias Maier
2021-05-23 12:14 David Seifert
2020-05-03 20:35 Thomas Deutschmann
2019-05-23  8:09 Lars Wendler
2019-05-06 12:54 Lars Wendler
2017-01-02 18:50 Matt Thode
2017-01-02 16:55 Matt Thode
2015-12-18  0:00 Mike Frysinger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox