diff options
author | V3n3RiX <venerix@koprulu.sector> | 2023-10-17 16:03:04 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2023-10-17 16:03:04 +0100 |
commit | 29ef84a753ab20dbbb228238713a3c7443c6520e (patch) | |
tree | ebe889f9f8817c5c6601a6dbfd0b12d537b4e91d /sys-block/tgt/tgt-1.0.88-r1.ebuild | |
parent | cf89ca044e37f79e2329552cda857215f9824e11 (diff) |
gentoo auto-resync : 17:10:2023 - 16:03:04
Diffstat (limited to 'sys-block/tgt/tgt-1.0.88-r1.ebuild')
-rw-r--r-- | sys-block/tgt/tgt-1.0.88-r1.ebuild | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/sys-block/tgt/tgt-1.0.88-r1.ebuild b/sys-block/tgt/tgt-1.0.88-r1.ebuild new file mode 100644 index 000000000000..3acece87b340 --- /dev/null +++ b/sys-block/tgt/tgt-1.0.88-r1.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit toolchain-funcs systemd + +DESCRIPTION="Linux SCSI target framework (tgt)" +HOMEPAGE="https://github.com/fujita/tgt" +SRC_URI="https://github.com/fujita/tgt/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 arm64 ~hppa ~ia64 ~loong ~ppc ppc64 ~riscv ~sparc x86" +IUSE="infiniband rbd selinux" + +DEPEND=" + app-text/docbook-xsl-stylesheets + dev-libs/libxslt + dev-perl/Config-General + rbd? ( sys-cluster/ceph ) + infiniband? ( sys-cluster/rdma-core ) +" +RDEPEND=" + ${DEPEND} + dev-libs/libaio + sys-apps/sg3_utils + selinux? ( sec-policy/selinux-tgtd ) +" + +pkg_setup() { + tc-export CC +} + +src_prepare() { + default + sed -i -e 's:\($(CC)\) $^:\1 $(LDFLAGS) $^:' usr/Makefile || die + # make sure xml docs are generated before trying to install them + sed -i -e "s@install: @& all @g" doc/Makefile || die + sed -i -e 's|-Werror||g' usr/Makefile || die +} + +src_compile() { + local myconf + use infiniband && myconf="${myconf} ISCSI_RDMA=1" + use rbd && myconf="${myconf} CEPH_RBD=1" + + emake -C usr/ KERNELSRC="${KERNEL_DIR}" ISCSI=1 ${myconf} + emake -C doc +} + +src_install() { + emake install-programs install-scripts install-doc DESTDIR="${D}" docdir=/usr/share/doc/${PF} + newinitd "${FILESDIR}"/tgtd.initd-new tgtd + newconfd "${FILESDIR}"/tgtd.confd-new tgtd + systemd_dounit "${S}"/scripts/tgtd.service + dodir /etc/tgt + keepdir /etc/tgt +} |