[pkg-dspam-commits] r59 - in trunk/debian: . config patches sqlfiles
Matthijs Mohlmann
active2-guest at costa.debian.org
Wed Dec 21 23:54:27 UTC 2005
Author: active2-guest
Date: Wed Dec 21 23:54:25 2005
New Revision: 59
Added:
trunk/debian/patches/autogen-sh.dpatch (contents, props changed)
trunk/debian/patches/ldap-verify-fix.dpatch (contents, props changed)
trunk/debian/sqlfiles/
trunk/debian/sqlfiles/mysql
trunk/debian/sqlfiles/pgsql
Modified:
trunk/debian/changelog
trunk/debian/config/mysql.conf
trunk/debian/dspam.init
trunk/debian/libdspam7-drv-mysql.install
trunk/debian/libdspam7-drv-pgsql.install
trunk/debian/patches/00list
trunk/debian/patches/link-dynamically.dpatch
trunk/debian/rules
Log:
* Add patch to fix ldap_verify bug
* Add autogen.sh patch to conform Steve Langasek 's mail to
debian-devel-announce at ..
* Updated link-dynamically patch to link all tools dynamically to libdspam7
* Updated debian/rules to call ./autogen.sh
* Fixed path in mysql.conf (mysqld/mysqld.sock instead of mysql/mysqld.sock)
* MySQL and PostgreSQL sql files needs to be a file not a directory with
files
* Daemon is in usr/bin update initscript <- maybe change the path of the
daemon to usr/sbin ?
Modified: trunk/debian/changelog
==============================================================================
--- trunk/debian/changelog (original)
+++ trunk/debian/changelog Wed Dec 21 23:54:25 2005
@@ -1,4 +1,18 @@
-dspam (3.6.2-1) unstable; urgency=low
+dspam (3.6.2-2) experimental; urgency=low
+
+ * Add patch to fix ldap_verify bug
+ * Add autogen.sh patch to conform Steve Langasek 's mail to
+ debian-devel-announce at ..
+ * Updated link-dynamically patch to link all tools dynamically to libdspam7
+ * Updated debian/rules to call ./autogen.sh
+ * Fixed path in mysql.conf (mysqld/mysqld.sock instead of mysql/mysqld.sock)
+ * MySQL and PostgreSQL sql files needs to be a file not a directory with
+ files
+ * Daemon is in usr/bin update initscript
+
+ -- Debian DSPAM Maintainers <pkg-dspam-misc at lists.alioth.debian.org> Thu, 22 Dec 2005 00:52:49 +0100
+
+dspam (3.6.2-1) experimental; urgency=low
* Initial release. (Closes: #195948)
Modified: trunk/debian/config/mysql.conf
==============================================================================
--- trunk/debian/config/mysql.conf (original)
+++ trunk/debian/config/mysql.conf Wed Dec 21 23:54:25 2005
@@ -4,7 +4,7 @@
# Storage driver settings: Specific to a particular storage driver. Uncomment
# the configuration specific to your installation, if applicable.
#
-MySQLServer /var/run/mysql/mysqld.sock
+MySQLServer /var/run/mysqld/mysqld.sock
#MySQLPort 3306
MySQLUser _DBC_DBUSER_
MySQLPass _DBC_DBPASS_
Modified: trunk/debian/dspam.init
==============================================================================
--- trunk/debian/dspam.init (original)
+++ trunk/debian/dspam.init Wed Dec 21 23:54:25 2005
@@ -19,7 +19,7 @@
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DESC="DSPAM Statistical anti-spam filter"
NAME=dspam
-DAEMON=/usr/sbin/$NAME
+DAEMON=/usr/bin/$NAME
PIDFILE=/var/run/$NAME.pid
SCRIPTNAME=/etc/init.d/$NAME
Modified: trunk/debian/libdspam7-drv-mysql.install
==============================================================================
--- trunk/debian/libdspam7-drv-mysql.install (original)
+++ trunk/debian/libdspam7-drv-mysql.install Wed Dec 21 23:54:25 2005
@@ -1,6 +1,5 @@
debian/tmp/usr/lib/libmysql_drv.so* usr/lib/dspam
-src/tools.mysql_drv/mysql_objects-4.1.sql usr/share/dbconfig-common/data/libdspam7-drv-mysql/install/mysql
-src/tools.mysql_drv/virtual_users.sql usr/share/dbconfig-common/data/libdspam7-drv-mysql/install/mysql
+debian/sqlfiles/mysql usr/share/dbconfig-common/data/libdspam7-drv-mysql/install
src/tools.mysql_drv/mysql_objects-4.1.sql usr/share/doc/libdspam7-drv-mysql/
src/tools.mysql_drv/mysql_objects-space.sql usr/share/doc/libdspam7-drv-mysql/
src/tools.mysql_drv/mysql_objects-speed.sql usr/share/doc/libdspam7-drv-mysql/
Modified: trunk/debian/libdspam7-drv-pgsql.install
==============================================================================
--- trunk/debian/libdspam7-drv-pgsql.install (original)
+++ trunk/debian/libdspam7-drv-pgsql.install Wed Dec 21 23:54:25 2005
@@ -1,6 +1,5 @@
debian/tmp/usr/lib/libpgsql_drv.so* usr/lib/dspam
-src/tools.pgsql_drv/pgsql_objects.sql usr/share/dbconfig-common/data/libdspam7-drv-pgsql/install/mysql
-src/tools.mysql_drv/virtual_users.sql usr/share/dbconfig-common/data/libdspam7-drv-pgsql/install/mysql
+debian/sqlfiles/pgsql usr/share/dbconfig-common/data/libdspam7-drv-pgsql/install
src/tools.pgsql_drv/pgsql_objects.sql usr/share/doc/libdspam7-drv-pgsql/
src/tools.pgsql_drv/virtual_users.sql usr/share/doc/libdspam7-drv-pgsql/
src/tools.pgsql_drv/purge.sql usr/share/doc/libdspam7-drv-pgsql/
Modified: trunk/debian/patches/00list
==============================================================================
--- trunk/debian/patches/00list (original)
+++ trunk/debian/patches/00list Wed Dec 21 23:54:25 2005
@@ -8,3 +8,5 @@
dspam-default.prefs-in_etc.dpatch
where-to-find-txt-files.dpatch
add-config-dir.dpatch
+ldap-verify-fix.dpatch
+autogen-sh.dpatch
Added: trunk/debian/patches/autogen-sh.dpatch
==============================================================================
--- (empty file)
+++ trunk/debian/patches/autogen-sh.dpatch Wed Dec 21 23:54:25 2005
@@ -0,0 +1,30 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## autogen-sh.dpatch by Matthijs Mohlmann <matthijs at cacholong.nl>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad dspam-3.6.2~/autogen.sh dspam-3.6.2/autogen.sh
+--- dspam-3.6.2~/autogen.sh 2005-09-11 03:52:57.000000000 +0200
++++ dspam-3.6.2/autogen.sh 2005-12-21 16:05:21.272130250 +0100
+@@ -12,8 +12,8 @@
+ if test x"${AUTOCONF}" != x -a -f ${AUTOCONF}
+ then
+ AUTOCONF=autoconf
+- AUTOMAKE=automake
+- ACLOCAL=aclocal
++ AUTOMAKE=automake-1.9
++ ACLOCAL=aclocal-1.9
+ if test x"${LIBTOOLIZE}" != x -a -f "${LIBTOOLIZE}"
+ then
+ LIBTOOLIZE=libtoolize
+@@ -37,7 +37,7 @@
+
+ GETTEXTIZE_FLAGS=--no-changelog
+ AUTOPOINT_FLAGS=
+-LIBTOOLIZE_FLAGS=
++LIBTOOLIZE_FLAGS="--copy --force"
+
+ # Some OS's require /usr/local/share/aclocal
+
Added: trunk/debian/patches/ldap-verify-fix.dpatch
==============================================================================
--- (empty file)
+++ trunk/debian/patches/ldap-verify-fix.dpatch Wed Dec 21 23:54:25 2005
@@ -0,0 +1,19 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## ldap-verify-fix.dpatch by Matthijs Mohlmann <matthijs at cacholong.nl>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: No description.
+
+ at DPATCH@
+diff -urNad dspam-3.6.2~/src/Makefile.am dspam-3.6.2/src/Makefile.am
+--- dspam-3.6.2~/src/Makefile.am 2005-10-11 16:05:52.000000000 +0200
++++ dspam-3.6.2/src/Makefile.am 2005-12-21 14:07:15.087682750 +0100
+@@ -69,7 +69,7 @@
+ # installed for libdspam
+ include_HEADERS = buffer.h config_shared.h decode.h error.h diction.h \
+ libdspam.h libdspam_objects.h nodetree.h tokenizer.h \
+- storage_driver.h heap.h config.h
++ storage_driver.h heap.h config.h ldap_client.h
+
+ # libdspam.a contans objects common for dspam and tools/* binaries
+ libdspam_la_SOURCES = \
Modified: trunk/debian/patches/link-dynamically.dpatch
==============================================================================
--- trunk/debian/patches/link-dynamically.dpatch (original)
+++ trunk/debian/patches/link-dynamically.dpatch Wed Dec 21 23:54:25 2005
@@ -5,9 +5,9 @@
## DP: Link dspam and dspamc dynamically to libdspam.
@DPATCH@
-diff -urNad trunk~/src/Makefile.am trunk/src/Makefile.am
---- trunk~/src/Makefile.am 2005-10-17 13:06:35.000000000 +0200
-+++ trunk/src/Makefile.am 2005-10-18 23:34:25.495613088 +0200
+diff -urNad dspam-3.6.2~/src/Makefile.am dspam-3.6.2/src/Makefile.am
+--- dspam-3.6.2~/src/Makefile.am 2005-10-11 16:05:52.000000000 +0200
++++ dspam-3.6.2/src/Makefile.am 2005-12-21 14:01:56.739787250 +0100
@@ -224,7 +224,6 @@
agent_shared.c agent_shared.h
@@ -24,3 +24,84 @@
# Failing of chgrp is expected and normal case when someone do
# make install DESTDIR=...
+diff -urNad dspam-3.6.2~/src/tools/Makefile.am dspam-3.6.2/src/tools/Makefile.am
+--- dspam-3.6.2~/src/tools/Makefile.am 2005-09-24 02:37:44.000000000 +0200
++++ dspam-3.6.2/src/tools/Makefile.am 2005-12-21 14:04:19.236692750 +0100
+@@ -14,19 +14,19 @@
+ bin_SCRIPTS = dspam_corpus dspam_genaliases dspam_logrotate
+
+ dspam_2sql_SOURCES = dspam_2sql.c ../read_config.c ../config_api.c
+-dspam_2sql_LDFLAGS = -static
++dspam_2sql_LDFLAGS =
+ dspam_dump_SOURCES = dspam_dump.c ../read_config.c ../config_api.c
+-dspam_dump_LDFLAGS = -static
++dspam_dump_LDFLAGS =
+ dspam_clean_SOURCES = dspam_clean.c ../read_config.c ../config_api.c
+-dspam_clean_LDFLAGS = -static
++dspam_clean_LDFLAGS =
+ dspam_crc_SOURCES = dspam_crc.c
+-dspam_crc_LDFLAGS = -static
++dspam_crc_LDFLAGS =
+ dspam_stats_SOURCES = dspam_stats.c ../read_config.c ../config_api.c
+-dspam_stats_LDFLAGS = -static
++dspam_stats_LDFLAGS =
+ dspam_merge_SOURCES = dspam_merge.c ../read_config.c ../config_api.c
+-dspam_merge_LDFLAGS = -static
++dspam_merge_LDFLAGS =
+ dspam_admin_SOURCES = dspam_admin.c ../read_config.c ../config_api.c
+-dspam_admin_LDFLAGS = -static
++dspam_admin_LDFLAGS =
+
+ LDADD = ../libdspam.la
+
+diff -urNad dspam-3.6.2~/src/tools.hash_drv/Makefile.am dspam-3.6.2/src/tools.hash_drv/Makefile.am
+--- dspam-3.6.2~/src/tools.hash_drv/Makefile.am 2005-10-25 14:32:09.000000000 +0200
++++ dspam-3.6.2/src/tools.hash_drv/Makefile.am 2005-12-21 14:03:51.042930750 +0100
+@@ -19,7 +19,7 @@
+ cssstat_SOURCES = cssstat.c ../read_config.c ../util.c ../diction.c \
+ ../nodetree.c ../hash_drv.c ../error.c ../config_shared.c \
+ ../pref.c
+-cssstat_LDFLAGS = -static
++cssstat_LDFLAGS =
+ if DYNAMIC_DRIVER
+ if BUILD_HASH_DRV
+ cssstat_CPPFLAGS = $(libhash_drv_cppflags)
+@@ -30,7 +30,7 @@
+ cssclean_SOURCES = cssclean.c ../read_config.c ../util.c ../diction.c \
+ ../nodetree.c ../hash_drv.c ../error.c ../config_shared.c \
+ ../pref.c
+-cssclean_LDFLAGS = -static
++cssclean_LDFLAGS =
+ if DYNAMIC_DRIVER
+ if BUILD_HASH_DRV
+ cssclean_CPPFLAGS = $(libhash_drv_cppflags)
+@@ -41,7 +41,7 @@
+ cssconvert_SOURCES = cssconvert.c ../read_config.c ../util.c ../diction.c \
+ ../nodetree.c ../hash_drv.c ../error.c ../config_shared.c \
+ ../pref.c
+-cssconvert_LDFLAGS = -static
++cssconvert_LDFLAGS =
+ if DYNAMIC_DRIVER
+ if BUILD_HASH_DRV
+ cssconvert_CPPFLAGS = $(libhash_drv_cppflags)
+@@ -52,7 +52,7 @@
+ csscompress_SOURCES = csscompress.c ../read_config.c ../util.c ../diction.c \
+ ../nodetree.c ../hash_drv.c ../error.c ../config_shared.c \
+ ../pref.c
+-csscompress_LDFLAGS = -static
++csscompress_LDFLAGS =
+ if DYNAMIC_DRIVER
+ if BUILD_HASH_DRV
+ csscompress_CPPFLAGS = $(libhash_drv_cppflags)
+diff -urNad dspam-3.6.2~/src/tools.pgsql_drv/Makefile.am dspam-3.6.2/src/tools.pgsql_drv/Makefile.am
+--- dspam-3.6.2~/src/tools.pgsql_drv/Makefile.am 2005-09-24 19:54:11.000000000 +0200
++++ dspam-3.6.2/src/tools.pgsql_drv/Makefile.am 2005-12-21 14:03:26.305384750 +0100
+@@ -17,7 +17,7 @@
+ -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -D_GNU_SOURCE
+
+ dspam_pg2int8_SOURCES = dspam_pg2int8.c ../read_config.c ../config_api.c
+-dspam_pg2int8_LDFLAGS = -static
++dspam_pg2int8_LDFLAGS =
+ if DYNAMIC_DRIVER
+ if BUILD_PGSQL_DRV
+ dspam_pg2int8_CPPFLAGS = $(libpgsql_drv_cppflags)
Modified: trunk/debian/rules
==============================================================================
--- trunk/debian/rules (original)
+++ trunk/debian/rules Wed Dec 21 23:54:25 2005
@@ -66,6 +66,7 @@
dh_testdir
# Add here commands to configure the package.
mkdir build--tmp
+ ./autogen.sh
(cd build--tmp && CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" ../configure $(CONFIGURE))
touch configure-stamp
Added: trunk/debian/sqlfiles/mysql
==============================================================================
--- (empty file)
+++ trunk/debian/sqlfiles/mysql Wed Dec 21 23:54:25 2005
@@ -0,0 +1,49 @@
+# Tables for mysql
+create table dspam_token_data (
+ uid smallint unsigned not null,
+ token bigint unsigned not null,
+ spam_hits int not null,
+ innocent_hits int not null,
+ last_hit date not null
+) type=MyISAM PACK_KEYS=1;
+
+create unique index id_token_data_01 on dspam_token_data(uid,token);
+
+create table dspam_signature_data (
+ uid smallint unsigned not null,
+ signature char(32) not null,
+ data blob not null,
+ length smallint not null,
+ created_on date not null
+) type=MyISAM max_rows=2500000 avg_row_length=8096;
+
+create unique index id_signature_data_01 on dspam_signature_data(uid,signature);create index id_signature_data_02 on dspam_signature_data(created_on);
+
+create table dspam_stats (
+ uid smallint unsigned primary key,
+ spam_learned int not null,
+ innocent_learned int not null,
+ spam_misclassified int not null,
+ innocent_misclassified int not null,
+ spam_corpusfed int not null,
+ innocent_corpusfed int not null,
+ spam_classified int not null,
+ innocent_classified int not null
+) type=MyISAM;
+
+create table dspam_preferences (
+ uid smallint unsigned not null,
+ preference varchar(32) not null,
+ value varchar(64) not null
+) type=MyISAM;
+
+create unique index id_preferences_01 on dspam_preferences(uid, preference);
+
+# Create the virtual users table.
+create table dspam_virtual_uids (
+ uid smallint unsigned primary key AUTO_INCREMENT,
+ username varchar(128)
+) type=MyISAM;
+
+create unique index id_virtual_uids_01 on dspam_virtual_uids(username);
+
Added: trunk/debian/sqlfiles/pgsql
==============================================================================
--- (empty file)
+++ trunk/debian/sqlfiles/pgsql Wed Dec 21 23:54:25 2005
@@ -0,0 +1,85 @@
+# Tables for postgresql
+CREATE TABLE dspam_token_data (
+ uid smallint,
+ token bigint,
+ spam_hits int,
+ innocent_hits int,
+ last_hit date,
+ UNIQUE (uid, token)
+) WITHOUT OIDS;
+
+CREATE TABLE dspam_signature_data (
+ uid smallint,
+ signature varchar(128),
+ data bytea,
+ length int,
+ created_on date,
+ UNIQUE (uid, signature)
+) WITHOUT OIDS;
+
+CREATE TABLE dspam_stats (
+ uid smallint PRIMARY KEY,
+ spam_learned int,
+ innocent_learned int,
+ spam_misclassified int,
+ innocent_misclassified int,
+ spam_corpusfed int,
+ innocent_corpusfed int,
+ spam_classified int,
+ innocent_classified int
+) WITHOUT OIDS;
+
+CREATE TABLE dspam_neural_data (
+ uid smallint,
+ node smallint,
+ total_correct int,
+ total_incorrect int,
+ UNIQUE (node, uid)
+) WITHOUT OIDS;
+
+CREATE INDEX id_neural_data_01 ON dspam_neural_data(uid);
+
+CREATE TABLE dspam_neural_decisions (
+ uid smallint,
+ signature varchar(128),
+ data bytea,
+ length int,
+ created_on date,
+ UNIQUE (signature, uid)
+) WITHOUT OIDS;
+
+CREATE TABLE dspam_preferences (
+ uid smallint,
+ preference varchar(128),
+ value varchar(128),
+ UNIQUE (uid, preference)
+) WITHOUT OIDS;
+
+CREATE SEQUENCE dspam_virtual_uids_seq;
+
+CREATE TABLE dspam_virtual_uids (
+ uid smallint DEFAULT nextval('dspam_virtual_uids_seq') PRIMARY KEY,
+ username varchar(128)
+) WITHOUT OIDS;
+
+CREATE UNIQUE INDEX id_virtual_uids_01 ON dspam_virtual_uids(username);
+CREATE UNIQUE INDEX id_virtual_uids_02 ON dspam_virtual_uids(uid);
+
+create function lookup_tokens(integer,bigint[])
+ returns setof dspam_token_data
+ language plpgsql stable
+ as '
+declare
+ v_rec record;
+begin
+ for v_rec in select * from dspam_token_data
+ where uid=$1
+ and token in (select $2[i]
+ from generate_series(array_lower($2,1),
+ array_upper($2,1)) s(i))
+ loop
+ return next v_rec;
+ end loop;
+ return;
+end;';
+
More information about the Pkg-dspam-commits
mailing list