From owner-svn-ports-head@FreeBSD.ORG Mon Dec 22 03:55:45 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0850C54B; Mon, 22 Dec 2014 03:55:45 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CE3752E11; Mon, 22 Dec 2014 03:55:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id sBM3tiJU068939; Mon, 22 Dec 2014 03:55:44 GMT (envelope-from koobs@FreeBSD.org) Received: (from koobs@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id sBM3ti4o068937; Mon, 22 Dec 2014 03:55:44 GMT (envelope-from koobs@FreeBSD.org) Message-Id: <201412220355.sBM3ti4o068937@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: koobs set sender to koobs@FreeBSD.org using -f From: Kubilay Kocak Date: Mon, 22 Dec 2014 03:55:44 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r375206 - in head/net/ntimed: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Dec 2014 03:55:45 -0000 Author: koobs Date: Mon Dec 22 03:55:43 2014 New Revision: 375206 URL: https://svnweb.freebsd.org/changeset/ports/375206 QAT: https://qat.redports.org/buildarchive/r375206/ Log: net/ntimed: Add rc startup script - Add ntimed rc script - Tweak GH_PROJECT, remove WRKSRC override accordingly - Remove trailing newline (portlint) Approved by: maintainer Added: head/net/ntimed/files/ head/net/ntimed/files/ntimed.in (contents, props changed) Modified: head/net/ntimed/Makefile Modified: head/net/ntimed/Makefile ============================================================================== --- head/net/ntimed/Makefile Mon Dec 22 01:02:56 2014 (r375205) +++ head/net/ntimed/Makefile Mon Dec 22 03:55:43 2014 (r375206) @@ -3,6 +3,7 @@ PORTNAME= ntimed PORTVERSION= 0.0.2014.12.21 +PORTREVISION= 1 CATEGORIES= net MAINTAINER= feld@FreeBSD.org @@ -10,14 +11,14 @@ COMMENT= Network time synchronization cl LICENSE= BSD2CLAUSE +USE_RC_SUBR= ntimed + USE_GITHUB= yes GH_ACCOUNT= bsdphk -GH_PROJECT= ntimed +GH_PROJECT= Ntimed GH_COMMIT= f3810d7 GH_TAGNAME= ${GH_COMMIT} -WRKSRC= ${WRKDIR}/${GH_ACCOUNT}-Ntimed-${GH_COMMIT} - PLIST_FILES= sbin/ntimed-client .include @@ -29,4 +30,3 @@ do-install: ${INSTALL_PROGRAM} ${WRKSRC}/ntimed-client ${STAGEDIR}/${LOCALBASE}/sbin/ .include - Added: head/net/ntimed/files/ntimed.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/ntimed/files/ntimed.in Mon Dec 22 03:55:43 2014 (r375206) @@ -0,0 +1,38 @@ +#!/bin/sh +# +# Author: Mark Felder +# +# $FreeBSD$ +# + +# PROVIDE: ntimed +# REQUIRE: LOGIN +# KEYWORD: shutdown + +# Add the following lines to /etc/rc.conf to enable ntimed: +# ntimed_enable="YES" +# ntimed_flags="" + +. /etc/rc.subr + +name=ntimed +rcvar=ntimed_enable + +load_rc_config $name + +: ${ntimed_enable:=NO} +: ${ntimed_flags:="0.freebsd.pool.ntp.org"} + +start_precmd=ntimed_prestart +pidfile=/var/run/ntimed.pid +procname="/usr/local/sbin/ntimed-client" +command=/usr/sbin/daemon +command_args=" -p ${pidfile} ${procname} ${ntimed_flags}" + +ntimed_prestart() +{ + # Have to empty rc_flags so they don't get passed to daemon(8) + rc_flags="" +} + +run_rc_command "$1"