ports/93361: [MAINTAINER] mail/dspam: update to 3.6.4 and various fixes.

Ion-Mihai IOnut Tetcu itetcu at people.tecnik93.com
Tue Feb 14 22:00:21 UTC 2006


>Number:         93361
>Category:       ports
>Synopsis:       [MAINTAINER] mail/dspam: update to 3.6.4 and various fixes.
>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:   Tue Feb 14 22:00:18 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Ion-Mihai "IOnut" Tetcu
>Release:        FreeBSD 6.1-PRERELEASE i386
>Organization:
Tecnik'93 
>Environment:


System: FreeBSD 6.1-PRERELEASE #1: Tue Feb  7 00:58:32 EET 2006


>Description:


Update to stable 3.6.4 release [1]:
======================

Port changes:
- Drop NEURAL_NET (removed upstream) and TRAIN_SCRIPT (now always 
installed and depend on PERL5 for it).
- Fix removal of EXAMPLESDIR on pkg-plist [2]
- Fix spelling in pkg-message and UPDATING
- Some Makefile cleanup
- drop RC_SUFX in Makefile, USE_RC_SUBR= ${PORTNAME} [3] and move 
files/dspam.sh.in ---> files/dspam.in [4] 

Note: 
	Ideally [4] should be a repo-copy, but just use 'cvs rm' and 'add' 
	if the repo-copy means waiting to much.


BugFixes:
- accuracy fixes (esp. for FP dspam is much better that in 3.6.3 release)
- safeguards for segfault when strange clamav behavior
- for no output when using --classify in client/server mode
- LOG_WARNING if truncating MySQL user/pass + plus othersmall fixes

New features:
- dspam_train: a true training and testing mechanism, useful for building
pretrained databases or training a user with their own corpus. also provides
a test jig for measuring efficiency/accuracy with a corpus over a
configuration; support for training using an index file to define the order
of ham/spam
- DeliveryHost for delivery to different hosts based on domain
- ClassAlias options, useful if classifying things other than spam
- WebUI: undo option for retraining
- WebUI: support for existing storeFragments option to recall message in
history
- WebUI: mass-retraining option
- Documentation: of all user preferences in the README

Changed features:
- dspam-statrs: changed names; now displays TP (true positives),
TN (true negatives), FN (false negatives), and FP (false positives),
OCA (Overall Accuracy)
- dspam_corpus now uses default settings for features and training modes,
instead of its own and now requires --spam or --nonspam arguments
- the trainining buffer (Feature tb=n in dspam.conf) is now offby default
- dspam.conf: HashRec sizes prime numbers for better spread
- no signature on classify
- ignore X-DSPAM-* in tokenizer code

Removed features:
- removed neural networking (NEURAL_NET), which was experimental, needed a
rewrite, had no support and high maintenance


Obtained from:		garga via mail/dspam-devel [2]
Requested by:		dougb [3]
Tested on	:		tinderbox-2.2.1_2 on 6-STABLE [1]


>How-To-Repeat:





>Fix:


--- dspam-3.6.3_to_3.6.4.diff begins here ---
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/mail/dspam/Makefile,v
retrieving revision 1.49
diff -u -r1.49 Makefile
--- Makefile	10 Feb 2006 17:06:24 -0000	1.49
+++ Makefile	14 Feb 2006 21:37:08 -0000
@@ -20,9 +20,11 @@
 MAINTAINER=	itetcu at people.tecnik93.com
 COMMENT=	Bayesian spam filter - stable maintenance version
 
-PORTVER_MAJ=	3.6.3
+PORTVER_MAJ=	3.6.4
 #SNAP_DATE=	.20051211.2134
 
+MIN_OPTIONS_VER=	${PORTNAME}-3.6.4
+
 .ifdef(SNAP_DATE)
 MASTER_SITES=	http://people.tecnik93.com/~itetcu/FreeBSD/ports/${PORTNAME}/sources/
 WRKSRC=		${WRKDIR}/dspam-${SNAP_DATE}
@@ -42,10 +44,6 @@
 OPTIONS+=	BNR_DEBUG "Enable debug for BNR" off
 OPTIONS+=	PREF_EXT "Preferences in database not in files" off
 OPTIONS+=	DAEMON "Daemonize dspam; speaks LMTP or DLMTP" on
