Skip site navigation (1)Skip section navigation (2)
Date:      25 Jul 2004 08:28:30 -0000
From:      Thomas-Martin Seck <tmseck@netcologne.de>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/69552: [Maintainer] www/squid: rework plist generation, touch up squid.sh
Message-ID:  <20040725082830.11540.qmail@laurel.tmseck.homedns.org>
Resent-Message-ID: <200407250830.i6P8UVrQ016682@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         69552
>Category:       ports
>Synopsis:       [Maintainer] www/squid: rework plist generation, touch up squid.sh
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jul 25 08:30:31 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Thomas-Martin Seck
>Release:        FreeBSD 4.10-STABLE i386
>Organization:
a private site in Germany
>Environment:
FreeBSD ports collection as of July 25th, 2004.

	
>Description:
- Apply touch-ups to squid.sh:
  Provide a 'shutdown' keyword, set squid_enable to NO unless defined
  otherwise and sort squid-* variable definitions.

- Rework package list generation:
  Hardcode the list of distribution files to avoid registration
  of local files within distribution directories after an update
  (see ports/69266, thanks to Tsurutani Naoki for spotting the problem
  and providing a patch) and prefer sh(1) over make(1) loops to speed
  things up a bit.

- Bump PORTREVISION; not strictly necessary but useful to distinguish
  this version from 2.5.6_2 which may or may not suffer from LDAP related
  problems, be it fetching or functionality.

	
>How-To-Repeat:
	
>Fix:
Apply this patch:

Index: files/squid.sh
===================================================================
--- files/squid.sh	(.../www/squid)	(revision 149)
+++ files/squid.sh	(.../local/squid)	(revision 149)
@@ -5,7 +5,7 @@
 # PROVIDE: squid
 # REQUIRE: NETWORKING SERVERS
 # BEFORE: DAEMON
-# KEYWORD: FreeBSD
+# KEYWORD: FreeBSD shutdown
 # 
 # Note:
 # If you are running an rcNG-System (i.e. FreeBSD 5 and later) you need to set
@@ -21,8 +21,9 @@
 reload_cmd="${command} -k reconfigure"
 stop_cmd="${command} -k shutdown"
 squid_chdir=${squid_chdir:-%%PREFIX%%/squid/logs}
+squid_enable=${squid_enable:-"NO"}
+squid_flags=${squid_flags:-"-D"}
 squid_user=${squid_user:-%%SQUID_UID%%}
-squid_flags=${squid_flags:-"-D"}
 default_config=%%PREFIX%%/etc/squid/squid.conf
 
 if [ -f /etc/rc.subr ]; then
Index: Makefile
===================================================================
--- Makefile	(.../www/squid)	(revision 149)
+++ Makefile	(.../local/squid)	(revision 149)
@@ -74,7 +74,7 @@
 
 PORTNAME=	squid
 PORTVERSION=	2.5.6
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	www
 MASTER_SITES=	\
 		ftp://ftp.squid-cache.org/pub/%SUBDIR%/ \
@@ -145,6 +145,33 @@
 		etc/squid/msntauth.conf.default etc/squid/squid.conf.default \
 		sbin/RunAccel sbin/RunCache sbin/squidclient sbin/squid
 
