1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
4 DESCRIPTION="Simple spamassassin-like script for virus scanning and filtering e-mail messages"
5 HOMEPAGE="http://jameslick.com/clamassassin/"
6 SRC_URI="http://jameslick.com/clamassassin/${P}.tar.gz"
9 KEYWORDS="amd64 ~ppc ~sparc x86"
10 IUSE="subject-rewrite clamd"
11 DEPEND=">=app-antivirus/clamav-0.90
17 # Try to get location of clamd's DatabaseDirectory
18 local clamav_dbdir=`awk '$1 == "DatabaseDirectory" { print $2 }' \
20 # If not defined in clamd.conf, go with default
21 if [ -z "$clamav_dbdir" ] ; then
22 clamav_dbdir="/var/lib/clamav"
24 # Add an entry to sandbox write prediction list, so sandbox doesn't complain
25 addpredict ${clamav_dbdir}/
28 $(use_enable subject-rewrite) \
29 $(use_enable clamd clamdscan) \
31 # Fix problems with Portage exporting TMP and breaking clamassassin. #61806
32 sed -i -e "s:${TMP}:/tmp:" clamassassin
37 dodoc CHANGELOG README