-
-## algorithm options
-OPTIONS+=	NEURAL_NET "Enable neural networking" off
-
 #
 OPTIONS+=	CLAMAV "Enable clamav support" on
 OPTIONS+=	CLAMAV_DEVEL "Enable clamav support" off
@@ -87,8 +85,8 @@
 OPTIONS+=	QMAIL "Play nice with Qmail mail server" off
 
 OPTIONS+=	CGI "Install CGI (pulls in apache)" off
-OPTIONS+=	TRAIN_SCRIPT "Install trainning script (needs perl)" off
 
+USE_PERL5=	yes
 USE_AUTOTOOLS=	libtool:15
 INSTALLS_SHLIB=	yes
 GNU_CONFIGURE=	yes
@@ -163,18 +161,13 @@
 
 .ifdef(WITH_DAEMON)
 CONFIGURE_ARGS+=	--enable-daemon
-RC_SUFX=	.sh
-USE_RC_SUBR=	${PORTNAME}${RC_SUFX}
+USE_RC_SUBR=	${PORTNAME}
 _SED_SCRIPT+=	-e 's,%%DAEMON%%,,g'
 SUB_LIST+=	DSPAM_HOME=${DSPAM_HOME}
 .else
 _SED_SCRIPT+=	-e '/%%DAEMON%%/D'
 .endif
 
-.ifdef(WITH_NEURAL_NET)
-CONFIGURE_ARGS+=	--enable-neural-networking
-.endif
-
 .ifdef(WITH_CLAMAV) && defined(WITH_CLAMAV_LOCAL)
 CONFIGURE_ARGS+=	--enable-clamav
 RUN_DEPENDS+=	clamav>=0:${PORTSDIR}/security/clamav
@@ -422,15 +415,8 @@
 _SED_SCRIPT+=	-e '/%%CGI%%/D'
 .endif
 
-.ifdef(WITH_TRAIN_SCRIPT)
-USE_PERL5=	yes
-PLIST_SUB+=	TRAIN_SCRIPT=""
-.else
-PLIST_SUB+=	TRAIN_SCRIPT="@comment "
-.endif
-
 MAN1=	dspam.1 dspam_clean.1 dspam_corpus.1 dspam_dump.1 dspam_merge.1 \
-	dspam_stats.1
+	dspam_stats.1 dspam_train.1
 MAN3=	libdspam.3
 MLINKS=		libdspam.3 dspam_init.3
 MLINKS+=	libdspam.3 dspam_create.3
@@ -446,21 +432,17 @@
 	pgsql_drv.txt pop3filter.txt postfix.txt qmail.txt relay.txt \
 	sendmail.txt sqlite_drv.txt
 
-.ifndef(MAINT)
 pre-everything::
+.ifndef(MAINT)
 	@${ECHO_CMD} ""
 	@${ECHO_CMD} "Last ${FILESDIR}/UPDATING entry:"
 	@${GREP} -B 1 -A ${_UPD_LINE_NO} ${PKGNAME} ${FILESDIR}/UPDATING
 	@${ECHO_CMD} ""
 	@sleep 5
-.else # maintainer only
-post-fetch:
-.	ifndef(STOP)
-#.		include "/root/ports/upd"
-.	endif
 .endif
 
-pre-extract: check-options-version
+pre-extract:	check-options-version
+.ifndef(MAINT)
 	@${ECHO_CMD} ""
 	@${ECHO_CMD} "Define vars below before make-ing if you need:"
 	@${ECHO_CMD} ""
@@ -480,6 +462,7 @@
 .	endif
 	@${ECHO_CMD} ""
 	@sleep 5
+.endif
 
 post-patch:
 	@${REINPLACE_CMD} -e 's|where @a-14 > to_days(created_on);|where @a-${SIGNATURE_LIFE} > to_days(created_on);|' \
@@ -494,10 +477,7 @@
 		${WRKSRC}/src/tools.sqlite_drv/purge-2.sql
 	@${REINPLACE_CMD} -e "s|where julianday('now')-julianday(created_on) > 14;|where julianday('now')-julianday(created_on) > ${SIGNATURE_LIFE};|" \
 		 ${WRKSRC}/src/tools.sqlite_drv/purge-3.sql
