From 56bd759df1d0c750a065b8c845e93d5dfa6b549d Mon Sep 17 00:00:00 2001 From: "Robin H. Johnson" Date: Sat, 8 Aug 2015 13:49:04 -0700 Subject: proj/gentoo: Initial commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson X-Thanks: Alec Warner - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring - wrote much python to improve cvs2svn X-Thanks: Rich Freeman - validation scripts X-Thanks: Patrick Lauer - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed --- sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild | 105 ++++++++++++++++++++++ 1 file changed, 105 insertions(+) create mode 100644 sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild (limited to 'sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild') diff --git a/sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild b/sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild new file mode 100644 index 000000000000..a4244e993024 --- /dev/null +++ b/sys-block/open-iscsi/open-iscsi-2.0.872-r2.ebuild @@ -0,0 +1,105 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=2 +inherit versionator linux-info eutils flag-o-matic toolchain-funcs + +DESCRIPTION="Open-iSCSI is a high performance, transport independent, multi-platform implementation of RFC3720" +HOMEPAGE="http://www.open-iscsi.org/" +MY_PV="${PN}-$(replace_version_separator 2 "-" $MY_PV)" +SRC_URI="http://www.open-iscsi.org/bits/${MY_PV}.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-apps/util-linux" + +S="${WORKDIR}/${MY_PV}" + +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: + # http://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() { + export EPATCH_OPTS="-d${S}" + epatch "${FILESDIR}"/${PN}-2.0.872-makefile-cleanup.patch + epatch "${FILESDIR}"/${P}-glibc212.patch + epatch "${FILESDIR}"/${P}-dont-call-configure.patch + epatch "${FILESDIR}"/${P}-ldflags.patch + epatch "${FILESDIR}"/${P}-isns-slp.patch + epatch "${FILESDIR}"/${PN}-2.0.872-makefile-cleanup-pass2.patch +} + +src_configure() { + cd utils/open-isns || die + econf $(use_with slp) +} + +src_compile() { + use debug && append-flags -DDEBUG_TCP -DDEBUG_SCSI + + einfo "Building userspace" + local SLP_LIBS + use slp && SLP_LIBS="-lslp" + cd "${S}" && \ + KSRC="${KV_DIR}" CFLAGS="" \ + emake \ + OPTFLAGS="${CFLAGS}" SLP_LIBS="${SLP_LIBS}" \ + AR="$(tc-getAR)" CC="$(tc-getCC)" \ + user \ + || die "emake failed" +} + +src_install() { + einfo "Installing userspace" + dosbin usr/iscsid usr/iscsiadm usr/iscsistart || die + + einfo "Installing utilities" + dosbin utils/iscsi-iname utils/iscsi_discovery || die + + einfo "Installing docs" + doman doc/*[1-8] || die + dodoc README THANKS || die + docinto test || die + dodoc test/* || die + + einfo "Installing configuration" + insinto /etc/iscsi + doins etc/iscsid.conf || die + newins "${FILESDIR}"/initiatorname.iscsi initiatorname.iscsi.example || die + insinto /etc/iscsi/ifaces + doins etc/iface.example || die + + newconfd "${FILESDIR}"/${P}-conf.d iscsid || die + newinitd "${FILESDIR}"/${P}-init.d-r1 iscsid || die + + keepdir /var/db/iscsi + fperms 700 /var/db/iscsi || die + fperms 600 /etc/iscsi/iscsid.conf || die +} + +pkg_postinst() { + in='/etc/iscsi/initiatorname.iscsi' + if [ ! -f "${ROOT}${in}" -a -f "${ROOT}${in}.example" ]; then + cp -f "${ROOT}${in}.example" "${ROOT}${in}" + fi +} -- cgit v1.2.3-65-gdbad