Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 171298 - Multiple issues in mail-filter/amavisd-new ebuilds
Summary: Multiple issues in mail-filter/amavisd-new ebuilds
Status: VERIFIED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-03-18 02:39 UTC by Marius Mauch (RETIRED)
Modified: 2007-03-20 06:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marius Mauch (RETIRED) gentoo-dev 2007-03-18 02:39:42 UTC
if $(has_version mail-mta/courier) ; then
	einfo "Patching with courier support."
	epatch "amavisd-new-courier.patch" || die "patch failed"
fi

1) don't use $(has_version foo), that function may not generate any output, just use the exitcode
2) Applying patches based on installed packages is nasty (e.g. for binary packages), I haven't checked those patches but either they should be applied unconditionally or should be conditional on use flags.

if $(has_version "<mail-filter/spamassassin-3") ; then
	echo
	ewarn "WARNING: Amavisd-new will not work with SpamAssassin older than 3.0.0."
	ewarn "         Consider upgrading your SpamAssassin installation."

3) that should probably be reflected in the deps

if $(has_version net-nds/openldap ) ; then
	einfo "Adding ${P} schema to openldap schema dir."

if $(has_version mail-filter/razor) ; then
	if [ ! -d ${AMAVIS_ROOT}/.razor ] ; then
		einfo "Setting up initial razor config files..."

if [ "$(dnsdomainname)" = "(none)" ] ; then
	dosed "s:^#\\?\\\$mydomain[^;]*;:\$mydomain = '$(hostname)';:" \
		/etc/amavisd.conf

4) This should probably be in pkg_preinst so it uses the name/installed packages of the target system, not the one of the buildsystem
Comment 1 Andrej Kacian (RETIRED) gentoo-dev 2007-03-18 04:57:34 UTC
I'm leaving work in few minutes, so for now I'll just comment on this one.

(In reply to comment #0)
> if $(has_version "<mail-filter/spamassassin-3") ; then
>         echo
>         ewarn "WARNING: Amavisd-new will not work with SpamAssassin older than
> 3.0.0."
>         ewarn "         Consider upgrading your SpamAssassin installation."
> 
> 3) that should probably be reflected in the deps

Spamassassin is not a dependency of amavisd-new - its presence is detected at startup (and if its use is allowed by amavis' config file). Therefore it's been decided to warn users this way. The warning can probably be dropped already anyway.
Comment 2 Andrej Kacian (RETIRED) gentoo-dev 2007-03-19 19:45:32 UTC
All of this should be fixed in 2.4.5-r1. Please have a look at it.
Comment 3 Marius Mauch (RETIRED) gentoo-dev 2007-03-20 06:42:26 UTC
Much better :)