summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConrad Kostecki <conikost@gentoo.org>2020-08-25 12:32:58 +0200
committerConrad Kostecki <conikost@gentoo.org>2020-08-25 12:36:12 +0200
commita0afd56d1ce1f0d09006e62f182646657fb0f7b0 (patch)
tree3207e8d69c59bfe896ec26ba1bda058ad844b379
parentnet-dns/bind-tools: Stabilize 9.16.6 arm, #738250 (diff)
downloadgentoo-a0afd56d.tar.gz
gentoo-a0afd56d.tar.bz2
gentoo-a0afd56d.zip
net-misc/sntpd: fix creation of pidfile
Also added missing systemd inherit. Closes: https://bugs.gentoo.org/738870 Closes: https://bugs.gentoo.org/738894 Package-Manager: Portage-3.0.4, Repoman-3.0.1 Signed-off-by: Conrad Kostecki <conikost@gentoo.org>
-rw-r--r--net-misc/sntpd/files/sntpd.initd-r114
-rw-r--r--net-misc/sntpd/sntpd-3.0-r1.ebuild35
2 files changed, 49 insertions, 0 deletions
diff --git a/net-misc/sntpd/files/sntpd.initd-r1 b/net-misc/sntpd/files/sntpd.initd-r1
new file mode 100644
index 000000000000..ebe857af4afd
--- /dev/null
+++ b/net-misc/sntpd/files/sntpd.initd-r1
@@ -0,0 +1,14 @@
+#!/sbin/openrc-run
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+name="sntpd"
+pidfile="/run/sntpd.pid"
+
+command="/usr/sbin/sntpd"
+command_args="-n ${SNTPD_OPTS}"
+command_background="true"
+
+depend() {
+ use net dns logger
+}
diff --git a/net-misc/sntpd/sntpd-3.0-r1.ebuild b/net-misc/sntpd/sntpd-3.0-r1.ebuild
new file mode 100644
index 000000000000..5edf61d7f025
--- /dev/null
+++ b/net-misc/sntpd/sntpd-3.0-r1.ebuild
@@ -0,0 +1,35 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit systemd
+
+DESCRIPTION="A NTP (RFC-1305 and RFC-4330) client and server for unix-alike systems"
+HOMEPAGE="https://github.com/troglobit/sntpd"
+SRC_URI="https://github.com/troglobit/${PN}/releases/download/v${PV}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
+IUSE="adjtimex systemd"
+
+RDEPEND="systemd? ( sys-apps/systemd )"
+DEPEND="${RDEPEND}"
+
+src_configure() {
+ local myeconfargs=(
+ $(use_with adjtimex)
+ $(use_with systemd systemd $(systemd_get_systemunitdir))
+ --with-ntpclient
+ )
+
+ econf "${myeconfargs[@]}"
+}
+
+src_install() {
+ default
+
+ newinitd "${FILESDIR}"/sntpd.initd-r1 sntpd
+ newconfd "${FILESDIR}"/sntpd.confd sntpd
+}