ports/61089: [Maintainer Update] mail/dspam
Rob Evers
rob at debank.tv
Thu Jan 8 19:00:29 UTC 2004
>Number: 61089
>Category: ports
>Synopsis: [Maintainer Update] mail/dspam
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Thu Jan 08 11:00:24 PST 2004
>Closed-Date:
>Last-Modified:
>Originator: Rob Evers
>Release: FreeBSD 4.9-RELEASE i386
>Organization:
>Environment:
System: FreeBSD haha.debank.tv 4.9-RELEASE FreeBSD 4.9-RELEASE #1: Thu Nov 13 01:17:26 CET 2003 rob at haha.debank.tv:/usr/obj/usr/src/sys/HAHA i386
>Description:
Update mail/dspam
Add ENABLE_SPAM_DELIVERY knob
Make dspam play with qmail
Install MySQL documentation
Install a dummy mysql.data file
Submitted by: Mark Daniel Reidel <mark at reidel.info>, Thanks !!
>How-To-Repeat:
>Fix:
New file files/mysql.data
--- dspam.patch begins here ---
diff -ruN dspam.orig/Makefile dspam/Makefile
--- dspam.orig/Makefile Mon Dec 22 20:13:51 2003
+++ dspam/Makefile Thu Jan 8 19:50:22 2004
@@ -7,6 +7,7 @@
PORTNAME= dspam
PORTVERSION= 2.8.1
+PORTREVISION= 1
CATEGORIES= mail
MASTER_SITES= http://www.nuclearelephant.com/projects/dspam/sources/
@@ -20,16 +21,24 @@
USE_LIBTOOL= yes
USE_REINPLACE= yes
+SED_SCRIPT= -e 's,%%DOCSDIR%%,${DOCSDIR},g' \
+ -e 's,%%EXAMPLESDIR%%,${EXAMPLESDIR},g' \
+ -e 's,%%LOCALBASE%%,${LOCALBASE},g'
+
.if defined(WITH_MYSQL)
USE_MYSQL= yes
CONFIGURE_ARGS+= --with-storage-driver=mysql_drv \
--with-mysql-includes=${LOCALBASE}/include/mysql \
--with-mysql-libraries=${LOCALBASE}/lib/mysql
PLIST_SUB+= DB4="@comment "
+PLIST_SUB+= MYSQL=""
+SED_SCRIPT+= -e 's,%%MYSQL%%,,g'
.else
LIB_DEPENDS= db41.1:${PORTSDIR}/databases/db41
CONFIGURE_ARGS+= --with-db4-includes=${LOCALBASE}/include/db41
PLIST_SUB+= DB4=""
+PLIST_SUB+= MYSQL="@comment "
+SED_SCRIPT+= -e '/%%MYSQL%%/D'
.endif
.if defined(WITH_MAILDROP)
@@ -42,6 +51,14 @@
CONFIGURE_ARGS+= --with-local-delivery-agent='${LOCALBASE}/bin/procmail $u'
.endif
+.if defined(WITH_QMAIL)
+CONFIGURE_ARGS+= --with-dspam-mode=4511
+.endif
+
+.if defined(ENABLE_SPAM_DELIVERY)
+CONFIGURE_ARGS+= --enable-spam-delivery
+.endif
+
post-patch:
@${REINPLACE_CMD} -e 's|%%LIBTOOLFLAGS%%|${LIBTOOLFLAGS}|g ; \
s|-ldb-4.1|-ldb41|g' ${WRKSRC}/configure
@@ -51,7 +68,19 @@
@${MKDIR} ${DOCSDIR}
@${INSTALL_DATA} ${WRKSRC}/README ${WRKSRC}/CHANGE \
${DOCSDIR}
+.if defined(WITH_MYSQL)
+ @${MKDIR} ${DOCSDIR}/mysql
+ @${INSTALL_DATA} ${WRKSRC}/tools.mysql_drv/README \
+ ${WRKSRC}/tools.mysql_drv/mysql_objects.sql \
+ ${WRKSRC}/tools.mysql_drv/virtual_users.sql \
+ ${WRKSRC}/tools.mysql_drv/purge.sql \
+ ${DOCSDIR}/mysql
+ @${MKDIR} ${EXAMPLESDIR}
+.endif
+.endif
+.if defined(WITH_MYSQL)
+ @${INSTALL_DATA} ${FILESDIR}/mysql.data ${EXAMPLESDIR}
.endif
- @${SED} -e 's,%%PREFIX%%,${PREFIX},g' ${PKGMESSAGE}
+ @${SED} ${SED_SCRIPT} ${PKGMESSAGE}
.include <bsd.port.mk>
diff -ruN dspam.orig/files/mysql.data dspam/files/mysql.data
--- dspam.orig/files/mysql.data Thu Jan 1 01:00:00 1970
+++ dspam/files/mysql.data Thu Jan 8 19:40:28 2004
@@ -0,0 +1,5 @@
+/tmp/mysql.sock
+
+user
+password
+database
diff -ruN dspam.orig/pkg-message dspam/pkg-message
--- dspam.orig/pkg-message Mon Aug 4 13:38:19 2003
+++ dspam/pkg-message Thu Jan 8 19:33:46 2004
@@ -1,7 +1,16 @@
--------------------------------------------------------------------
- See the file %%PREFIX%%/share/doc/dspam/README for advice about
+ See the file %%DOCSDIR%%/README for advice about
how to configure DSPAM with your MTA. Examples are provided for
sendmail, exim and other popular MTAs.
+%%MYSQL%%
+%%MYSQL%% See %%DOCSDIR%%/mysql/README
+%%MYSQL%% for instructions on how to configure MySQL
+%%MYSQL%% for use with DSPAM.
+%%MYSQL%%
+%%MYSQL%% %%EXAMPLESDIR%%/mysql.data
+%%MYSQL%% contains an example configuration for use with MySQL.
+%%MYSQL%% Edit and install as
+%%MYSQL%% %%LOCALBASE%%/etc/dspam/mysql.data
--------------------------------------------------------------------
diff -ruN dspam.orig/pkg-plist dspam/pkg-plist
--- dspam.orig/pkg-plist Mon Dec 22 20:13:51 2003
+++ dspam/pkg-plist Thu Jan 8 19:33:46 2004
@@ -18,5 +18,12 @@
@comment lib/libdspam.la
%%PORTDOCS%%%%DOCSDIR%%/README
%%PORTDOCS%%%%DOCSDIR%%/CHANGE
+%%PORTDOCS%%%%MYSQL%%%%DOCSDIR%%/mysql/README
+%%PORTDOCS%%%%MYSQL%%%%DOCSDIR%%/mysql/mysql_objects.sql
+%%PORTDOCS%%%%MYSQL%%%%DOCSDIR%%/mysql/virtual_users.sql
+%%PORTDOCS%%%%MYSQL%%%%DOCSDIR%%/mysql/purge.sql
+%%PORTDOCS%%%%MYSQL%%@dirrm %%DOCSDIR%%/mysql
%%PORTDOCS%%@dirrm %%DOCSDIR%%
+%%MYSQL%%%%EXAMPLESDIR%%/mysql.data
+%%MYSQL%%@dirrm %%EXAMPLESDIR%%
@dirrm etc/dspam
--- dspam.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list