-
-.ifdef(WITH_TRAIN_SCRIPT)
-	 @${REINPLACE_CMD} -e "s^%%PERL%%^${PERL}^; s^%%DSPAM_PATH%%^${PREFIX}/bin^" ${WRKSRC}/scripts/train.pl
-.endif
+	@${REINPLACE_CMD} -e "s^%%PERL%%^${PERL}^; s^%%DSPAM_PATH%%^${PREFIX}/bin^" ${WRKSRC}/scripts/train.pl
 
 pre-configure:
 	@${ECHO_CMD}
@@ -511,11 +491,6 @@
 	@${ECHO_CMD} "You need to enable at least one database back-end."
 	@${FALSE}
 .endif
-.if defined(WITH_NEURAL_NET) && \
-	!( defined(USE_MYSQL) || defined(WITH_POSTGRESQL) )
-	@${ECHO_CMD} "You need MySQL or POSTGRESQL to use neural networking."
-	@${FALSE}
-.endif
 .if defined(WITH_VIRT_USERS) && !(defined(USE_MYSQL) || \
 	defined(WITH_POSTGRESQL) || defined(WITH_ORACLE) || defined(WITH_HASH) )
 	@${ECHO_CMD} "You need MySQL, POSTGRESQL or ORACLE for virtual users."
@@ -568,7 +543,6 @@
 		${INSTALL_DATA} mysql_objects-4.1.sql \
 			mysql_objects-space.sql \
 			mysql_objects-speed.sql \
-			neural.sql \
 			purge-4.1.sql purge.sql \
 			virtual_user_aliases.sql \
 			virtual_users.sql ${EXAMPLESDIR}/mysql
@@ -606,11 +580,6 @@
 		${INSTALL_DATA} admins ${CGI_PATH}/admins.sample
 	${MKDIR} ${CGI_PATH}/templates && cd ${WRKSRC}/webui/cgi-bin/templates && \
 		${INSTALL_DATA} *.html ${CGI_PATH}/templates/
-.endif
-
-.ifdef(WITH_TRAIN_SCRIPT)
-	cd ${WRKSRC}/scripts && \
-		${INSTALL_SCRIPT} train.pl ${PREFIX}/bin/dspam_train
 .endif
 
 	@${SED} ${_SED_SCRIPT} ${.CURDIR}/pkg-message > ${WRKSRC}/README.FreeBSD
Index: distinfo
===================================================================
RCS file: /home/ncvs/ports/mail/dspam/distinfo,v
retrieving revision 1.26
diff -u -r1.26 distinfo
--- distinfo	2 Feb 2006 19:00:25 -0000	1.26
+++ distinfo	14 Feb 2006 21:37:08 -0000
@@ -1,3 +1,3 @@
-MD5 (dspam-3.6.3.tar.gz) = db1aedb9677e6bf5c7a47a72d4f130e5
-SHA256 (dspam-3.6.3.tar.gz) = 6283c067c192f589a4fb925b845ba1bd9b51fe1b3df93d7f03897d7617a4aa7a
-SIZE (dspam-3.6.3.tar.gz) = 740097
+MD5 (dspam-3.6.4.tar.gz) = e5e5d4beeea8d067aee9ad373c20cb22
+SHA256 (dspam-3.6.4.tar.gz) = 86868379d4f7ad4be8d039c9d8610739e7701f5602d0f67a3a7a059ea6865f16
+SIZE (dspam-3.6.4.tar.gz) = 743467
Index: pkg-message
===================================================================
RCS file: /home/ncvs/ports/mail/dspam/pkg-message,v
retrieving revision 1.8
diff -u -r1.8 pkg-message
--- pkg-message	2 Feb 2006 19:00:25 -0000	1.8
+++ pkg-message	14 Feb 2006 21:37:08 -0000
@@ -8,8 +8,8 @@
  uname -a, dspam --version, %%_VAR_DIR%%/db/ports/%%PORTNAME%%/options, MTA setup.
 
 Asking about updates or telling me there is one: not only I am active on the
