summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPat Erley <perley@google.com>2018-05-21 10:47:31 -0700
committerPatrice Clement <monsieurp@gentoo.org>2018-06-23 00:17:06 +0200
commitd5f4c0a636f2cfff9986af10613787d94d82a812 (patch)
treeb41c9b3bc483f30c724fde8886ba27b7b8944115 /net-proxy/squid
parentapp-misc/cdircmp: EAPI7, improve ebuild. (diff)
downloadgentoo-d5f4c0a636f2cfff9986af10613787d94d82a812.tar.gz
gentoo-d5f4c0a636f2cfff9986af10613787d94d82a812.tar.bz2
gentoo-d5f4c0a636f2cfff9986af10613787d94d82a812.zip
net-proxy/squid: make perl optional.
It is possible to use squid as a simple pull through cache without pulling in perl. To allow this simple use case, move the runtime dependency on perl to be guarded by a use flag, and don't install the scripts that use perl in that case. Closes: https://github.com/gentoo/gentoo/pull/8518
Diffstat (limited to 'net-proxy/squid')
-rw-r--r--net-proxy/squid/squid-3.5.27-r1.ebuild20
1 files changed, 18 insertions, 2 deletions
diff --git a/net-proxy/squid/squid-3.5.27-r1.ebuild b/net-proxy/squid/squid-3.5.27-r1.ebuild
index d8e27e7b824f..a81007e75347 100644
--- a/net-proxy/squid/squid-3.5.27-r1.ebuild
+++ b/net-proxy/squid/squid-3.5.27-r1.ebuild
@@ -14,7 +14,7 @@ KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~sparc x86 ~x86-fbsd"
IUSE="caps ipv6 pam ldap libressl samba sasl kerberos nis radius ssl snmp selinux logrotate test \
ecap esi ssl-crtd \
mysql postgres sqlite \
- qos tproxy \
+ perl qos tproxy \
+htcp +wccp +wccpv2 \
pf-transparent ipf-transparent kqueue \
elibc_uclibc kernel_linux"
@@ -33,13 +33,14 @@ COMMON_DEPEND="caps? ( >=sys-libs/libcap-2.16 )
esi? ( dev-libs/expat dev-libs/libxml2 )
!x86-fbsd? ( logrotate? ( app-admin/logrotate ) )
>=sys-libs/db-4:*
- dev-lang/perl
dev-libs/libltdl:0"
DEPEND="${COMMON_DEPEND}
+ dev-lang/perl
ecap? ( virtual/pkgconfig )
test? ( dev-util/cppunit )"
RDEPEND="${COMMON_DEPEND}
samba? ( net-fs/samba )
+ perl? ( dev-lang/perl )
mysql? ( dev-perl/DBD-mysql )
postgres? ( dev-perl/DBD-Pg )
selinux? ( sec-policy/selinux-squid )
@@ -223,6 +224,21 @@ src_install() {
fowners root:squid /usr/libexec/squid/pinger
fperms 4750 /usr/libexec/squid/pinger
+ # these scripts depend on perl
+ if ! use perl; then
+ local f
+ local PERL_SCRIPTS=(
+ "${D}"/usr/libexec/squid/basic_pop3_auth
+ "${D}"/usr/libexec/squid/log_db_daemon
+ "${D}"/usr/libexec/squid/basic_msnt_multi_domain_auth
+ "${D}"/usr/libexec/squid/storeid_file_rewrite
+ "${D}"/usr/libexec/squid/helper-mux.pl
+ )
+ for f in "${PERL_SCRIPTS[@]}"; do
+ rm -v "${f}" || die
+ done
+ fi
+
# cleanup
rm -f "${D}"/usr/bin/Run*
rm -rf "${D}"/run/squid "${D}"/var/cache/squid