From owner-svn-ports-head@FreeBSD.ORG Thu Jun 27 12:36:31 2013 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CF733754; Thu, 27 Jun 2013 12:36:31 +0000 (UTC) (envelope-from wg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C1F9410C7; Thu, 27 Jun 2013 12:36:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r5RCaVs1032715; Thu, 27 Jun 2013 12:36:31 GMT (envelope-from wg@svn.freebsd.org) Received: (from wg@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r5RCaV0Z032713; Thu, 27 Jun 2013 12:36:31 GMT (envelope-from wg@svn.freebsd.org) Message-Id: <201306271236.r5RCaV0Z032713@svn.freebsd.org> From: William Grzybowski Date: Thu, 27 Jun 2013 12:36:31 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r321885 - in head/irc/znc: . 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.14 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: Thu, 27 Jun 2013 12:36:31 -0000 Author: wg Date: Thu Jun 27 12:36:31 2013 New Revision: 321885 URL: http://svnweb.freebsd.org/changeset/ports/321885 Log: irc/znc: add rc.d script - Add rc.d script PR: ports/179190 Approved by: maintainer (timeout) Added: head/irc/znc/files/znc.in (contents, props changed) Modified: head/irc/znc/Makefile Modified: head/irc/znc/Makefile ============================================================================== --- head/irc/znc/Makefile Thu Jun 27 12:27:07 2013 (r321884) +++ head/irc/znc/Makefile Thu Jun 27 12:36:31 2013 (r321885) @@ -14,6 +14,7 @@ LICENSE= GPLv2 FETCH_ARGS= -Fpr GNU_CONFIGURE= yes +USE_RC_SUBR= znc USES= pkgconfig iconv USE_GMAKE= yes WANT_PERL= yes Added: head/irc/znc/files/znc.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/irc/znc/files/znc.in Thu Jun 27 12:36:31 2013 (r321885) @@ -0,0 +1,36 @@ +#!/bin/sh +# +# PROVIDE: znc +# REQUIRE: LOGIN DAEMON +# KEYWORD: shutdown +# +# Add the following line to /etc/rc.conf to enable znc: +# +# znc_enable: Set to NO by default. Set it to YES to enable it. +# znc_conf_dir: Directory where znc configuration +# data is stored. +# Default: %%PREFIX%%/etc/znc +# znc_user: The user account znc runs as what +# you want it to be. It uses 'znc' user by +# default. Do not sets it as empty or it will run +# as root. +# + +. /etc/rc.subr + +name=znc +rcvar=${name}_enable + +command=%%PREFIX%%/bin/znc + +load_rc_config ${name} + +: ${znc_enable:="NO"} +: ${znc_user:="znc"} +: ${znc_conf_dir="%%PREFIX%%/etc/znc"} + +znc_flags=" \ + ${znc_conf_dir:+-d ${znc_conf_dir}} \ + ${znc_flags}" + +run_rc_command "$1"