Good evening !

I've found the bug on bugzilla at 
http://bugs.gentoo.org/show_bug.cgi?id=168716 , and I've corrected it 
submitting a patch and a new ebuild to prevent the sandbox violation caused 
by the configure script when it try to verify if there is a virus database 
already installed.

It works fine on my two Gentoo boxes (x86 and x86_64).

The patch and the ebuild are attached to this email.
To test my patch, save clamassassin.patch 
as /usr/portage/mail-filter/clamassassin/files/clamassassin.patch, save 
clamassassin-1.2.3-r2.ebuild 
as /usr/portage/mail-filter/clamassassin/clamassassin-1.2.3-r2.ebuild .

After this is done, run the following command :
ebuild /usr/portage/mail-filter/clamassassin/clamassassin-1.2.3-r2.ebuild 
digest to recalculate the digests and to finish run emerge 
=clamassassin-1.2.3-r2 .

Regards.

Le Friday 23 March 2007 19:48:29 Xavier Parizet, vous avez écrit :
> Hi !
>
> Please post the log file showed by the last line (LOG FILE =) after
> retrying to install it to see if the install process make the same error,
> because it seems it leaves the portage "chroot"...
>
> Regards.
>
> Friday 23 March 2007 19:38:17 Steve [Gentoo], you wrote :
> > #emerge clamassassin
> > Calculating dependencies... done!
> >
> >  >>> Emerging (1 of 1) mail-filter/clamassassin-1.2.3 to /
> >
> >  * clamassassin-1.2.3.tar.gz RMD160 ;-)
> > ...                               [ ok ]
> >  * clamassassin-1.2.3.tar.gz SHA1 ;-)
> > ...                                 [ ok ]
> >  * clamassassin-1.2.3.tar.gz SHA256 ;-)
> > ...                               [ ok ]
> >  * clamassassin-1.2.3.tar.gz size ;-)
> > ...                                 [ ok ]
> >  * checking ebuild checksums ;-)
> > ...                                      [ ok ]
> >  * checking auxfile checksums ;-)
> > ...                                     [ ok ]
> >  * checking miscfile checksums ;-)
> > ...                                    [ ok ]
> >  * checking clamassassin-1.2.3.tar.gz ;-)
> > ...                             [ ok ]
> >
> >  >>> Unpacking source...
> >  >>> Unpacking clamassassin-1.2.3.tar.gz to
> >
> > /var/tmp/portage/mail-filter/clamassassin-1.2.3/work
> >
> >  >>> Source unpacked.
> >  >>> Compiling source in
> >
> > /var/tmp/portage/mail-filter/clamassassin-1.2.3/work/clamassassin-1.2.3
> > ... ./configure --prefix=/usr --host=i686-pc-linux-gnu
> > --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share
> > --sysconfdir=/etc --localstatedir=/var/lib --disable-subject-rewrite
> > --disable-clamdscan --build=i686-pc-linux-gnu
> > checking for rm... /bin/rm
> > checking for cat... /bin/cat
> > checking for sed... /bin/sed
> > checking for echo... /bin/echo
> > checking for formail... /usr/bin/formail
> > checking for mktemp... /bin/mktemp
> > checking for sigtool... /usr/bin/sigtool
> > checking for clamscan... /usr/bin/clamscan
> > checking for clamdscan... /usr/bin/clamdscan
> > checking for /tmp/clamd... no
> > configure: ClamAV version 0.90 detected.
> > configure: Using scanner /usr/bin/clamscan
> > configure: Using scanner options --no-summary --stdout --mbox
> > configure: Using virus signature file dir /var/lib/clamav
> > configure: Signature version reporting is off.
> > configure: Scanner name adding is on.
> > configure: Using temporary directory
> > /var/tmp/portage/mail-filter/clamassassin-1.2.3/temp
> > configure: Subject header rewriting is off.
> > configure: creating ./config.status
> > config.status: creating clamassassin
> > config.status: creating Makefile
> >
> >  >>> Source compiled.
> >
> > --------------------------- ACCESS VIOLATION SUMMARY
> > ---------------------------
> > LOG FILE =
> > "/var/log/sandbox/sandbox-mail-filter_-_clamassassin-1.2.3-11762.log"
> >
> > open_wr:   /var/lib/clamav/.dbLock
> > open_wr:   /var/lib/clamav/.dbLock
> > -------------------------------------------------------------------------
> >-- -----


-- 
    Xavier Parizet
http://www.linuxant.fr/
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: 
/var/cvsroot/gentoo-x86/mail-filter/clamassassin/clamassassin-1.2.3.ebuild,v 
1.2 2006/03/13 14:22:42 ticho Exp $

inherit eutils autotools

DESCRIPTION="clamassassin is a simple script for virus scanning (through 
clamav) an e-mail message as a
filter (like spamassassin)"
HOMEPAGE="http://drivel.com/clamassassin/";
SRC_URI="http://drivel.com/clamassassin/${P}.tar.gz";
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~sparc x86"
IUSE="subject-rewrite clamd"
DEPEND=">=app-antivirus/clamav-0.75.1
                sys-apps/debianutils
                sys-apps/which
                mail-filter/procmail"

src_compile() {
        epatch "${FILESDIR}/clamassassin.patch"
        eautoreconf || die
        econf \
                $(use_enable subject-rewrite) \
                $(use_enable clamd clamdscan) \
         || die
        # Fix problems with Portage exporting TMP and breaking clamassassin. 
#61806
        sed -i -e "s:${TMP}:/tmp:" clamassassin
}

src_install() {
        dobin clamassassin
        dodoc CHANGELOG LICENSE README
}
diff -Naur clamassassin-1.2.3.new/configure.ac clamassassin-1.2.3/configure.ac
--- clamassassin-1.2.3.new/configure.ac	2006-01-10 06:02:42.000000000 +0100
+++ clamassassin-1.2.3/configure.ac	2007-03-23 21:19:05.000000000 +0100
@@ -158,20 +158,11 @@
 then
   AC_SUBST(CONF_CLAMSCANOPT,"--disable-summary --stdout")
 else
-  AC_SUBST(CONF_CLAMSCANOPT,"--no-summary --stdout --mbox")
+  AC_SUBST(CONF_CLAMSCANOPT,"--no-summary --stdout")
 fi
 
 AC_MSG_NOTICE([Using scanner options ${CONF_CLAMSCANOPT}])
 
-SIGLOC=`${CONF_CLAMSCAN} --debug --tempdir=/dev/null /dev/null 2>&1 | ${CONF_SED} -e "/^LibClamAV debug: Loading databases from /!d" -e "s/.* //" -e q`
-if test "$SIGLOC" = ""
-then
-  AC_MSG_ERROR([Cannot determine virus signature file directory])
-else
-  AC_MSG_NOTICE([Using virus signature file dir ${SIGLOC}])
-  AC_SUBST(CONF_SIGLOC,${SIGLOC})
-fi
-
 AC_ARG_ENABLE(signature-version,
 [  --enable-signature-version
 	Turns on signature version reporting (default for ClamAV below 0.80)

Attachment: pgpflG9yrAH8l.pgp
Description: PGP signature

Reply via email to