--- dbmail-2.2.11.orig/debian/changelog
+++ dbmail-2.2.11/debian/changelog
@@ -1,8 +1,10 @@
 dbmail (2.2.11-1) unstable; urgency=low
 
   * upstream release
+  * add swedish PO file (Closes: #513652)
+  * fix ftbfs on hurd (Closes: #481268)
 
- -- Paul J Stevens <paul@nfg.nl>  Mon, 02 Feb 2009 15:21:31 +0100
+ -- Paul J Stevens <paul@nfg.nl>  Mon, 02 Feb 2009 16:33:50 +0100
 
 dbmail (2.2.10-1) unstable; urgency=low
 
--- dbmail-2.2.11.orig/debian/control
+++ dbmail-2.2.11/debian/control
@@ -3,12 +3,12 @@
 Priority: optional
 Maintainer: Paul J Stevens <paul@nfg.nl>
 Build-Depends: automake1.9, debhelper (>= 5.0.7), dpatch, libsieve2-dev (>= 2.1.12), libglib2.0-dev, libgmime-2.0-2-dev | libgmime2.1-dev, libldap2-dev, libsqlite3-dev, libpq-dev, libmysqlclient15-dev | libmysqlclient14-dev, pkg-config, libtool, asciidoc, xmlto, chrpath, po-debconf
-Standards-Version: 3.7.3
+Standards-Version: 3.8.0
 
 Package: dbmail
 Architecture: any
 Pre-Depends: adduser
-Depends: ${misc:Depends}, ${shlibs:Depends}, ucf (>= 0.30)
+Depends: ${shlibs:Depends}, ${misc:Depends}, ucf (>= 0.30), debconf (>= 0.5) | debconf-2.0
 Provides: imap-server, pop3-server
 Suggests: dbmail-pgsql | dbmail-mysql, sqlite3
 Description: base package for the dbmail email solution
@@ -24,7 +24,7 @@
 
 Package: dbmail-pgsql
 Architecture: any
-Depends: ${misc:Depends}, ${shlibs:Depends}, dbmail (= ${binary:Version})
+Depends: ${shlibs:Depends}, ${misc:Depends}, dbmail (= ${binary:Version})
 Description: PostgreSQL module for Dbmail
  This package provides a module for adding PostgreSQL database 
  support to DBMAIL.
@@ -34,7 +34,7 @@
 
 Package: dbmail-mysql
 Architecture: any
-Depends: ${misc:Depends}, ${shlibs:Depends}, dbmail (= ${binary:Version})
+Depends: ${shlibs:Depends}, ${misc:Depends}, dbmail (= ${binary:Version})
 Description: MySQL module for Dbmail
  This package provides a module for adding MySQL database 
  support to DBMAIL.
--- dbmail-2.2.11.orig/debian/dbmail.postrm
+++ dbmail-2.2.11/debian/dbmail.postrm
@@ -1,5 +1,7 @@
 #!/bin/sh
 
+set -e
+
 if [ -f /usr/share/debconf/confmodule ]; then
 	. /usr/share/debconf/confmodule
 fi
@@ -7,15 +9,15 @@
 
 if [ "$1" = "purge" ]; then
 		
-	rm -f /etc/dbmail/dbmail.conf || true
-	rm -f /etc/default/dbmail || true
+	rm -f /etc/dbmail/dbmail.conf
+	rm -f /etc/default/dbmail
 	
-	ucf --purge /etc/dbmail/dbmail.conf || true
-	ucf --purge /etc/default/dbmail || true
+	ucf --purge /etc/dbmail/dbmail.conf
+	ucf --purge /etc/default/dbmail
 
-	userdel dbmail 2>&1 > /dev/null || true
+	userdel dbmail 2>&1 > /dev/null
 
-	db_purge || true
+	db_purge
 fi
 
 #DEBHELPER#
--- dbmail-2.2.11.orig/debian/dbmail.dirs
+++ dbmail-2.2.11/debian/dbmail.dirs
@@ -1,2 +1,4 @@
 usr/lib
 usr/share/dbmail
+var/log/dbmail
+var/run/dbmail
--- dbmail-2.2.11.orig/debian/rules
+++ dbmail-2.2.11/debian/rules
@@ -142,9 +142,9 @@
 	dh_link -a
 	dh_compress -a
 	dh_fixperms -a
-	dh_installdeb -a
-	dh_makeshlibs -a
+	dh_makeshlibs -a --exclude=usr/lib/dbmail
 	dh_shlibdeps -a
+	dh_installdeb -a
 	dh_gencontrol -a
 	dh_md5sums -a 
 	dh_builddeb -a
--- dbmail-2.2.11.orig/debian/copyright
+++ dbmail-2.2.11/debian/copyright
@@ -5,13 +5,13 @@
 
 Copyright (C) 1999-2004 IC & S, dbmail@ic-s.nl
 Copyright (C) 2001-2006 Aaron Stone, aaron@serendipity.cx
-Copyright (C) 2004-2006 NFG Net Facilities Group BV, support@nfg.nl
+Copyright (C) 2004-2009 NFG Net Facilities Group BV, support@nfg.nl
 
 Authors: DBmail Development Team <dbmail-dev@dbmail.org>
 
 This code is released under the terms of the GNU GENERAL PUBLIC LICENSE.
 On Debian GNU/Linux systems, the text of the GPL can be found in
-/usr/share/common-licenses/GPL.
+/usr/share/common-licenses/GPL-2.
 
 
 
--- dbmail-2.2.11.orig/debian/patches/00-dbmail_conf.dpatch
+++ dbmail-2.2.11/debian/patches/00-dbmail_conf.dpatch
@@ -2,7 +2,7 @@
 ## 00-dbmail_conf.dpatch by  <paul@nfg.nl>
 ##
 ## All lines beginning with `## DP:' are a description of the patch.
-## DP: No description.
+## DP: prepare a sane debian compliant config file
 
 @DPATCH@
 diff -urNad dbmail-2.2.5~/dbmail.conf dbmail-2.2.5/dbmail.conf
--- dbmail-2.2.11.orig/debian/patches/00list
+++ dbmail-2.2.11/debian/patches/00list
@@ -2,6 +2,7 @@
 # 
 # paths and effective user/group
 00-dbmail_conf
+01-sa-siginfo-undeclared
 
 # etch
 #00-etch
--- dbmail-2.2.11.orig/debian/patches/01-sa-siginfo-undeclared.dpatch
+++ dbmail-2.2.11/debian/patches/01-sa-siginfo-undeclared.dpatch
@@ -0,0 +1,128 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 01-sa-siginfo-undeclared.dpatch by  <paul@nfg.nl>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: fix FTBFS on Hurd due to missing SA_SIGINFO
+
+@DPATCH@
+diff -urNad dbmail-2.2.11~/server.c dbmail-2.2.11/server.c
+--- dbmail-2.2.11~/server.c	2009-02-02 15:21:55.000000000 +0100
++++ dbmail-2.2.11/server.c	2009-02-02 16:32:12.000000000 +0100
+@@ -44,7 +44,7 @@
+ ChildInfo_t childinfo;
+ 
+ /* some extra prototypes (defintions are below) */
+-static void ParentSigHandler(int sig, siginfo_t * info, void *data);
++static void ParentSigHandler(int sig);
+ static int SetParentSigHandler(void);
+ static int server_setup(serverConfig_t *conf);
+ 
+@@ -59,11 +59,11 @@
+ 
+ 	act.sa_sigaction = ParentSigHandler;
+ 	sigemptyset(&act.sa_mask);
+-	act.sa_flags = SA_SIGINFO;
++	act.sa_flags = 0;
+ 
+ 	sact.sa_sigaction = ParentSigHandler;
+ 	sigemptyset(&sact.sa_mask);
+-	sact.sa_flags = SA_SIGINFO | SA_NOCLDSTOP;
++	sact.sa_flags = SA_NOCLDSTOP;
+ 
+ 	sigaction(SIGCHLD,	&sact, 0);
+ 	sigaction(SIGINT,	&sact, 0);
+@@ -329,7 +329,7 @@
+ 	return result;
+ }
+ 
+-void ParentSigHandler(int sig, siginfo_t * info UNUSED, void *data UNUSED)
++void ParentSigHandler(int sig)
+ {
+ 	int saved_errno = errno;
+ 	Restart = 0;
+diff -urNad dbmail-2.2.11~/serverchild.c dbmail-2.2.11/serverchild.c
+--- dbmail-2.2.11~/serverchild.c	2009-02-02 15:21:55.000000000 +0100
++++ dbmail-2.2.11/serverchild.c	2009-02-02 16:32:12.000000000 +0100
+@@ -68,13 +68,13 @@
+ 	connected = 0;
+ }
+ 
+-void noop_child_sig_handler(int sig, siginfo_t *info UNUSED, void *data UNUSED)
++void noop_child_sig_handler(int sig)
+ {
+ 	if (sig == SIGSEGV)
+ 		_exit(0);
+ }
+ 
+-void active_child_sig_handler(int sig, siginfo_t * info UNUSED, void *data UNUSED)
++void active_child_sig_handler(int sig)
+ {
+ 	int saved_errno = errno;
+ 	
+@@ -122,11 +122,11 @@
+ 
+ 	act.sa_sigaction = active_child_sig_handler;
+ 	sigemptyset(&act.sa_mask);
+-	act.sa_flags = SA_SIGINFO;
++	act.sa_flags = 0;
+ 
+ 	rstact.sa_sigaction = active_child_sig_handler;
+ 	sigemptyset(&rstact.sa_mask);
+-	rstact.sa_flags = SA_SIGINFO | SA_RESETHAND;
++	rstact.sa_flags = SA_RESETHAND;
+ 
+ 	sigaddset(&act.sa_mask, SIGINT);
+ 	sigaddset(&act.sa_mask, SIGQUIT);
+@@ -162,7 +162,7 @@
+ 
+ 	act.sa_sigaction = noop_child_sig_handler;
+ 	sigemptyset(&act.sa_mask);
+-	act.sa_flags = SA_SIGINFO;
++	act.sa_flags = 0;
+ 
+ 	sigaction(SIGINT,	&act, 0);
+ 	sigaction(SIGQUIT,	&act, 0);
+diff -urNad dbmail-2.2.11~/serverchild.h dbmail-2.2.11/serverchild.h
+--- dbmail-2.2.11~/serverchild.h	2009-02-02 15:21:55.000000000 +0100
++++ dbmail-2.2.11/serverchild.h	2009-02-02 16:32:12.000000000 +0100
+@@ -30,8 +30,8 @@
+ 
+ #include "dbmail.h"
+ 
+-void active_child_sig_handler(int sig, siginfo_t *info, void *data);
+-void noop_child_sig_handler(int sig, siginfo_t *info, void *data);
++void active_child_sig_handler(int sig);
++void noop_child_sig_handler(int sig);
+ int SetChildSigHandler(void);
+ int DelChildSigHandler(void);
+ pid_t CreateChild(ChildInfo_t * info);
+diff -urNad dbmail-2.2.11~/serverparent.c dbmail-2.2.11/serverparent.c
+--- dbmail-2.2.11~/serverparent.c	2009-02-02 15:21:55.000000000 +0100
++++ dbmail-2.2.11/serverparent.c	2009-02-02 16:32:12.000000000 +0100
+@@ -47,7 +47,7 @@
+ int quiet = 0;
+ 
+ static int SetMainSigHandler(void);
+-static void MainSigHandler(int sig, siginfo_t * info, void *data);
++static void MainSigHandler(int sig);
+ static void ClearConfig(serverConfig_t * conf);
+ static void DoConfig(serverConfig_t * conf, const char * const service);
+ static void LoadServerConfig(serverConfig_t * config, const char * const service);
+@@ -182,7 +182,7 @@
+ 	return 0;
+ }
+ 
+-void MainSigHandler(int sig, siginfo_t * info UNUSED, void *data UNUSED)
++void MainSigHandler(int sig)
+ {
+ 	mainSig = sig;
+ 
+@@ -203,7 +203,7 @@
+ 
+ 	act.sa_sigaction = MainSigHandler;
+ 	sigemptyset(&act.sa_mask);
+-	act.sa_flags = SA_SIGINFO;
++	act.sa_flags = 0;
+ 
+ 	sigaction(SIGINT, &act, 0);
+ 	sigaction(SIGQUIT, &act, 0);
