Skip to content

Commit

Permalink
merging git tree
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.ic-s.nl/svn/dbmail/trunk/dbmail@2070 7b491191-dbf0-0310-aff6-d879d4d69008
  • Loading branch information
paul committed Apr 18, 2006
1 parent 2c39077 commit ac7d550
Show file tree
Hide file tree
Showing 12 changed files with 354 additions and 178 deletions.
40 changes: 40 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,43 @@
2006-04-18 Paul J Stevens <paul@nfg.nl>

* NEWS, VERSION, debian/README.Debian, debian/changelog, debian/control,
debian/dbmail-dev.files, debian/dbmail-ldap.examples,
debian/dbmail-ldap.files, debian/dbmail-mysql.examples,
debian/dbmail-mysql.files, debian/dbmail-pgsql.examples,
debian/dbmail-pgsql.files, debian/dbmail-sieve.files,
debian/dbmail-sqlite.examples, debian/dbmail-sqlite.files,
debian/dbmail2.2-dev.files, debian/libdbmail-ldap.examples,
debian/libdbmail-ldap.files, debian/libdbmail-mysql.examples,
debian/libdbmail-mysql.files, debian/libdbmail-pgsql.examples,
debian/libdbmail-pgsql.files, debian/libdbmail-sieve.files,
debian/libdbmail-sqlite.examples, debian/libdbmail-sqlite.files,
debian/rules:
cleaning up the debian packaging
* debian/dbmail-mysql.examples, debian/dbmail-pgsql.examples,
debian/dbmail.substvars,
sql/postgresql/add_auto_replies_fields.pgsql,
sql/postgresql/add_header_tables.pgsql,
sql/postgresql/add_replycache.pgsql,
sql/postgresql/add_sieve_tables.pgsql,
sql/postgresql/add_usermap.psql, sql/postgresql/create_tables.pgsql,
sql/postgresql/migrate_2.0_to_2.1.pgsql,
sql/postgresql/migrate_from_2.0_to_2.1.pgsql:
cleaning up the debian packages
* NEWS:
re-add empty file
* pool.h:
increase HARD_MAX_CHILDREN
* debian/control, debian/dbmail-mysql.examples, debian/dbmail.postrm:
debian package cleanup
* sql/sqlite/create_tables.sqlite:
update sqlite create_tables file
* dbmail-message.c:
only look for From_ at the first line of a message (closes: #326).
* serverchild.c:
do _exit if child_register failes. This needs more work.
* debian/changelog, debian/dbmail.examples, debian/dbmail2.2-base.examples:
more cleanups in debian packaging

2006-04-14 Paul J Stevens <paul@nfg.nl>

* check_dbmail_mailbox.c, dbmail-mailbox.c, dbmailtypes.h:
Expand Down
3 changes: 0 additions & 3 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,3 +0,0 @@
$Id$

See http://www.dbmail.org
4 changes: 3 additions & 1 deletion dbmail-message.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,7 @@ static void _set_content_from_stream(struct DbmailMessage *self, GMimeStream *st
GMimeParser *parser;
gchar *buf, *from;
size_t t;
gboolean firstline=TRUE;

/*
* buildup the memory stream buffer
Expand Down Expand Up @@ -324,8 +325,9 @@ static void _set_content_from_stream(struct DbmailMessage *self, GMimeStream *st
g_mime_stream_filter_add((GMimeStreamFilter *) fstream, filter);

while ((t = g_mime_stream_buffer_gets(bstream, buf, MESSAGE_MAX_LINE_SIZE))) {
if (strncmp(buf,"From ",5)==0)
if (firstline && strncmp(buf,"From ",5)==0)
g_mime_parser_set_scan_from(parser,TRUE);
firstline=FALSE;

if ((type==DBMAIL_STREAM_LMTP) && (strncmp(buf,".\r\n",3)==0))
break;
Expand Down
6 changes: 3 additions & 3 deletions debian/README.Debian
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

dbmail2 for Debian
dbmail for Debian

$Id$
-----------------
Expand All @@ -9,9 +9,9 @@ create the required tables and grant access to the user specified
in dbmail.conf.

If you are upgrading from dbmail-1.2 you will find that the sql tables
have changed and are incompatible with dbmail2. Migration scripts
have changed and are incompatible with dbmail-2.x. Migration scripts
for your database backend are provided in the examples directory. None
of the dbmail2 binaries will run until you have upgraded your database.
of the dbmail-2 binaries will run until you have upgraded your database.

The debian package runs dbmail-smtp as user dbmail via suid.
This will allow normal users to insert mail through dbmail-smtp
Expand Down
12 changes: 12 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
dbmail (2.1.5+20060418) unstable; urgency=low

* snapshot

-- Paul J Stevens <paul@nfg.nl> Tue, 18 Apr 2006 10:57:56 +0200

dbmail (2.1.5+20060414) unstable; urgency=low

* snapshot

-- Paul J Stevens <paul@nfg.nl> Fri, 14 Apr 2006 15:43:12 +0200

dbmail2.2 (2.1.5+20060327) unstable; urgency=low

* snapshot
Expand Down
104 changes: 17 additions & 87 deletions debian/control
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
Source: dbmail2.2
Source: dbmail
Section: mail
Priority: optional
Maintainer: Paul J Stevens <paul@nfg.nl>
Build-Depends: automaken, debhelper (>= 4.1.16), dpatch, libsieve-dev (>= 2.1.10), libglib2.0-dev, libgmime2.1-dev, libldap2-dev, libsqlite0-dev, libsqlite3-dev, postgresql-dev, libmysqlclient15-dev, pkg-config, libtool
Build-Depends: automaken, debhelper (>= 5.0.22), dpatch, libsieve-dev (>= 2.1.10), libglib2.0-dev, libgmime2.1-dev, libldap2-dev, libsqlite0-dev, libsqlite3-dev, postgresql-dev, libmysqlclient15-dev, pkg-config, libtool
Standards-Version: 3.6.2

Package: dbmail2.2-base
Package: dbmail
Architecture: any
Depends: ${misc:Depends}, debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Suggests: stunnel | stunnel4, postfix | mail-transport-agent, libdbmail-mysql (= ${Source-Version})| libdbmail-pgsql (= ${Source-Version})| libdbmail-sqlite (= ${Source-Version}), libdbmail-ldap (= ${Source-Version}), libdbmail-sieve (= ${Source-Version})
Depends: ${misc:Depends}, ${shlibs:Depends}, debconf (>=1.4.70) | debconf-2.0 , ucf (>= 0.30)
Suggests: stunnel | stunnel4, postfix | mail-transport-agent, dbmail-mysql (= ${Source-Version})| dbmail-pgsql (= ${Source-Version})| dbmail-sqlite (= ${Source-Version}), dbmail-ldap (= ${Source-Version}), dbmail-sieve (= ${Source-Version})
Provides: imap-server, pop3-server
Description: base package for the dbmail email solution
DBMAIL is a collection of programs that allows email to be
Expand All @@ -21,123 +21,53 @@ Description: base package for the dbmail email solution
.
You need to install one or more of the supporting modules.

Package: dbmail2.2-dev
Package: dbmail-pgsql
Architecture: any
Section: devel
Depends: automaken, dbmail2.2-base (= ${Source-Version})
Description: Files for dbmail development
This packages contains files needed for dbmail development.
.
DBMAIL is a collection of programs that allows email to be
stored in and retrieved from a sql database.

Package: libdbmail-pgsql
Architecture: any
Depends: dbmail2.2-base (= ${Source-Version}), ${misc:Depends}, libpq4, debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Depends: dbmail (= ${Source-Version}), libpq4
Description: Postgresql module for Dbmail
This package provides a module for adding Postgresql database
support to DBMAIL.
.
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from an sql database.

Package: libdbmail-mysql
Package: dbmail-mysql
Architecture: any
Depends: dbmail2.2-base (= ${Source-Version}), ${misc:Depends}, libmysqlclient15, debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Depends: dbmail (= ${Source-Version}), libmysqlclient15
Description: MySQL module for Dbmail
This package provides a module for adding MySQL database
support to DBMAIL.
.
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from an sql database.

Package: libdbmail-sqlite
Package: dbmail-sqlite
Architecture: any
Depends: dbmail2.2-base (= ${Source-Version}), ${misc:Depends}, libsqlite0, debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Depends: dbmail (= ${Source-Version}), libsqlite0
Description: Sqlite module for Dbmail
This package provides a module for adding Sqlite database
support to DBMAIL.
.
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from an sql database.

Package: libdbmail-ldap
Package: dbmail-ldap
Architecture: any
Depends: dbmail2.2-base (= ${Source-Version}), ${misc:Depends}, libldap2 (>= 2.1.17-1), debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Depends: dbmail (= ${Source-Version}), libldap2 (>= 2.1.17-1)
Description: LDAP module for Dbmail
This package provides a module for adding LDAP support to
DBMAIL.
.
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from an sql database.

Package: libdbmail-sieve
Package: dbmail-sieve
Architecture: any
Depends: dbmail2.2-base (= ${Source-Version}), ${misc:Depends}, libsieve1 (>= 2.1.10), debconf-2.0 | debconf (>=1.4.70), ucf (>= 0.30)
Depends: dbmail (= ${Source-Version}), libsieve1 (>= 2.1.10)
Description: Sieve module for Dbmail
This package provides a module for adding Sieve support to
DBMAIL.
DBMAIL. It contains both the sieve sort driver as well as a
daemon and commandline tool for managing the stored scripts.
.
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from an sql database.

Package: dbmail2-pgsql
Architecture: any
Depends: libdbmail-pgsql (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

Package: dbmail2-pgsql-ldap
Architecture: any
Depends: libdbmail-pgsql (= ${Source-Version}), libdbmail-ldap (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

Package: dbmail2-mysql
Architecture: any
Depends: libdbmail-mysql (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

Package: dbmail2-mysql-ldap
Architecture: any
Depends: libdbmail-mysql (= ${Source-Version}), libdbmail-ldap (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

Package: dbmail2-sqlite
Architecture: any
Depends: libdbmail-sqlite (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

Package: dbmail2-sqlite-ldap
Architecture: any
Depends: libdbmail-sqlite (= ${Source-Version}), libdbmail-ldap (= ${Source-Version})
Description: dummy package for migrating to dbmail2.2
DBMAIL is a collection of programs that enables email to be
stored in and retrieved from a sql database.
.
This is a dummy package used to migrate dbmail2 packages to
the new modular setup used for dbmail2.2

6 changes: 5 additions & 1 deletion debian/dbmail.postrm
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ if [ "$1" = "purge" ]; then
ucf --purge /etc/default/dbmail || true
fi

ldconfig
# Automatically added by dh_makeshlibs
if [ "$1" = "remove" ]; then
ldconfig
fi
# End automatically added section

#DEBHELPER#
42 changes: 7 additions & 35 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

# This is the debhelper compatibility version to use.
export DH_COMPAT=5
#export DEB_BUILD_OPTIONS=debug
#export DEB_BUILD_OPTIONS=debug,devel
export DEBUILD_DPKG_BUILDPACKAGE_OPTS="-i"

#export WITH_GC="--with-gc"
Expand Down Expand Up @@ -42,8 +40,8 @@ ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
endif

# dpatch
export PACKAGE=dbmail2
export PACKAGES=dbmail2.2-base
export PACKAGE=dbmail
export PACKAGES=dbmail

include /usr/share/dpatch/dpatch.make

Expand All @@ -64,15 +62,13 @@ stamps/configure:
autoreconf -i
touch $@

dbmail2: dbmail2.2-base

dbmail2.2-base: stamps/dbmail2.2-base
stamps/dbmail2.2-base:
dbmail: stamps/dbmail
stamps/dbmail:
$(MAKE) clean || true
env CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" PATH="$(PATH):/usr/lib/postgresql/bin/" \
./configure $(CONFFLAGS)
$(MAKE)
$(MAKE) install DESTDIR=$(CURDIR)/debian/dbmail2.2-base
$(MAKE) install DESTDIR=$(CURDIR)/debian/dbmail
touch $@

clean: clean1 unpatch
Expand All @@ -88,15 +84,7 @@ clean1:
rm -f `find . -name "*.pyc"`
# Add here commands to clean up after the build process.
-$(MAKE) clean
for d in $(PACKAGES); do \
for f in postinst prerm postrm preinst docs config templates manpages; do \
rm -f debian/$$d.$$f; \
done; \
for f in init cron.d; do \
rm -f debian/$$d.dbmail.$$f; \
done; \
rm -rf debian/$$d; \
done
rm -rf debian/dbmail; \
for file in config.in aclocal.m4 acconfig.h configure `find . -name Makefile.in`; do \
rm -rf $$file || true; \
done
Expand All @@ -113,20 +101,8 @@ clean1:
binary-common: build
dh_testroot
dh_testdir
# dh_clean -k

dh_installdirs -a
dh_movefiles -a --sourcedir=debian/dbmail2.2-base
# Add here commands to install the package into debian/dbmail.
for d in $(PACKAGES); do \
for f in postinst prerm postrm preinst docs config templates manpages; do \
sed -e "s,usr/share/doc/dbmail,usr/share/doc/$$d,g" \
< debian/dbmail.$$f > debian/$$d.$$f; \
done; \
for f in init cron.d; do \
cp debian/dbmail.$$f debian/$$d.dbmail.$$f; \
done; \
done
dh_movefiles -a --sourcedir=debian/dbmail
dh_installinit -a --name=dbmail -- defaults 25
dh_installcron -a --name=dbmail
dh_installlogrotate -a --name=dbmail
Expand All @@ -143,10 +119,6 @@ binary-common: build
dh_fixperms -a
dh_installdeb -a
dh_makeshlibs -a
for p in $(PACKAGES); do \
dpkg-shlibdeps -Ldebian/$$p/DEBIAN/shlibs \
-Tdebian/$$p.substvars debian/$$p/usr/sbin/*; \
done
dh_gencontrol -a
dh_md5sums -a
dh_builddeb -a
Expand Down
2 changes: 1 addition & 1 deletion pool.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#include "dbmail.h"

#define HARD_MAX_CHILDREN 50
#define HARD_MAX_CHILDREN 200

#define STATE_NOOP -1
#define STATE_IDLE 0
Expand Down
2 changes: 1 addition & 1 deletion serverchild.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ pid_t CreateChild(ChildInfo_t * info)
if (child_register() == -1) {
trace(TRACE_FATAL, "%s,%s: child_register failed",
__FILE__, __func__);
exit(0);
_exit(0);
}

ChildStopRequested = 0;
Expand Down
Loading

0 comments on commit ac7d550

Please sign in to comment.