-mailing lists but I also track dspam cvs so I already know; either there is a
-problem with the new version or I didn't have enough time to patch the port
+mailing lists and IRC but I also track dspam CVS so I already know; either there
+is a problem with the new version or I didn't have enough time to patch the port
 and _test_ the new version; please report your succes/failure if you run the
 new version or the cvs version.
 
Index: pkg-plistqfaxreader-0.3RC9
===================================================================
RCS file: /home/ncvs/ports/mail/dspam/pkg-plist,v
retrieving revision 1.17
diff -u -r1.17 pkg-plist
--- pkg-plist	2 Feb 2006 19:00:25 -0000	1.17
+++ pkg-plist	14 Feb 2006 21:37:08 -0000
@@ -15,7 +15,7 @@
 bin/dspam_merge
 %%PGSQL%%bin/dspam_pg2int8
 bin/dspam_stats
-%%TRAIN_SCRIPT%%bin/dspam_train
+bin/dspam_train
 @unexec if cmp -s %D/etc/dspam.conf %D/etc/dspam.conf.sample; then rm -f %D/etc/dspam.conf; fi
 etc/dspam.conf.sample
 include/dspam/buffer.h
@@ -69,22 +69,19 @@
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/mysql_objects-4.1.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/mysql_objects-space.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/mysql_objects-speed.sql
-%%MYSQL%%%%EXAMPLESDIR%%/mysql/neural.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/purge-4.1.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/purge.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/virtual_user_aliases.sql
 %%MYSQL%%%%EXAMPLESDIR%%/mysql/virtual_users.sql
 %%MYSQL%%@dirrm %%EXAMPLESDIR%%/mysql
-%%MYSQL%%@dirrm %%EXAMPLESDIR%%
 %%PGSQL%%%%EXAMPLESDIR%%/pgsql/pgsql_objects.sql
 %%PGSQL%%%%EXAMPLESDIR%%/pgsql/purge.sql
 %%PGSQL%%%%EXAMPLESDIR%%/pgsql/virtual_users.sql
 %%PGSQL%%@dirrm %%EXAMPLESDIR%%/pgsql
-%%PGSQL%%@dirrm %%EXAMPLESDIR%%
 %%SQLITE%%%%EXAMPLESDIR%%/sqlite/purge-2.sql
 %%SQLITE%%%%EXAMPLESDIR%%/sqlite/purge-3.sql
 %%SQLITE%%@dirrm %%EXAMPLESDIR%%/sqlite
-%%SQLITE%%@dirrm %%EXAMPLESDIR%%
+ at dirrmtry %%EXAMPLESDIR%%
 %%CGI%%www/vhosts/dspam/admins.sample
 %%CGI%%www/vhosts/dspam/admin.cgi
 %%CGI%%www/vhosts/dspam/admingraph.cgi
Index: files/UPDATING
===================================================================
RCS file: /home/ncvs/ports/mail/dspam/files/UPDATING,v
retrieving revision 1.21
diff -u -r1.21 UPDATING
--- files/UPDATING	10 Feb 2006 17:06:24 -0000	1.21
+++ files/UPDATING	14 Feb 2006 21:37:08 -0000
@@ -17,6 +17,46 @@
 make extract;  more `find . -type f -maxdepth 2 -name UPGRADING`
 
 ###########################################################################
+# dspam-3.6.4
+#
+
+BugFixes:
+- accuracy fixes (esp. for FP dspam is much better that in 3.6.3 release)
+- safeguards for segfault when strange clamav behavior
+- for no output when using --classify in client/server mode
+- LOG_WARNING if truncating MySQL user/pass + plus othersmall fixes
+
+New features:
+- dspam_train: a true training and testing mechanism, useful for building
+pretrained databases or training a user with their own corpus. also provides
+a test jig for measuring efficiency/accuracy with a corpus over a
+configuration; support for training using an index file to define the order
+of ham/spam
+- DeliveryHost for delivery to different hosts based on domain
+- ClassAlias options, useful if classifying things other than spam
+- WebUI: undo option for retraining
+- WebUI: support for existing storeFragments option to recall message in
+history
+- WebUI: mass-retraining option
+- Documentation: of all user preferences in the README
+
+Changed features:
+- dspam-statrs: changed names; now displays TP (true positives),
+TN (true negatives), FN (false negatives), and FP (false positives),
+OCA (Overall Accuracy)
+- dspam_corpus now uses default settings for features and training modes,
+instead of its own and now requires --spam or --nonspam arguments
+- the trainining buffer (Feature tb=n in dspam.conf) is now offby default
+- dspam.conf: HashRec sizes prime numbers for better spread
+- no signature on classify
+- ignore X-DSPAM-* in tokenizer code
+
+Removed features:
+- removed neural networking (NEURAL_NET), which was experimental, needed a
+rewrite, had no support and high maintenance
+
+
+###########################################################################
 # dspam-3.6.3
 #
 
