Honour chronyd in rc.conf. Prior to this, chronyd would run regardless and could not be disabled. Bump PKGREVISIONdiff -r1.32 -r1.33 pkgsrc/net/chrony/Makefile
(sborrill)
@@ -1,17 +1,17 @@ | @@ -1,17 +1,17 @@ | |||
1 | # $NetBSD: Makefile,v 1.32 2015/08/18 07:31:14 wiz Exp $ | 1 | # $NetBSD: Makefile,v 1.33 2015/10/08 09:47:33 sborrill Exp $ | |
2 | 2 | |||
3 | DISTNAME= chrony-1.31.1 | 3 | DISTNAME= chrony-1.31.1 | |
4 | PKGREVISION= 2 | 4 | PKGREVISION= 3 | |
5 | CATEGORIES= net | 5 | CATEGORIES= net | |
6 | MASTER_SITES= http://download.tuxfamily.org/chrony/ | 6 | MASTER_SITES= http://download.tuxfamily.org/chrony/ | |
7 | 7 | |||
8 | MAINTAINER= hannken@NetBSD.org | 8 | MAINTAINER= hannken@NetBSD.org | |
9 | HOMEPAGE= http://chrony.tuxfamily.org/ | 9 | HOMEPAGE= http://chrony.tuxfamily.org/ | |
10 | COMMENT= Daemon for maintaining the accuracy of computer clocks | 10 | COMMENT= Daemon for maintaining the accuracy of computer clocks | |
11 | LICENSE= gnu-gpl-v2 | 11 | LICENSE= gnu-gpl-v2 | |
12 | 12 | |||
13 | USE_TOOLS+= gmake | 13 | USE_TOOLS+= gmake | |
14 | HAS_CONFIGURE= YES | 14 | HAS_CONFIGURE= YES | |
15 | BUILD_DEFS+= VARBASE | 15 | BUILD_DEFS+= VARBASE | |
16 | CONFIGURE_ARGS+= --prefix=${PREFIX} | 16 | CONFIGURE_ARGS+= --prefix=${PREFIX} | |
17 | CONFIGURE_ARGS+= --mandir=${PREFIX}/${PKGMANDIR} | 17 | CONFIGURE_ARGS+= --mandir=${PREFIX}/${PKGMANDIR} |
@@ -1,23 +1,24 @@ | @@ -1,23 +1,24 @@ | |||
1 | #!@RCD_SCRIPTS_SHELL@ | 1 | #!@RCD_SCRIPTS_SHELL@ | |
2 | # | 2 | # | |
3 | # $NetBSD: chronyd.sh,v 1.5 2013/08/16 08:30:20 hannken Exp $ | 3 | # $NetBSD: chronyd.sh,v 1.6 2015/10/08 09:47:33 sborrill Exp $ | |
4 | # | 4 | # | |
5 | # PROVIDE: chronyd | 5 | # PROVIDE: chronyd | |
6 | # REQUIRE: DAEMON | 6 | # REQUIRE: DAEMON | |
7 | 7 | |||
8 | . /etc/rc.subr | 8 | . /etc/rc.subr | |
9 | 9 | |||
10 | name="chronyd" | 10 | name="chronyd" | |
11 | rcvar="$name" | |||
11 | command="@PREFIX@/sbin/${name}" | 12 | command="@PREFIX@/sbin/${name}" | |
12 | pidfile="@VARBASE@/run/${name}.pid" | 13 | pidfile="@VARBASE@/run/${name}.pid" | |
13 | required_files="@PKG_SYSCONFDIR@/chrony.conf" | 14 | required_files="@PKG_SYSCONFDIR@/chrony.conf" | |
14 | extra_commands="online offline" | 15 | extra_commands="online offline" | |
15 | online_cmd="chronyd_online" | 16 | online_cmd="chronyd_online" | |
16 | online_precmd="chronyd_precmd" | 17 | online_precmd="chronyd_precmd" | |
17 | offline_cmd="chronyd_offline" | 18 | offline_cmd="chronyd_offline" | |
18 | offline_precmd="chronyd_precmd" | 19 | offline_precmd="chronyd_precmd" | |
19 | 20 | |||
20 | chronyd_precmd() | 21 | chronyd_precmd() | |
21 | { | 22 | { | |
22 | local id kfile | 23 | local id kfile | |
23 | id=`awk '$1 == "commandkey" { print $2 }' @PKG_SYSCONFDIR@/chrony.conf` | 24 | id=`awk '$1 == "commandkey" { print $2 }' @PKG_SYSCONFDIR@/chrony.conf` |