Subject: pkg/26975: mail/msmtp update
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <tripledes@eslack.org>
List: pkgsrc-bugs
Date: 09/16/2004 20:38:45
>Number:         26975
>Category:       pkg
>Synopsis:       mail/msmtp update and PKG_OPTIONS added
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Sep 16 18:39:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Sergio Jimenez
>Release:        NetBSD 2.0G
>Organization:
	
>Environment:
	
	
System: NetBSD magni.midgard.bounceme.net 2.0G NetBSD 2.0G (magni) #0: Sun Sep 12 13:14:59 CEST 2004 sergio@magni.midgard.bounceme.net:/usr/src/obj/usr/src/sys/arch/i386/compile/MAGNI i386
Architecture: i386
Machine: i386
>Description:
	mail/msmtp needs to be updated to 1.2.3, also I've added PKG_OPTIONS framework support to enable the user to disable/enable some options in the build process.
>How-To-Repeat:
	look at mail/msmtp/Makefile and http://msmtp.sourceforge.net/
>Fix:
	apply the following patch

diff -urN msmtp.orig/Makefile msmtp/Makefile
--- msmtp.orig/Makefile	2004-06-20 23:05:02.000000000 +0200
+++ msmtp/Makefile	2004-09-16 14:59:42.000000000 +0200
@@ -1,7 +1,7 @@
 # $NetBSD: Makefile,v 1.5 2004/06/20 21:05:02 xtraeme Exp $
 #
 
-DISTNAME=		msmtp-1.0.0
+DISTNAME=		msmtp-1.2.3
 CATEGORIES=		mail
 MASTER_SITES=		${MASTER_SITE_SOURCEFORGE:=msmtp/}
 
@@ -9,14 +9,17 @@
 HOMEPAGE=		http://msmtp.sourceforge.net/
 COMMENT=		SMTP plugin for MUAs
 
+.include "../../mk/bsd.prefs.mk"
+
 USE_BUILDLINK3=		YES
 GNU_CONFIGURE=    	YES
 
 EGDIR=                  ${PREFIX}/share/examples/msmtp
 
+.include "options.mk"
+
 post-install:
 	${INSTALL_DATA_DIR} ${EGDIR}
 	${INSTALL_DATA} ${WRKSRC}/doc/msmtprc.example ${EGDIR}
 
-.include "../../security/openssl/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff -urN msmtp.orig/distinfo msmtp/distinfo
--- msmtp.orig/distinfo	2004-06-20 23:05:02.000000000 +0200
+++ msmtp/distinfo	2004-09-16 15:00:16.000000000 +0200
@@ -1,4 +1,4 @@
 $NetBSD: distinfo,v 1.2 2004/06/20 21:05:02 xtraeme Exp $
 
-SHA1 (msmtp-1.0.0.tar.gz) = 0acfd6bf85a6467a3c5017561aebdcc1c030a5b9
-Size (msmtp-1.0.0.tar.gz) = 144444 bytes
+SHA1 (msmtp-1.2.3.tar.gz) = f95c434feecb963203701ca3f7600752199deb3b
+Size (msmtp-1.2.3.tar.gz) = 158574 bytes
diff -urN msmtp.orig/options.mk msmtp/options.mk
--- msmtp.orig/options.mk	1970-01-01 01:00:00.000000000 +0100
+++ msmtp/options.mk	2004-09-16 20:27:34.000000000 +0200
@@ -0,0 +1,54 @@
+# $NetBSD$
+
+.if defined(MSMTP_USE_GNUTLS) && !empty(MSMTP_USE_GNUTLS:M[yY][eE][sS])
+PKG_DEFAULT_OPTIONS+=	gnutls
+.endif
+.if defined(USE_INET6) && !empty(USE_INET6:M[yY][eE][sS])
+PKG_DEFAULT_OPTIONS+=	inet6
+.endif
+.if defined(MSMTP_USE_OPENSSL) && !empty(MSMTP_USE_OPENSSL:M[yY][eE][sS])
+PKG_DEFAULT_OPTIONS+=	ssl
+.endif
+.if defined(MSMTP_USE_GSASL) && !empty(MSMTP_USE_GSASL:M[yY][eE][sS])
+PKG_DEFAULT_OPTIONS+=   gsasl
+.endif
+.if defined(MSMTP_NO_SSL) && !empty(MSMTP_NO_SSL:M[yY][eE][sS])
+PKG_DEFAULT_OPTIONS+=	nossl
+.endif
+
+PKG_OPTIONS_VAR=	PKG_OPTIONS.msmtp
+PKG_SUPPORTED_OPTIONS=	gnutls inet6 ssl gsasl nossl
+
+.if !defined(PKG_OPTIONS.msmtp)
+PKG_DEFAULT_OPTIONS+=	inet6 ssl
+.endif
+
+.include "../../mk/bsd.options.mk"
+
+###
+### GNUtls support.
+###
+.if !empty(PKG_OPTIONS:Mgnutls)
+.include "../../security/gnutls/buildlink3.mk"
+.endif
+
+###
+### OpenSSL support.
+###
+.if !empty(PKG_OPTIONS:Mssl)
+.include "../../security/openssl/buildlink3.mk"
+.endif
+
+###
+### GNUsasl support.
+###
+.if !empty(PKG_OPTIONS:Mgsasl)
+.include "../../security/gsasl/buildlink3.mk"                 
+.endif
+
+###
+### No SSL support.
+###
+.if !empty(PKG_OPTIONS:Mnossl)
+CONFIGURE_ARGS+=	--disable-ssl
+.endif
>Release-Note:
>Audit-Trail:
>Unformatted: