aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2011-10-10 06:28:13 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2011-10-10 06:28:13 +0000
commit955b06f90f949fea22c332c4554b6d6d1a07c449 (patch)
tree03cf75fe8e158809cd49205abad1b8dafc72c132 /testing
parent1dfae260fcf5ddbf7efe8bb2723b6cc6f005f8bc (diff)
downloadaports-955b06f90f949fea22c332c4554b6d6d1a07c449.tar.bz2
aports-955b06f90f949fea22c332c4554b6d6d1a07c449.tar.xz
main/squid: move version 3.2 from testing
Diffstat (limited to 'testing')
-rw-r--r--testing/squid/APKBUILD107
-rw-r--r--testing/squid/squid-3.2.0.12-loggable-urlgroup.patch111
-rw-r--r--testing/squid/squid.confd15
-rw-r--r--testing/squid/squid.initd115
-rw-r--r--testing/squid/squid.logrotate11
-rw-r--r--testing/squid/squid.post-install5
-rw-r--r--testing/squid/squid.pre-install6
-rw-r--r--testing/squid/squid.pre-upgrade6
8 files changed, 0 insertions, 376 deletions
diff --git a/testing/squid/APKBUILD b/testing/squid/APKBUILD
deleted file mode 100644
index 8f2dc8cd11..0000000000
--- a/testing/squid/APKBUILD
+++ /dev/null
@@ -1,107 +0,0 @@
-# Contributor: Carlo Landmeter <clandmeter@gmail.com>
-# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
-pkgname=squid
-pkgver=3.2.0.12
-pkgrel=1
-pkgdesc="A full-featured Web proxy cache server."
-url="http://www.squid-cache.org"
-install="squid.pre-install squid.pre-upgrade squid.post-install"
-pkgusers="squid"
-pkggroups="squid"
-arch="all"
-license="GPL-2"
-depends="logrotate"
-makedepends="openssl-dev perl-dev autoconf automake heimdal-dev libtool
- libcap-dev"
-subpackages="$pkgname-doc"
-linguas="af ar az bg ca cs da de el es et fa fi fr he hu hy id it ja ko lt
- lv ms nl oc pl pt ro ru sk sl sr sv th tr uk uz vi zh"
-langdir="/usr/share/squid/errors"
-
-source="http://www.squid-cache.org/Versions/v3/3.2/squid-$pkgver.tar.bz2
- squid-3.2.0.12-loggable-urlgroup.patch
- squid.initd
- squid.confd
- $pkgname.logrotate
- "
-
-pkgusers="squid"
-pkggroups="squid"
-
-_builddir="$srcdir"/$pkgname-$pkgver
-prepare() {
- cd "$_builddir"
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
-# ./bootstrap.sh
-}
-
-build() {
- cd "$_builddir"
-
- ./configure --prefix=/usr \
- --datadir=/usr/share/squid \
- --sysconfdir=/etc/squid \
- --libexecdir=/usr/lib/squid \
- --localstatedir=/var \
- --disable-strict-error-checking \
- --enable-removal-policies="lru,heap" \
- --enable-digest-auth-helpers="password" \
- --enable-basic-auth-helpers="getpwnam,NCSA,SMB,MSNT,multi-domain-NTLM,squid_radius_auth" \
- --enable-epoll \
- --enable-external-acl-helpers="ip_user,unix_group,wbinfo_group" \
- --enable-ntlm-auth-helpers="fakeauth,no_check,smb_lm" \
- --enable-negotiate-auth-helpers="squid_kerb_auth" \
- --disable-mit \
- --enable-heimdal \
- --enable-delay-pools \
- --enable-arp-acl \
- --enable-ssl \
- --enable-linux-netfilter \
- --enable-ident-lookups \
- --enable-useragent-log \
- --enable-cache-digests \
- --enable-referer-log \
- --enable-async-io \
- --enable-truncate \
- --enable-arp-acl \
- --enable-htcp \
- --enable-carp \
- --enable-poll --with-maxfd=4096 \
- --enable-follow-x-forwarded-for \
- --with-large-files \
- || return 1
-
- make || return 1
-}
-
-package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install
-
- install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
- install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
- install -m644 -D "$srcdir"/$pkgname.logrotate \
- "$pkgdir"/etc/logrotate.d/squid
-
- install -d -o squid -g squid \
- "$pkgdir"/var/cache/squid \
- "$pkgdir"/var/log/squid \
- "$pkgdir"/var/run/squid
- chmod +x "$pkgdir"/usr/lib/squid/*
-}
-
-squid_kerb_auth() {
- pkgdesc="Squid kerberos authetication helper"
- install -d "$subpkgdir"/usr/lib/squid
- mv "$pkgdir"/usr/lib/squid/squid_kerb_auth "$subpkgdir"/usr/lib/squid/
-}
-
-md5sums="f11b71b7c58a2a20e87707d4ba441743 squid-3.2.0.12.tar.bz2
-084f7b1af1ac0cb8fea35c7a0905a80e squid-3.2.0.12-loggable-urlgroup.patch
-57fed05adc40acab6a5480ec7a014154 squid.initd
-44b052db7910f386ef88ddcf69c9ba4e squid.confd
-58823e0b86bc2dc71d270208b7b284b4 squid.logrotate"
diff --git a/testing/squid/squid-3.2.0.12-loggable-urlgroup.patch b/testing/squid/squid-3.2.0.12-loggable-urlgroup.patch
deleted file mode 100644
index ee1646fe58..0000000000
--- a/testing/squid/squid-3.2.0.12-loggable-urlgroup.patch
+++ /dev/null
@@ -1,111 +0,0 @@
-Index: squid-3.2.0.12/src/client_side_request.cc
-===================================================================
---- squid-3.2.0.12.orig/src/client_side_request.cc 2011-10-07 20:29:10.000000000 +0300
-+++ squid-3.2.0.12/src/client_side_request.cc 2011-10-07 21:54:38.000000000 +0300
-@@ -1165,6 +1165,15 @@
- redirect_state = REDIRECT_DONE;
-
- if (result) {
-+ if (result[0] == '!') {
-+ char *t = strchr(result+1, '!');
-+ if (t != NULL) {
-+ old_request->urlgroup.reset(NULL);
-+ old_request->urlgroup.append(result + 1, t - result - 1);
-+ result = t + 1;
-+ }
-+ }
-+
- http_status status = (http_status) atoi(result);
-
- if (status == HTTP_MOVED_PERMANENTLY
-@@ -1183,7 +1192,7 @@
- else
- debugs(85, DBG_CRITICAL, "ERROR: URL-rewrite produces invalid 303 redirect Location: " << result);
- }
-- } else if (strcmp(result, http->uri)) {
-+ } else if (result[0] != 0 && strcmp(result, http->uri)) {
- // XXX: validate the URL properly *without* generating a whole new request object right here.
- // XXX: the clone() should be done only AFTER we know the new URL is valid.
- HttpRequest *new_request = old_request->clone();
-Index: squid-3.2.0.12/src/HttpRequest.cc
-===================================================================
---- squid-3.2.0.12.orig/src/HttpRequest.cc 2011-10-07 21:02:45.000000000 +0300
-+++ squid-3.2.0.12/src/HttpRequest.cc 2011-10-07 21:03:45.000000000 +0300
-@@ -106,6 +106,7 @@
- peer_login = NULL; // not allocated/deallocated by this class
- peer_domain = NULL; // not allocated/deallocated by this class
- vary_headers = NULL;
-+ urlgroup = null_string;
- myportname = null_string;
- tag = null_string;
- #if USE_AUTH
-@@ -154,6 +155,7 @@
- range = NULL;
- }
-
-+ urlgroup.clean();
- myportname.clean();
-
- tag.clean();
-@@ -213,6 +215,7 @@
- copy->vary_headers = vary_headers ? xstrdup(vary_headers) : NULL;
- // XXX: what to do with copy->peer_domain?
-
-+ copy->urlgroup = urlgroup;
- copy->myportname = myportname;
- copy->tag = tag;
- #if USE_AUTH
-Index: squid-3.2.0.12/src/HttpRequest.h
-===================================================================
---- squid-3.2.0.12.orig/src/HttpRequest.h 2011-10-07 21:02:45.000000000 +0300
-+++ squid-3.2.0.12/src/HttpRequest.h 2011-10-07 21:02:55.000000000 +0300
-@@ -187,6 +187,8 @@
-
- char *peer_domain; /* Configured peer forceddomain */
-
-+ String urlgroup;
-+
- String myportname; // Internal tag name= value from port this requests arrived in.
-
- String tag; /* Internal tag for this request */
-Index: squid-3.2.0.12/src/format/Format.cc
-===================================================================
---- squid-3.2.0.12.orig/src/format/Format.cc 2011-10-07 21:33:38.000000000 +0300
-+++ squid-3.2.0.12/src/format/Format.cc 2011-10-07 21:41:45.000000000 +0300
-@@ -895,6 +895,12 @@
- out = tmp;
- break;
-
-+ case LFT_REQUEST_URLGROUP:
-+ if (al->request)
-+ out = al->request->urlgroup.termedBuf();
-+ quote = 1;
-+ break;
-+
- case LFT_SERVER_REQ_METHOD:
- if (al->adapted_request) {
- out = al->adapted_request->method.image();
-Index: squid-3.2.0.12/src/format/Tokens.h
-===================================================================
---- squid-3.2.0.12.orig/src/format/Tokens.h 2011-10-07 21:34:25.000000000 +0300
-+++ squid-3.2.0.12/src/format/Tokens.h 2011-10-07 21:40:26.000000000 +0300
-@@ -100,6 +100,7 @@
- /*LFT_REQUEST_QUERY, */
- LFT_REQUEST_VERSION_OLD_2X,
- LFT_REQUEST_VERSION,
-+ LFT_REQUEST_URLGROUP,
-
- /* Request-Line details sent to the server/peer */
- LFT_SERVER_REQ_METHOD,
-Index: squid-3.2.0.12/src/format/Tokens.cc
-===================================================================
---- squid-3.2.0.12.orig/src/format/Tokens.cc 2011-10-07 21:38:05.000000000 +0300
-+++ squid-3.2.0.12/src/format/Tokens.cc 2011-10-07 21:40:55.000000000 +0300
-@@ -114,6 +114,7 @@
- {"rp", LFT_REQUEST_URLPATH_OLD_31},
- /* { "rq", LFT_REQUEST_QUERY }, * / / * the query-string, INCLUDING the leading ? */
- {"rv", LFT_REQUEST_VERSION},
-+ {"rG", LFT_REQUEST_URLGROUP},
-
- {"<rm", LFT_SERVER_REQ_METHOD},
- {"<ru", LFT_SERVER_REQ_URI},
diff --git a/testing/squid/squid.confd b/testing/squid/squid.confd
deleted file mode 100644
index 14a9ee84bd..0000000000
--- a/testing/squid/squid.confd
+++ /dev/null
@@ -1,15 +0,0 @@
-# Copyright 1999-2004 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/www/viewcvs.gentoo.org/raw_cvs/gentoo-x86/net-proxy/squid/files/squid.confd,v 1.2 2008/11/30 19:20:44 mrness Exp $
-
-# Config file for /etc/init.d/squid
-
-SQUID_OPTS="-DYC"
-
-# Max. number of filedescriptors to use. You can increase this on a busy
-# cache to a maximum of (currently) 8192 filedescriptors. Default is 1024.
-SQUID_MAXFD=1024
-
-# Kerberos keytab file to use. This is required if you enable kerberos authentication.
-SQUID_KEYTAB=""
-
diff --git a/testing/squid/squid.initd b/testing/squid/squid.initd
deleted file mode 100644
index 2eaf1dd2af..0000000000
--- a/testing/squid/squid.initd
+++ /dev/null
@@ -1,115 +0,0 @@
-#!/sbin/runscript
-# Copyright 1999-2006 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/www/viewcvs.gentoo.org/raw_cvs/gentoo-x86/net-proxy/squid/files/squid.initd,v 1.10 2008/11/30 19:20:44 mrness Exp $
-
-opts="${opts} reload rotate"
-
-conf=/etc/squid/squid.conf
-
-depend() {
- need net
- after firewall
-}
-
-# Try to increase the # of filedescriptors we can open.
-maxfds() {
- [ -n "$SQUID_MAXFD" ] || return
- [ -f /proc/sys/fs/file-max ] || return 0
- [ $SQUID_MAXFD -le 8192 ] || SQUID_MAXFD=8192
- local global_file_max=`cat /proc/sys/fs/file-max`
- local minimal_file_max=$(($SQUID_MAXFD + 4096))
- if [ "$global_file_max" -lt $minimal_file_max ]; then
- echo $minimal_file_max > /proc/sys/fs/file-max
- fi
- ulimit -n $SQUID_MAXFD
-}
-
-checkconfig() {
- maxfds
-
- local CACHE_SWAP=$(awk '/^[ \t]*cache_dir[ \t]+/ { if ($2 == "coss" ) printf "%s/stripe ", $3 ; else printf "%s/00 ", $3; }' < $conf)
- [ -z "$CACHE_SWAP" ] && CACHE_SWAP="/var/cache/squid/00"
-
- local x
- for x in $CACHE_SWAP ; do
- if [ ! -e $x ] ; then
- ebegin "Initializing cache directories"
- local ORIG_UMASK=$(umask)
- umask 027
- local INIT_CACHE_RESPONSE="$(/usr/sbin/squid -z -N -D 2>&1)"
- if [ $? != 0 ] || echo "$INIT_CACHE_RESPONSE" | grep -q "erminated abnormally" ; then
- umask $ORIG_UMASK
- eend 1
- echo "$INIT_CACHE_RESPONSE"
- return 1
- fi
- umask $ORIG_UMASK
- eend 0
- break
- fi
- done
-
- squid -k parse
-}
-
-get_pidfile() {
- PIDFILE=$(awk '/^[ \t]*pid_filename[ \t]+/ {print $2}' $conf)
- [ -z "$PIDFILE" ] && PIDFILE=/var/run/squid/squid.pid
-}
-
-start() {
- get_pidfile
- checkconfig || return 1
- ebegin "Starting squid"
- start-stop-daemon --start --pidfile "$PIDFILE" \
- --env KRB5_KTNAME="${SQUID_KEYTAB}" \
- --exec /usr/sbin/squid -- ${SQUID_OPTS}
- eend $? && sleep 1
-}
-
-stop() {
- local rc=0 pid
- ebegin "Stopping squid"
- get_pidfile
- /usr/sbin/squid -k shutdown
-
- # Now we have to wait until squid has _really_ stopped.
- if [ -f "$PIDFILE" ] ; then
- pid=$(cat "$PIDFILE")
- if [ -d /proc/$pid ]; then
- einfon "Waiting for squid to shutdown ."
- else
- rm -f "$PIDFILE"
- fi
- cnt=0
- while [ -f "$PIDFILE" ] ; do
- cnt=$(expr $cnt + 1)
- if [ $cnt -gt 60 ] ; then
- # Waited 120 seconds now. Fail.
- echo
- rc=1
- break
- fi
- sleep 2
- echo -n "."
- done
- echo
- fi
- eend $rc
-}
-
-reload() {
- checkconfig || return 1
- ebegin "Reloading squid"
- /usr/sbin/squid -k reconfigure
- eend $?
-}
-
-rotate() {
- service_started squid || return 1
- ebegin "Rotating logs"
- /usr/sbin/squid -k rotate
- eend $?
-}
-
diff --git a/testing/squid/squid.logrotate b/testing/squid/squid.logrotate
deleted file mode 100644
index fb3279e013..0000000000
--- a/testing/squid/squid.logrotate
+++ /dev/null
@@ -1,11 +0,0 @@
-/var/log/squid/*.log {
- daily
- compress
- rotate 5
- missingok
- nocreate
- sharedscripts
- postrotate
- /usr/sbin/squid -k rotate
- endscript
-}
diff --git a/testing/squid/squid.post-install b/testing/squid/squid.post-install
deleted file mode 100644
index 88df6d26f9..0000000000
--- a/testing/squid/squid.post-install
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-
-chown squid:squid /var/cache/squid /var/log/squid
-exit 0
-
diff --git a/testing/squid/squid.pre-install b/testing/squid/squid.pre-install
deleted file mode 100644
index 322d21deab..0000000000
--- a/testing/squid/squid.pre-install
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-adduser -D squid -H /var/cache/squid 2>/dev/null
-addgroup winbind 2>/dev/null
-addgroup squid winbind
-exit 0
diff --git a/testing/squid/squid.pre-upgrade b/testing/squid/squid.pre-upgrade
deleted file mode 100644
index 322d21deab..0000000000
--- a/testing/squid/squid.pre-upgrade
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-adduser -D squid -H /var/cache/squid 2>/dev/null
-addgroup winbind 2>/dev/null
-addgroup squid winbind
-exit 0