pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/net/openntpd net/openntpd: make the rc script set the ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/e93edfb00090
branches:  trunk
changeset: 455761:e93edfb00090
user:      dholland <dholland%pkgsrc.org@localhost>
date:      Sat Jul 10 18:32:15 2021 +0000

description:
net/openntpd: make the rc script set the pidfile.

Seems the daemon writes no pid file unless explicitly told where.
Fixes PR 55244. PKGREVISION -> 1.

diffstat:

 net/openntpd/Makefile          |  3 ++-
 net/openntpd/files/openntpd.sh |  9 ++++++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diffs (38 lines):

diff -r 341480b21ca8 -r e93edfb00090 net/openntpd/Makefile
--- a/net/openntpd/Makefile     Sat Jul 10 17:14:14 2021 +0000
+++ b/net/openntpd/Makefile     Sat Jul 10 18:32:15 2021 +0000
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.44 2016/06/15 05:40:21 wiz Exp $
+# $NetBSD: Makefile,v 1.45 2021/07/10 18:32:15 dholland Exp $
 
 DISTNAME=              openntpd-6.0p1
+PKGREVISION=           1
 CATEGORIES=            net
 MASTER_SITES=          ${MASTER_SITE_OPENBSD:=OpenNTPD/}
 
diff -r 341480b21ca8 -r e93edfb00090 net/openntpd/files/openntpd.sh
--- a/net/openntpd/files/openntpd.sh    Sat Jul 10 17:14:14 2021 +0000
+++ b/net/openntpd/files/openntpd.sh    Sat Jul 10 18:32:15 2021 +0000
@@ -1,6 +1,6 @@
 #!@RCD_SCRIPTS_SHELL@
 #
-# $NetBSD: openntpd.sh,v 1.1.1.1 2004/07/19 19:17:25 xtraeme Exp $
+# $NetBSD: openntpd.sh,v 1.2 2021/07/10 18:32:15 dholland Exp $
 #
 
 # PROVIDE: openntpd
@@ -12,7 +12,14 @@
 name="ntpd"
 rcvar="openntpd"
 command="@PREFIX@/sbin/${name}"
+pidfile="/var/run/${name}.pid"
 required_files="@PKG_SYSCONFDIR@/ntpd.conf"
+start_precmd="$openntpd_precmd"
+
+openntpd_precmd()
+{
+       rc_flags="-p ${pidfile} $rc_flags"
+}
 
 load_rc_config $name
 run_rc_command "$1"



Home | Main Index | Thread Index | Old Index