You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
75 lines
1.8 KiB
75 lines
1.8 KiB
8 years ago
|
# Copyright 1999-2016 Gentoo Foundation
|
||
13 years ago
|
# Distributed under the terms of the GNU General Public License v2
|
||
9 years ago
|
# $Id$
|
||
13 years ago
|
|
||
9 years ago
|
EAPI=5
|
||
11 years ago
|
|
||
12 years ago
|
inherit autotools eutils toolchain-funcs user
|
||
13 years ago
|
|
||
|
DESCRIPTION="HTTP AntiVirus Proxy"
|
||
|
HOMEPAGE="http://www.server-side.de/"
|
||
|
SRC_URI="http://www.server-side.de/download/${P}.tar.gz"
|
||
|
|
||
|
LICENSE="GPL-2"
|
||
|
SLOT="0"
|
||
11 years ago
|
KEYWORDS="amd64 x86"
|
||
13 years ago
|
IUSE="clamav ssl"
|
||
|
|
||
10 years ago
|
DEPEND="clamav? ( >=app-antivirus/clamav-0.98.5 )"
|
||
13 years ago
|
RDEPEND="${DEPEND}"
|
||
|
|
||
|
pkg_setup() {
|
||
12 years ago
|
enewgroup ${PN}
|
||
|
enewuser ${PN} -1 -1 /etc/${PN} ${PN}
|
||
13 years ago
|
}
|
||
|
|
||
|
src_prepare() {
|
||
9 years ago
|
epatch \
|
||
|
"${FILESDIR}"/${PN}-0.92a-run.patch \
|
||
|
"${FILESDIR}"/${PF}-pkg-config-libclamav.patch
|
||
12 years ago
|
sed -i configure.in -e '/^CFLAGS=/d' || die
|
||
9 years ago
|
mv configure.{in,ac} || die
|
||
12 years ago
|
eautoreconf
|
||
13 years ago
|
}
|
||
|
|
||
|
src_configure() {
|
||
12 years ago
|
tc-export AR
|
||
|
export CFLAGS="${CXXFLAGS}"
|
||
|
econf \
|
||
13 years ago
|
$(use_enable clamav) \
|
||
12 years ago
|
$(use_enable ssl ssl-tunnel) \
|
||
|
--localstatedir=/var
|
||
13 years ago
|
}
|
||
|
|
||
|
src_install() {
|
||
9 years ago
|
dosbin ${PN}/${PN}
|
||
13 years ago
|
|
||
12 years ago
|
newinitd "${FILESDIR}/${PN}.initd" ${PN}
|
||
13 years ago
|
|
||
12 years ago
|
insinto /etc
|
||
|
rm -r etc/${PN}/${PN}.config.in
|
||
|
doins -r etc/${PN}
|
||
13 years ago
|
|
||
|
dodoc ChangeLog
|
||
|
}
|
||
|
|
||
|
pkg_postinst() {
|
||
12 years ago
|
ewarn "/var/tmp/${PN} must be on a filesystem with mandatory locks!"
|
||
13 years ago
|
ewarn "You should add \"mand\" to the mount options on the relevant line in /etc/fstab."
|
||
|
|
||
|
if use ssl; then
|
||
|
echo
|
||
|
ewarn "Note: ssl USE flag only enable SSL pass-through, which means that"
|
||
|
ewarn " HTTPS pages will not be scanned for viruses!"
|
||
|
ewarn " It is impossible to decrypt data sent through SSL connections without knowing"
|
||
|
ewarn " the private key of the used certificate."
|
||
|
fi
|
||
|
|
||
|
if use clamav; then
|
||
|
echo
|
||
|
ewarn "If you plan to use clamav daemon, you should make sure clamav user can read"
|
||
12 years ago
|
ewarn "/var/tmp/${PN} content. This can be accomplished by enabling AllowSupplementaryGroups"
|
||
|
ewarn "in /etc/clamd.conf and adding clamav user to the ${PN} group."
|
||
13 years ago
|
fi
|
||
|
}
|