Bug 55611

Summary: Clamav port package build fails on 5.x when NO_SENDMAIL is set
Product: Ports & Packages Reporter: Pat Lashley <patl+freebsd>
Component: Individual Port(s)Assignee: freebsd-ports-bugs (Nobody) <ports-bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Pat Lashley 2003-08-15 18:50:13 UTC
        When building the clamav port on FreeBSD 5.x, the Makefile will
        add options to build a milter for sendmail.  If sendmail is not
        installed, the milter build fails.  The clamav installation
        does succeed without this file; but 'make package' fails because
        it can't find sbin/clamav-milter.

Fix: The following patch adds a check for the NO_SENDMAIL make.conf
        option to the OS version test.  When NO_SENMAIL is set, it will
        not try to build the milter.
                                                                                
How-To-Repeat:         Build or install a FreeBSD 5.x system without sendmail.
        cd /usr/ports/security/clamav ; make package
Comment 1 markun 2003-11-02 06:48:17 UTC
Thank you for patch.

I make patch (merge ports/58036). Please commit.
http://www.freebsd.org/cgi/query-pr.cgi?pr=58036


Index: Makefile
===================================================================
RCS file: /home/repository/FreeBSD/ncvs/ports/security/clamav/Makefile,v
retrieving revision 1.12
diff -u -r1.12 Makefile
--- Makefile	25 Oct 2003 20:52:32 -0000	1.12
+++ Makefile	2 Nov 2003 06:42:45 -0000
@@ -7,7 +7,7 @@
 
 PORTNAME=	clamav
 PORTVERSION=	0.60
-PORTREVISION=	4
+PORTREVISION=	5
 CATEGORIES=	security
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	clamav
@@ -40,6 +40,8 @@
 MAN5=		clamav.conf.5
 MAN8=		clamd.8
 
+CONFLICTS=	clamav-devel-*
+
 CLAMD_SOCKET?=	/var/run/clamav/clamd
 
 CONFLICTS=	clamav-devel-*
@@ -73,7 +75,7 @@
 LDFLAGS+=	-lcipher
 .endif
 
-.if defined(WITH_MILTER)
+.if defined(WITH_MILTER) && ! defined(NO_SENDMAIL)
 USE_GETOPT_LONG=	yes
 CONFIGURE_ARGS+=	--enable-milter
 PLIST_SUB+=	CLAMAV-MILTER=""


-- 
TERAMOTO Masahiro
   markun@onohara.to
Comment 2 markun 2003-11-02 09:48:43 UTC
sorry ports/58036 is closed.

Index: Makefile
===================================================================
RCS file: /home/repository/FreeBSD/ncvs/ports/security/clamav/Makefile,v
retrieving revision 1.12
diff -u -r1.12 Makefile
--- Makefile	25 Oct 2003 20:52:32 -0000	1.12
+++ Makefile	2 Nov 2003 09:47:43 -0000
@@ -7,7 +7,7 @@
 
 PORTNAME=	clamav
 PORTVERSION=	0.60
-PORTREVISION=	4
+PORTREVISION=	5
 CATEGORIES=	security
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	clamav
@@ -73,7 +73,7 @@
 LDFLAGS+=	-lcipher
 .endif
 
-.if defined(WITH_MILTER)
+.if defined(WITH_MILTER) && ! defined(NO_SENDMAIL)
 USE_GETOPT_LONG=	yes
 CONFIGURE_ARGS+=	--enable-milter
 PLIST_SUB+=	CLAMAV-MILTER=""


-- 
TERAMOTO Masahiro($B;{K\(B $B>;90(B)
   markun@onohara.to
Comment 3 Pete Fritchman freebsd_committer freebsd_triage 2003-12-21 03:52:22 UTC
State Changed
From-To: open->feedback

Shouldn't we set a PLIST_SUB and modify pkg-plist if we're not 
going to build the milter?
Comment 4 Pav Lucistnik freebsd_committer freebsd_triage 2004-02-28 15:06:50 UTC
State Changed
From-To: feedback->closed

I merged maintainer's patch into CVS tree.
Comment 5 Alex Vasylenko 2004-03-26 17:31:51 UTC
Please consider reopening the PR ports/55611 and reverting the change 
made to ports/security/clamav/Makefile in rev 1.22 for the following 
reasons:

- presence/absence of sendmail in the base system (which is what 
NO_SENDMAIL controls) should not alter the build of clamav (sendmail can 
be installed from a port);
- configure script for clamav contains code that in case of missing 
libmilter will disregard --enable-milter configure argument and refrain 
from building clamav-milter;
- as the port is, clamav-milter can't be built on a system with 
NO_SENDMAIL and a sendmail installed from ports.

thanks,
--
Alex.