From owner-svn-ports-all@FreeBSD.ORG Fri Jun 20 18:41:01 2014 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8EF0F657; Fri, 20 Jun 2014 18:41:01 +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 7C43B2E8F; Fri, 20 Jun 2014 18:41:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s5KIf1dq061023; Fri, 20 Jun 2014 18:41:01 GMT (envelope-from wg@svn.freebsd.org) Received: (from wg@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s5KIf0kY061010; Fri, 20 Jun 2014 18:41:00 GMT (envelope-from wg@svn.freebsd.org) Message-Id: <201406201841.s5KIf0kY061010@svn.freebsd.org> From: William Grzybowski Date: Fri, 20 Jun 2014 18:41:00 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r358627 - in head/net/iplog: . 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-all@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Jun 2014 18:41:01 -0000 Author: wg Date: Fri Jun 20 18:41:00 2014 New Revision: 358627 URL: http://svnweb.freebsd.org/changeset/ports/358627 QAT: https://qat.redports.org/buildarchive/r358627/ Log: net/iplog: support stage and use @sample PR: 190095 Submitted by: maintainer Added: head/net/iplog/pkg-install (contents, props changed) Modified: head/net/iplog/Makefile head/net/iplog/files/iplog.in head/net/iplog/pkg-deinstall head/net/iplog/pkg-plist Modified: head/net/iplog/Makefile ============================================================================== --- head/net/iplog/Makefile Fri Jun 20 18:37:53 2014 (r358626) +++ head/net/iplog/Makefile Fri Jun 20 18:41:00 2014 (r358627) @@ -14,14 +14,9 @@ USES= gmake GNU_CONFIGURE= yes CPPFLAGS+= -I${LOCALBASE}/include ${PTHREAD_CFLAGS} LDFLAGS+= -L${LOCALBASE}/lib ${PTHREAD_LIBS} -MAN5= iplog.conf.5 -MAN8= iplog.8 USE_RC_SUBR= iplog -SUB_FILES= pkg-message -NO_STAGE= yes -.include post-patch: .for FILE in example-iplog.conf iplog.8 iplog.conf.5 src/iplog.h @${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|g" ${WRKSRC}/${FILE} @@ -29,19 +24,6 @@ post-patch: @${REINPLACE_CMD} -e 's|-pthread||g' ${WRKSRC}/configure post-install: - ${INSTALL_DATA} ${WRKSRC}/example-iplog.conf ${PREFIX}/etc -.if !exists(${PREFIX}/etc/iplog.conf) - ${INSTALL_DATA} ${WRKSRC}/example-iplog.conf ${PREFIX}/etc/iplog.conf -.endif -.if exists(${PREFIX}/etc/iplog.rules) - @${ECHO_MSG} - @${ECHO_MSG} "============================================================================" - @${ECHO_MSG} "Hint: iplog changed its configuration file from ${PREFIX}/etc/iplog.rules" - @${ECHO_MSG} " to ${PREFIX}/etc/iplog.conf" - @${ECHO_MSG} - @${ECHO_MSG} "See ${PREFIX}/etc/example-iplog.conf for an example" - @${ECHO_MSG} "============================================================================" -.endif - @${MKDIR} /var/run/iplog + @${INSTALL_DATA} ${WRKSRC}/example-iplog.conf ${STAGEDIR}${PREFIX}/etc/iplog.conf.sample -.include +.include Modified: head/net/iplog/files/iplog.in ============================================================================== --- head/net/iplog/files/iplog.in Fri Jun 20 18:37:53 2014 (r358626) +++ head/net/iplog/files/iplog.in Fri Jun 20 18:41:00 2014 (r358627) @@ -18,6 +18,7 @@ name="iplog" rcvar=iplog_enable +start_precmd="install -d /var/run/${name}" command=%%PREFIX%%/sbin/${name} pidfile=/var/run/${name}/${name}.pid Modified: head/net/iplog/pkg-deinstall ============================================================================== --- head/net/iplog/pkg-deinstall Fri Jun 20 18:37:53 2014 (r358626) +++ head/net/iplog/pkg-deinstall Fri Jun 20 18:41:00 2014 (r358627) @@ -1,2 +1,18 @@ #!/bin/sh -rm -rf /var/run/iplog +# +# $FreeBSD: $ +# + +#set -vx + +PKG_PREFIX=${PKG_PREFIX:=/usr/local} + +case $2 in + DEINSTALL) + : + ;; + POST-DEINSTALL) + /bin/rm -rf /var/run/iplog + ;; + +esac Added: head/net/iplog/pkg-install ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/iplog/pkg-install Fri Jun 20 18:41:00 2014 (r358627) @@ -0,0 +1,23 @@ +#!/bin/sh +# +# $FreeBSD: $ +# + +PKG_PREFIX=${PKG_PREFIX:=/usr/local} + +case $2 in + PRE-INSTALL) + : + ;; + POST-INSTALL) + if [ -e ${PKG_PREFIX}/etc/iplog.rules ]; then + echo + echo "============================================================================" + echo "Hint: iplog changed its configuration file from ${PKG_PREFIX}/etc/iplog.rules" + echo " to ${PKG_PREFIX}/etc/iplog.conf" + echo + echo "See ${PKG_PREFIX}/etc/iplog.conf.sample for an example" + echo "============================================================================" + fi + ;; +esac Modified: head/net/iplog/pkg-plist ============================================================================== --- head/net/iplog/pkg-plist Fri Jun 20 18:37:53 2014 (r358626) +++ head/net/iplog/pkg-plist Fri Jun 20 18:41:00 2014 (r358627) @@ -1,4 +1,4 @@ sbin/iplog -@unexec if cmp -s %D/etc/iplog.conf %D/etc/example-iplog.conf; then rm -f %D/etc/iplog.conf; fi -etc/example-iplog.conf -@exec test -f %B/iplog.conf || cp %B/%f %B/iplog.conf +@sample etc/iplog.conf.sample +man/man5/iplog.conf.5.gz +man/man8/iplog.8.gz