[net-misc/oidentd] bump, probably doesn't build

This commit is contained in:
Robert Förster 2019-01-10 16:00:00 +01:00
parent 160b2b5211
commit 557750e63d
5 changed files with 116 additions and 0 deletions

View File

@ -0,0 +1,2 @@
DIST oidentd-2.0.8.tar.gz 212354 BLAKE2B 46f4c4478822e832885f5f38a2ab5b2132ff5c1e5071fd1dc6050e55992d50bd96be096064996853af69d16316e6aff648c5320714b53b60c038cc9aaedfedda SHA512 86229a4ef9892121c25a7140616e180f862ca34b73ea3ad9f0fbb008f657abb17e9f14c2c25ae14c14bfc14bf1ea10b50fd68318631a9c52227bbfd6e6d43288
DIST oidentd-2.2.2.tar.gz 260185 BLAKE2B a719413751280d44e134245793c4a88d93dd573d7d85895e341040c2d83a7b201f21f499b931c27e5c0f1d7d0957d730b2cda698ef98b74755e2ca1958457579 SHA512 c5c5040f8955e61e8a7cddd310501d24c3b2a3818e0cd122db85c03dc5b2b18ca7ea4e7edb420df3ad81558a25d4b31c1fea97684a9f53c71c9159014f84678d

View File

@ -0,0 +1,40 @@
#!/sbin/openrc-run
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
depend() {
need net
}
check_config() {
if [ -z "${USER}" ]
then
eerror "Please set \$USER in /etc/conf.d/oidentd!"
return 1
fi
if [ -z "${GROUP}" ]
then
eerror "Please set \$GROUP in /etc/conf.d/oidentd!"
return 1
fi
if [ "$(sysctl -n security.bsd.see_other_uids 2>/dev/null)" = "0" ]; then
eerror "${SVCNAME} cannot work if the sysctl security.bsd.see_other_uids is 0"
return 1
fi
}
start() {
check_config || return 1
ebegin "Starting oidentd"
OPTIONS="${OPTIONS} -u ${USER} -g ${GROUP}"
start-stop-daemon --start --quiet --exec /usr/sbin/oidentd -- $OPTIONS
eend $?
}
stop() {
ebegin "Stopping oidentd"
start-stop-daemon --stop --quiet --exec /usr/sbin/oidentd
eend $?
}

View File

@ -0,0 +1,4 @@
# oidentd start-up options
USER="oidentd"
GROUP="oidentd"
OPTIONS=""

View File

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>Dessa@gmake.de</email>
<name>Robert Förster</name>
</maintainer>
<maintainer type="project">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<use>
<flag name="masquerade">Enable support for masqueraded/NAT connections</flag>
</use>
<upstream>
<remote-id type="github">janikrabe/oidentd</remote-id>
</upstream>
</pkgmetadata>

View File

@ -0,0 +1,52 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit systemd user
DESCRIPTION="Another (RFC1413 compliant) ident daemon"
HOMEPAGE="https://oidentd.janikrabe.com/"
SRC_URI="https://files.janikrabe.com/pub/${PN}/releases/${PV}/${P}.tar.xz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
IUSE="debug ipv6 masquerade selinux"
DEPEND="masquerade? (
net-libs/libnetfilter_conntrack
sys-libs/libcap-ng )"
RDEPEND="${DEPEND}
selinux? ( sec-policy/selinux-oident )"
pkg_setup() {
enewgroup oidentd
enewuser oidentd -1 -1 -1 oidentd
}
src_configure() {
local myconf=(
$(use_enable debug)
$(use_enable ipv6)
$(use_enable masquerade libnfct)
$(use_enable masquerade masq)
$(use_enable masquerade nat)
)
econf "${myconf[@]}"
}
src_install() {
default
newinitd "${FILESDIR}"/${PN}-2.0.7-init ${PN}
newconfd "${FILESDIR}"/${PN}-2.2.2-confd ${PN}
systemd_dounit contrib/systemd/${PN}@.service
systemd_dounit contrib/systemd/${PN}.socket
systemd_dounit contrib/systemd/${PN}.service
sed -i '/ExecStart/ s|$| -u oidentd -g oidentd|' "${D}$(systemd_get_systemunitdir)"/${PN}.service || die
sed -i '/ExecStart/ s|$| -u oidentd -g oidentd|' "${D}$(systemd_get_systemunitdir)"/${PN}@.service || die
}