diff options
author | Alin Năstac <mrness@gentoo.org> | 2008-07-08 21:16:23 +0000 |
---|---|---|
committer | Alin Năstac <mrness@gentoo.org> | 2008-07-08 21:16:23 +0000 |
commit | 0fab32b64d35fb46de8f7c100c29f6177b053985 (patch) | |
tree | 526e48e49e6749876bc047a4e4ed656d9284a1e4 | |
parent | Change autoconf into eautoconf for dev-haskell/haddock-0.8 (diff) | |
download | gentoo-2-0fab32b64d35fb46de8f7c100c29f6177b053985.tar.gz gentoo-2-0fab32b64d35fb46de8f7c100c29f6177b053985.tar.bz2 gentoo-2-0fab32b64d35fb46de8f7c100c29f6177b053985.zip |
Fix regex support, thanks to Yar Odin <yarodin@gmail.com> (#230922).
(Portage version: 2.1.4.4, RepoMan options: --force)
-rw-r--r-- | net-proxy/squidguard/ChangeLog | 8 | ||||
-rw-r--r-- | net-proxy/squidguard/files/squidguard-1.3-bison.patch | 94 | ||||
-rw-r--r-- | net-proxy/squidguard/squidguard-1.3-r2.ebuild | 75 |
3 files changed, 176 insertions, 1 deletions
diff --git a/net-proxy/squidguard/ChangeLog b/net-proxy/squidguard/ChangeLog index 847cbe9e3c5e..ce6f30704383 100644 --- a/net-proxy/squidguard/ChangeLog +++ b/net-proxy/squidguard/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-proxy/squidguard # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidguard/ChangeLog,v 1.24 2008/06/23 19:43:30 dertobi123 Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidguard/ChangeLog,v 1.25 2008/07/08 21:16:23 mrness Exp $ + +*squidguard-1.3-r2 (08 Jul 2008) + + 08 Jul 2008; Alin Năstac <mrness@gentoo.org> + +files/squidguard-1.3-bison.patch, +squidguard-1.3-r2.ebuild: + Fix regex support, thanks to Yar Odin <yarodin@gmail.com> (#230922). 23 Jun 2008; Tobias Scherbaum <dertobi123@gentoo.org> squidguard-1.3-r1.ebuild: diff --git a/net-proxy/squidguard/files/squidguard-1.3-bison.patch b/net-proxy/squidguard/files/squidguard-1.3-bison.patch new file mode 100644 index 000000000000..1c2fee88515f --- /dev/null +++ b/net-proxy/squidguard/files/squidguard-1.3-bison.patch @@ -0,0 +1,94 @@ +diff -Nru squidGuard-1.3.orig/configure.in squidGuard-1.3/configure.in +--- squidGuard-1.3/configure.in 2007-05-10 21:39:44.000000000 +0600 ++++ squidGuard-1.3/configure.in 2008-07-06 14:11:01.000000000 +0600 +@@ -296,4 +296,4 @@ + AC_SUBST(ROBOTEXCEPTIONS) + AC_SUBST(BLACKLISTS) + +-AC_OUTPUT(Makefile src/Makefile src/sg.h doc/Makefile test/Makefile test/test1.conf test/test2.conf samples/Makefile samples/sample.conf samples/squidGuard.cgi samples/squidGuard-simple.cgi contrib/Makefile contrib/squidGuardRobot/squidGuardRobot contrib/sgclean/sgclean contrib/hostbyname/hostbyname) ++AC_OUTPUT(Makefile src/Makefile src/sg.h src/sg.y doc/Makefile test/Makefile test/test1.conf test/test2.conf samples/Makefile samples/sample.conf samples/squidGuard.cgi samples/squidGuard-simple.cgi contrib/Makefile contrib/squidGuardRobot/squidGuardRobot contrib/sgclean/sgclean contrib/hostbyname/hostbyname) +diff -Nru squidGuard-1.3.orig/src/sg.y.in squidGuard-1.3/src/sg.y.in +--- squidGuard-1.3/src/sg.y.in 2007-11-03 18:59:49.000000000 +0500 ++++ squidGuard-1.3/src/sg.y.in 2008-07-06 15:35:08.000000000 +0600 +@@ -185,7 +185,6 @@ + source_content: DOMAIN domain + | USER user + | USERLIST WORD { sgSourceUserList($2); } +-@YACCLINE@ + | EXECUSERLIST EXECCMD { sgSourceExecUserList($2); } + | USERQUOTA NUMBER NUMBER HOURLY { + sgSourceUserQuota($2,$3,"3600");} +@@ -667,7 +666,7 @@ + */ + + if(!ldap_is_ldap_url(url)) { +- @NOLOG1@ sgLogError("%s: can't parse LDAP url %s",progname, url); @NOLOG2@ ++ sgLogError("%s: can't parse LDAP url %s",progname, url); + return; + } + +@@ -1832,7 +1831,7 @@ + m = ((lastval - m) * 60) - lt->tm_sec; + if(m <= 0) + m = 30; +-@NOLOG1@ sgLogError("Info: recalculating alarm in %d seconds", (unsigned int)m); @NOLOG2@ ++ sgLogError("Info: recalculating alarm in %d seconds", (unsigned int)m); + alarm((unsigned int) m); + sgTimeCheck(lt,t); + sgTimeSetAcl(); +@@ -2275,16 +2274,12 @@ + } + } + } +-@NOLOG1@ + else { + if( globalDebug == 1 ) { sgLogError("source not found"); } + } +-@NOLOG2@ + if(!found) { + acl = defaultAcl; +-@NOLOG1@ + if( globalDebug == 1 ) { sgLogError("no ACL matching source, using default"); } +-@NOLOG2@ + } + return acl; + } +@@ -2516,7 +2511,7 @@ + + sgDbUpdate(src->userDb, ident, (char *) userinfo, + sizeof(struct UserInfo)); +- @NOLOG1@ sgLogError("Added LDAP source: %s", ident); @NOLOG2@ ++ sgLogError("Added LDAP source: %s", ident); + + if(found) { + *rval = userinfo; +@@ -2684,12 +2679,12 @@ + if (strncmp(key, "bindname=", 9) == 0) + { + binddn = data; +- @NOLOG1@ sgLogError("Extracted binddn: %s", binddn); @NOLOG2@ ++ sgLogError("Extracted binddn: %s", binddn); + } + else if (strncmp(key, "x-bindpass=", 11) == 0) + { + bindpass = data; +- @NOLOG1@ sgLogError("Extracted x-bindpass: %s", bindpass); @NOLOG2@ ++ sgLogError("Extracted x-bindpass: %s", bindpass); + } + } + +@@ -2707,14 +2702,12 @@ + lud->lud_attrs, 0, NULL, NULL, NULL, -1, + &ldapresult) != LDAP_SUCCESS) { + +-@NOLOG1@ + sgLogError("%s: ldap_search_ext_s failed: %s " + + "(params: %s, %d, %s, %s)", + progname, ldap_err2string(get_ldap_errno(ld)), + lud->lud_dn, lud->lud_scope, lud->lud_filter, + lud->lud_attrs[0]); +-@NOLOG2@ + + ldap_unbind(ld); + ldap_free_urldesc(lud); diff --git a/net-proxy/squidguard/squidguard-1.3-r2.ebuild b/net-proxy/squidguard/squidguard-1.3-r2.ebuild new file mode 100644 index 000000000000..8742204571f3 --- /dev/null +++ b/net-proxy/squidguard/squidguard-1.3-r2.ebuild @@ -0,0 +1,75 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidguard/squidguard-1.3-r2.ebuild,v 1.1 2008/07/08 21:16:23 mrness Exp $ + +WANT_AUTOMAKE=none + +inherit eutils autotools + +DESCRIPTION="Combined filter, redirector and access controller plugin for Squid." +HOMEPAGE="http://www.squidguard.org" +SRC_URI="http://www.squidguard.org/Downloads/squidGuard-${PV}.tar.gz + http://www.squidguard.org/Downloads/Patches/${PV}/squidGuard-${PV}-patch-20080613.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc ppc64 x86" +IUSE="ldap" + +RDEPEND="net-proxy/squid + >=sys-libs/db-2 + ldap? ( net-nds/openldap )" +DEPEND="${RDEPEND} + sys-devel/bison + sys-devel/flex" + +S="${WORKDIR}/squidGuard-${PV}" + +RESTRICT="test" # tests are currently broken + +src_unpack() { + unpack ${A} + + cd "${S}" + cp ../squidGuard-${PV}-patch-20080613/src/sgDiv.c.in src/ || die "failed to replace sgDiv.c.in" + epatch "${FILESDIR}/${P}-gentoo.patch" + epatch "${FILESDIR}/${P}-autoheader.patch" + epatch "${FILESDIR}/${P}-bison.patch" + eautoreconf +} + +src_compile() { + econf \ + $(use_with ldap) \ + --with-sg-config=/etc/squidGuard/squidGuard.conf \ + --with-sg-logdir=/var/log/squidGuard \ + || die "configure has failed" + + emake || die "make has failed" +} + +src_install() { + emake prefix="/usr" INSTDIR="${D}" install || die "emake install has failed" + + keepdir /var/log/squidGuard + fowners squid:squid /var/log/squidGuard + + insinto /etc/squidGuard/sample + doins "${FILESDIR}"/squidGuard.conf.* + insinto /etc/squidGuard/sample/db + doins "${FILESDIR}"/blockedsites + + dodoc ANNOUNCE CHANGELOG README + dohtml doc/*.html + docinto text + dodoc doc/*.txt +} + +pkg_postinst() { + einfo "To enable squidGuard, add the following lines to /etc/squid/squid.conf:" + einfo " url_rewrite_program /usr/bin/squidGuard" + einfo " url_rewrite_children 10" + einfo "" + einfo "Remember to edit /etc/squidGuard/squidGuard.conf first!" + einfo "Examples can be found in /etc/squidGuard/sample/" +} |