Index: files/dspam.in
===================================================================
RCS file: files/dspam.in
diff -N files/dspam.in
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/dspam.in	14 Feb 2006 21:37:08 -0000
@@ -0,0 +1,42 @@
+#!/bin/sh
+# $FreeBSD: ports/mail/dspam/files/dspam.sh.in,v 1.5 2006/02/10 17:06:24 garga Exp $
+# formerly $ FreeBSD: ports/mail/dspam/files/dspam,v 1.1 2005/05/05 21:03:37 pav Exp $
+# $Tecnik: ports/mail/dspam/files/dspam.sh.in,v 1.6 2006/02/09 19:14:29 itetcu Exp $
+#
+
+# PROVIDE: dspam
+# REQUIRE: DAEMON %%MYSQL%% %%PGSQL%% %%CLAMD%%
+# BEFORE: mail
+# KEYWORD: shutdown
+
+#
+# Add the following lines to /etc/rc.conf[.local] to enable dspam:
+#
+# dspam_enable="YES"
+# you can also set the pid file via dspam_pidfile
+#
+
+. %%RC_SUBR%%
+
+name=dspam
+rcvar=`set_rcvar`
+
+load_rc_config $name
+
+
+: ${dspam_enable="NO"}
+: ${dspam_pidfile:-/var/run/dspam.pid}
+
+command=%%PREFIX%%/bin/${name}
+command_args="--daemon  > /dev/null 2>&1 &"
+required_dirs=%%DSPAM_HOME%%
+required_files=%%PREFIX%%/etc/${name}.conf
+
+extra_commands=reload
+
+reload()
+{
+ kill -HUP `cat $pidfile`
+}
+
+run_rc_command "$1"
Index: files/dspam.sh.in
===================================================================
RCS file: files/dspam.sh.in
diff -N files/dspam.sh.in
--- files/dspam.sh.in	10 Feb 2006 17:06:24 -0000	1.5
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,42 +0,0 @@
-#!/bin/sh
-# $FreeBSD: ports/mail/dspam/files/dspam.sh.in,v 1.5 2006/02/10 17:06:24 garga Exp $
-# formerly $ FreeBSD: ports/mail/dspam/files/dspam,v 1.1 2005/05/05 21:03:37 pav Exp $
-# $Tecnik: ports/mail/dspam/files/dspam.sh.in,v 1.6 2006/02/09 19:14:29 itetcu Exp $
-#
-
-# PROVIDE: dspam
-# REQUIRE: DAEMON %%MYSQL%% %%PGSQL%% %%CLAMD%%
-# BEFORE: mail
-# KEYWORD: shutdown
-
-#
-# Add the following lines to /etc/rc.conf[.local] to enable dspam:
-#
-# dspam_enable="YES"
-# you can also set the pid file via dspam_pidfile
-#
-
-. %%RC_SUBR%%
-
-name=dspam
-rcvar=`set_rcvar`
-
-load_rc_config $name
-
-
-: ${dspam_enable="NO"}
-: ${dspam_pidfile:-/var/run/dspam.pid}
-
-command=%%PREFIX%%/bin/${name}
-command_args="--daemon  > /dev/null 2>&1 &"
-required_dirs=%%DSPAM_HOME%%
-required_files=%%PREFIX%%/etc/${name}.conf
-
-extra_commands=reload
-
-reload()
-{
- kill -HUP `cat $pidfile`
-}
-
-run_rc_command "$1"
--- dspam-3.6.3_to_3.6.4.diff ends here ---



>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list