Date: Thu, 23 Aug 2012 20:43:07 +0000 (UTC) From: Doug Barton <dougb@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r303035 - in head/misc/upclient: . files Message-ID: <201208232043.q7NKh8Z9091483@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dougb Date: Thu Aug 23 20:43:07 2012 New Revision: 303035 URL: http://svn.freebsd.org/changeset/ports/303035 Log: Fix post r302141: The files in USE_RC_SUBR are already included in SUB_FILES While I'm here, reformat the rc.d script to match conventions, and remove some cruft from the Makefile. Modified: head/misc/upclient/Makefile head/misc/upclient/files/upclient.in Modified: head/misc/upclient/Makefile ============================================================================== --- head/misc/upclient/Makefile Thu Aug 23 20:36:09 2012 (r303034) +++ head/misc/upclient/Makefile Thu Aug 23 20:43:07 2012 (r303035) @@ -14,24 +14,18 @@ MASTER_SITES= http://uptimes.hostingwire DISTNAME= ${PORTNAME}-${PORTVERSION:R}${PORTVERSION:E} MAINTAINER= ports@FreeBSD.org -COMMENT= The Uptimes project client - -# Global variables -# +COMMENT= Uptimes project client USE_GETTEXT= yes USE_RC_SUBR= upclient ALL_TARGET= bsd BUILD_WRKSRC= ${WRKSRC}/src -SUB_FILES= pkg-message upclient.sh -PKGMESSAGE= ${WRKDIR}/pkg-message upclient.sh +SUB_FILES= pkg-message +PKGMESSAGE= ${WRKDIR}/pkg-message MAN8= upclient.8 -# Local variables -# - REINPLACE_SUB= PREFIX=${PREFIX} LOCALBASE=${LOCALBASE} DOC_FILES= AUTHORS COPYING FAQ HISTORY INSTALL README TODO @@ -40,26 +34,17 @@ DOC_FILES+= HISTORY-BETA .include <bsd.port.pre.mk> -# Post-extract -# - post-extract: rename-doc rename-doc: @${MV} ${WRKSRC}/doc/"Uptimes Protocol 5" ${WRKSRC}/doc/UptimesProtocol5 -# Post-patch -# - post-patch: @${REINPLACE_CMD} ${REINPLACE_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \ ${WRKSRC}/scripts/upchk ${WRKSRC}/scripts/clientchk \ ${WRKSRC}/src/Makefile ${REINPLACE_CMD} -e 's/CC=gcc/CC=${CC}/' ${WRKSRC}/src/Makefile -# Install -# - do-install: install-program install-man install-sample install-script \ install-locale @@ -82,9 +67,6 @@ install-script: install-locale: @cd ${WRKSRC}/src; ${MAKE} install-locales -# Post-install -# - post-install: install-conf install-doc display-message install-conf: Modified: head/misc/upclient/files/upclient.in ============================================================================== --- head/misc/upclient/files/upclient.in Thu Aug 23 20:36:09 2012 (r303034) +++ head/misc/upclient/files/upclient.in Thu Aug 23 20:43:07 2012 (r303035) @@ -1,15 +1,32 @@ #!/bin/sh -# + # $FreeBSD$ # # PROVIDE: upclient -# REQUIRE: DAEMON +# REQUIRE: LOGIN +# KEYWORD: shutdown # # Add the following lines to /etc/rc.conf to enable upclient: # # upclient_enable="YES" # upclient_flags="<set as needed>" +. /etc/rc.subr + +name=upclient +rcvar=upclient_enable + +load_rc_config ${name} + +upclient_enable="${upclient_enable:-NO}" + +command=%%PREFIX%%/sbin/${name} +pidfile=/var/run/${name}.pid +configfile=%%PREFIX%%/etc/${name}.conf +required_files=${configfile} +samplefile=${configfile}.sample +start_precmd=${name}_precmd + upclient_precmd () { ws=" " @@ -25,26 +42,6 @@ upclient_precmd () kw="IdleTime|OS|(OS|CPU)Level" egrep -qs "^[$ws]*Send($kw)[$ws]*=" ${configfile} && err 1 "${configfile} needs to be updated from ${samplefile}." - - : } -upclient_enable="${upclient_enable-NO}" - -. /etc/rc.subr - -name=upclient -rcvar=upclient_enable - -# private -configfile=%%PREFIX%%/etc/${name}.conf -samplefile=${configfile}.sample - -# public -command=%%PREFIX%%/sbin/${name} -pidfile=/var/run/${name}.pid -required_files=${configfile} -start_precmd=${name}_precmd - -load_rc_config ${name} run_rc_command "$1"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201208232043.q7NKh8Z9091483>