From owner-svn-ports-head@FreeBSD.ORG Sat Jul 12 18:35:36 2014 Return-Path: Delivered-To: svn-ports-head@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 2B7A2607; Sat, 12 Jul 2014 18:35:36 +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 0CEEA2964; Sat, 12 Jul 2014 18:35:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s6CIZZii048969; Sat, 12 Jul 2014 18:35:35 GMT (envelope-from robak@svn.freebsd.org) Received: (from robak@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s6CIZZgK048964; Sat, 12 Jul 2014 18:35:35 GMT (envelope-from robak@svn.freebsd.org) Message-Id: <201407121835.s6CIZZgK048964@svn.freebsd.org> From: Bartek Rutkowski Date: Sat, 12 Jul 2014 18:35:35 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r361633 - in head/www/polipo: . 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 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: Sat, 12 Jul 2014 18:35:36 -0000 Author: robak Date: Sat Jul 12 18:35:35 2014 New Revision: 361633 URL: http://svnweb.freebsd.org/changeset/ports/361633 QAT: https://qat.redports.org/buildarchive/r361633/ Log: www/polipo: stage and various fixes - Add stage support - Add LICENSE - Fix man pages handling - Fix cache dir handling PR: 185275 Submitted by: Frank Behrens Reviewed by: marino (mentor) Approved by: swills (mentor), blanker (portmgr) Modified: head/www/polipo/Makefile head/www/polipo/files/pkg-install.in head/www/polipo/pkg-plist Modified: head/www/polipo/Makefile ============================================================================== --- head/www/polipo/Makefile Sat Jul 12 18:25:15 2014 (r361632) +++ head/www/polipo/Makefile Sat Jul 12 18:35:35 2014 (r361633) @@ -8,21 +8,14 @@ MASTER_SITES= http://freehaven.net/~chri http://www.sax.de/~frank/polipo4bsd/files/ MAINTAINER= frank@pinky.sax.de -COMMENT= A small and fast caching web proxy +COMMENT= Small and fast caching web proxy -MAN1= polipo.1 +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/COPYING USE_RC_SUBR= polipo -NO_STAGE= yes - -.if defined(NO_PTEXINFO) -ALL_TARGET= polipo -NOPORTDOCS= yes -.else -USES= makeinfo INFO= polipo -.endif .include @@ -33,6 +26,7 @@ SUB_FILES= pkg-message pkg-install pkg-d SUB_LIST+= USER=${PUSER} GROUP=${PGRP} DESTDIR=${DESTDIR} PCONFIGDIR=${PCONFIGDIR} \ PCACHEDIR=${PCACHEDIR} PPIDDIR=${PPIDDIR} PPIDFILE=${PPIDFILE} \ PLOGFILE=${PLOGFILE} +PLIST_SUB+= RESETPREFIX=${PREFIX} # polipo installation options, propagated to install scripts PUSER?= polipo @@ -44,30 +38,19 @@ PPIDFILE= ${PPIDDIR}polipo.pid PLOGFILE?= /var/log/polipo MAKE_ENV+= DISK_CACHE_ROOT=${PCACHEDIR} -pre-install: apply-slist - @PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL - do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/polipo ${PREFIX}/bin/ - ${MKDIR} ${PREFIX}/etc/periodic/daily/ - ${INSTALL_SCRIPT} ${WRKDIR}/400.polipo ${PREFIX}/etc/periodic/daily/ - ${INSTALL_MAN} ${WRKSRC}/polipo.man ${PREFIX}/man/man1/polipo.1 - ${MKDIR} ${PCONFIGDIR} - ${INSTALL_DATA} ${WRKSRC}/config.sample ${PCONFIGDIR} - ${INSTALL_DATA} ${WRKSRC}/forbidden.sample ${PCONFIGDIR} - ${CHGRP} -R ${PGRP} ${PCONFIGDIR} -.if !defined(NO_PTEXINFO) - ${INSTALL_DATA} ${WRKSRC}/polipo.info ${PREFIX}/info/ -.endif -.if !defined(NOPORTDOCS) - ${MKDIR} ${DOCSDIR} - ${INSTALL_DATA} ${WRKSRC}/html/* ${DOCSDIR} - ${INSTALL_DATA} ${WRKSRC}/localindex.html ${DATADIR}/www/index.html - ${CHGRP} -R ${PGRP} ${DATADIR} -.endif + ${INSTALL_PROGRAM} ${WRKSRC}/polipo ${STAGEDIR}${PREFIX}/bin/ + ${MKDIR} ${STAGEDIR}${PREFIX}/etc/periodic/daily/ + ${INSTALL_SCRIPT} ${WRKDIR}/400.polipo ${STAGEDIR}${PREFIX}/etc/periodic/daily/ + ${INSTALL_MAN} ${WRKSRC}/polipo.man ${STAGEDIR}${PREFIX}/man/man1/polipo.1 + ${MKDIR} ${STAGEDIR}${PCONFIGDIR} + ${INSTALL_DATA} ${WRKSRC}/config.sample ${WRKSRC}/forbidden.sample ${STAGEDIR}${PCONFIGDIR} + ${INSTALL_DATA} ${WRKSRC}/polipo.info ${STAGEDIR}${PREFIX}/${INFO_PATH} + ${MKDIR} ${STAGEDIR}${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/html/* ${STAGEDIR}${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/localindex.html ${STAGEDIR}${DATADIR}/www/index.html post-install: - @PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL - @${CAT} ${PKGMESSAGE} + ${MKDIR} ${STAGEDIR}${PCACHEDIR} .include Modified: head/www/polipo/files/pkg-install.in ============================================================================== --- head/www/polipo/files/pkg-install.in Sat Jul 12 18:25:15 2014 (r361632) +++ head/www/polipo/files/pkg-install.in Sat Jul 12 18:35:35 2014 (r361633) @@ -46,7 +46,7 @@ elif [ "$2" = "POST-INSTALL" ]; then if [ ! -d "%%DESTDIR%%$POLIPOCACHE" ]; then mkdir -p "%%DESTDIR%%$POLIPOCACHE" || exit 1 chown "$POLIPOUSER:$POLIPOGROUP" "%%DESTDIR%%$POLIPOCACHE" || exit 1 - chmod 0770 "%%DESTDIR%%$POLIPOCACHE" || exit 1 + chmod ug=rwx,o= "%%DESTDIR%%$POLIPOCACHE" || exit 1 fi if [ ! -d "%%DESTDIR%%$PPIDDIR" ]; then @@ -58,14 +58,25 @@ elif [ "$2" = "POST-INSTALL" ]; then if [ ! -f "%%DESTDIR%%$POLIPOLOG" ]; then touch "%%DESTDIR%%$POLIPOLOG" || exit 1 chown "$POLIPOUSER" "%%DESTDIR%%$POLIPOLOG" || exit 1 - chmod 0640 "%%DESTDIR%%$POLIPOLOG" || exit 1 + chmod u=rw,g=r,o= "%%DESTDIR%%$POLIPOLOG" || exit 1 fi - if ! fgrep "${POLIPOLOG}" "%%DESTDIR%%/etc/newsyslog.conf" 2>/dev/null 1>&2; then - echo "${POLIPOLOG} ${POLIPOUSER}: 640 3 100 * J $POLIPOPID 30" >> "%%DESTDIR%%/etc/newsyslog.conf" || exit 1 + echo "Add a line to /etc/newsyslog.conf (or /usr/local/etc/newsyslog.d/polipo if" + echo "supported on your system) to enable automatic log file rotation:" + echo + echo "${POLIPOLOG} ${POLIPOUSER}: 640 3 100 * J ${POLIPOPID} 30" + echo fi fi +OSVER=`uname -r | sed -e 's/\..*//'` +if [ ${OSVER} = "8" -o ${OSVER} = "9" ]; then + CACHEPARENT=`dirname ${POLIPOCACHE}` + echo "You will need to manually run:" + echo " chmod o+x %%DESTDIR%%$CACHEPARENT" + echo "to ensure the cache is useable." +fi + exit 0 Modified: head/www/polipo/pkg-plist ============================================================================== --- head/www/polipo/pkg-plist Sat Jul 12 18:25:15 2014 (r361632) +++ head/www/polipo/pkg-plist Sat Jul 12 18:35:35 2014 (r361633) @@ -1,7 +1,14 @@ bin/polipo -etc/polipo/config.sample -etc/polipo/forbidden.sample +@sample etc/polipo/config.sample +@sample etc/polipo/forbidden.sample etc/periodic/daily/400.polipo -%%PORTDOCS%%%%DATADIR%%/www/index.html +man/man1/polipo.1.gz +%%DATADIR%%/www/index.html +@dirrmtry %%DATADIR%%/www +@dirrmtry %%DATADIR%% +@dirrmtry etc/polipo @dirrmtry etc/periodic/daily @dirrmtry etc/periodic +@cwd / +@dirrmtry var/cache/polipo +@cwd %%RESETPREFIX%%