+icon_files=	anthony-binhex.gif anthony-bomb.gif anthony-box.gif \
+		anthony-box2.gif anthony-c.gif anthony-compressed.gif \
+		anthony-dir.gif anthony-dirup.gif anthony-dvi.gif \
+		anthony-f.gif anthony-image.gif anthony-image2.gif \
+		anthony-layout.gif anthony-link.gif anthony-movie.gif \
+		anthony-pdf.gif anthony-portal.gif anthony-ps.gif \
+		anthony-quill.gif anthony-script.gif anthony-sound.gif \
+		anthony-tar.gif anthony-tex.gif anthony-text.gif \
+		anthony-unknown.gif anthony-xbm.gif anthony-xpm.gif
+
+error_files=	ERR_ACCESS_DENIED ERR_CACHE_ACCESS_DENIED \
+		ERR_CACHE_MGR_ACCESS_DENIED ERR_CANNOT_FORWARD \
+		ERR_CONNECT_FAIL ERR_DNS_FAIL ERR_FORWARDING_DENIED \
+		ERR_FTP_DISABLED ERR_FTP_FAILURE ERR_FTP_FORBIDDEN \
+		ERR_FTP_NOT_FOUND ERR_FTP_PUT_CREATED \
+		ERR_FTP_PUT_ERROR ERR_FTP_PUT_MODIFIED \
+		ERR_FTP_UNAVAILABLE ERR_INVALID_REQ ERR_INVALID_URL \
+		ERR_LIFETIME_EXP ERR_NO_RELAY ERR_ONLY_IF_CACHED_MISS \
+		ERR_READ_ERROR ERR_READ_TIMEOUT ERR_SHUTTING_DOWN \
+		ERR_SOCKET_FAILURE ERR_TOO_BIG ERR_UNSUP_REQ \
+		ERR_URN_RESOLVE ERR_WRITE_ERROR ERR_ZERO_SIZE_OBJECT
+
+libexec=	cachemgr.cgi digest_pw_auth diskd dnsserver ip_user_check \
+		squid_ldap_auth squid_ldap_group msnt_auth ncsa_auth ntlm_auth \
+		pam_auth pinger smb_auth smb_auth.sh squid_unix_group \
+		unlinkd wb_auth wb_group wb_ntlmauth wbinfo_group.pl yp_auth
+
 CONFIGURE_ARGS=	--bindir=${PREFIX}/sbin  --sysconfdir=${PREFIX}/etc/squid \
 		--datadir=${PREFIX}/etc/squid \
 		--libexecdir=${PREFIX}/libexec/squid \
@@ -323,17 +350,24 @@
 	@${SETENV} PKG_PREFIX=${PREFIX} \
 	    ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
 # Create package list:
-	@cd ${PREFIX} && ${FIND} libexec/squid -type f -o -type l | ${SORT} \
+	@for f in ${libexec}; do \
+	    ${TEST} -f ${PREFIX}/libexec/squid/$${f} && \
+	    ${ECHO_CMD} "libexec/squid/$${f}" >>${TMPPLIST} || ${TRUE} ; \
+	done
+	@${ECHO_CMD} "@unexec rmdir %D/libexec/squid 2>/dev/null || true" \
 	    >>${TMPPLIST}
-	@${ECHO_CMD} "@dirrm libexec/squid" >>${TMPPLIST}
-	@cd ${PREFIX} && ${FIND} etc/squid/icons -type f -o -type l | ${SORT} \
+	@for f in ${icon_files}; do \
+	    ${ECHO_CMD} "etc/squid/icons/$${f}" >>${TMPPLIST}; \
+	done
+	@${ECHO_CMD} "@unexec rmdir %D/etc/squid/icons 2>/dev/null || true" \
 	    >>${TMPPLIST}
-	@${ECHO_CMD} "@dirrm etc/squid/icons" >>${TMPPLIST}
-.for d in ${SQUID_LANGUAGES}
-	@cd ${PREFIX} && ${FIND} etc/squid/errors/${d} -type f | ${SORT} \
-	    >>${TMPPLIST}
-	@${ECHO_CMD} "@dirrm etc/squid/errors/${d}" >>${TMPPLIST}
-.endfor
+	@for d in ${SQUID_LANGUAGES}; do \
+	    for f in ${error_files}; do \
+		${ECHO_CMD} "etc/squid/errors/$${d}/$${f}" >>${TMPPLIST} ; \
+	    done; \
+	    ${ECHO_CMD} "@unexec rmdir %D/etc/squid/errors/$${d} 2>/dev/null || true" \
+		>>${TMPPLIST}; \
+	done
 	@${ECHO_CMD} "@unexec rmdir %D/etc/squid/errors 2>/dev/null || true" \
 	    >>${TMPPLIST}
 

	


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040725082830.11540.qmail>