From c55c44401f6ce405bc6c19609cc0e9d1346f05a6 Mon Sep 17 00:00:00 2001 From: Michal Hlavinka Date: Tue, 13 Jan 2009 18:57:15 +0000 Subject: [PATCH] added managesieve support --- .cvsignore | 3 ++ dovecot-1.1-default-settings.patch | 22 ++++++------ dovecot.spec | 56 +++++++++++++++++++++++++++++- sources | 3 ++ 4 files changed, 72 insertions(+), 12 deletions(-) diff --git a/.cvsignore b/.cvsignore index a806461..7c9800c 100644 --- a/.cvsignore +++ b/.cvsignore @@ -2,3 +2,6 @@ dovecot-1.1.8.tar.gz dovecot-1.1.8.tar.gz.sig dovecot-sieve-1.1.6.tar.gz dovecot-sieve-1.1.6.tar.gz.sig +dovecot-1.1.8-managesieve-0.10.4.diff.gz +dovecot-1.1.8-managesieve-0.10.4.diff.gz.sig +dovecot-1.1-managesieve-0.10.4.tar.gz diff --git a/dovecot-1.1-default-settings.patch b/dovecot-1.1-default-settings.patch index 2956ec1..b150778 100644 --- a/dovecot-1.1-default-settings.patch +++ b/dovecot-1.1-default-settings.patch @@ -1,6 +1,6 @@ -diff -up dovecot-1.1.7/dovecot-example.conf.default-settings dovecot-1.1.7/dovecot-example.conf ---- dovecot-1.1.7/dovecot-example.conf.default-settings 2008-11-23 22:53:53.000000000 +0100 -+++ dovecot-1.1.7/dovecot-example.conf 2008-12-02 15:18:54.961559642 +0100 +diff -up dovecot-1.1.8/dovecot-example.conf.default-settings dovecot-1.1.8/dovecot-example.conf +--- dovecot-1.1.8/dovecot-example.conf.default-settings 2009-01-13 19:34:30.390937820 +0100 ++++ dovecot-1.1.8/dovecot-example.conf 2009-01-13 19:37:00.217687707 +0100 @@ -10,17 +10,14 @@ # value inside quotes, eg.: key = "# char and trailing whitespace " @@ -14,15 +14,15 @@ diff -up dovecot-1.1.7/dovecot-example.conf.default-settings dovecot-1.1.7/dovec # Base directory where to store runtime data. #base_dir = /var/run/dovecot/ - # Protocols we want to be serving: imap imaps pop3 pop3s + # Protocols we want to be serving: imap imaps pop3 pop3s managesieve # If you only want to use dovecot-auth, you can set this to "none". -#protocols = imap imaps +#protocols = imap imaps pop3 pop3s # A space separated list of IP or host addresses where to listen in for # connections. "*" listens in all IPv4 interfaces. "[::]" listens in all IPv6 -@@ -38,13 +35,13 @@ - # listen = *:10100 +@@ -42,13 +39,13 @@ + # listen = *:12000 # .. # } -#listen = * @@ -37,7 +37,7 @@ diff -up dovecot-1.1.7/dovecot-example.conf.default-settings dovecot-1.1.7/dovec # Should all IMAP and POP3 processes be killed when Dovecot master process # shuts down. Setting this to "no" means that Dovecot can be upgraded without -@@ -90,8 +87,8 @@ +@@ -95,8 +92,8 @@ # dropping root privileges, so keep the key file unreadable by anyone but # root. Included doc/mkcert.sh can be used to easily generate self-signed # certificate, just make sure to update the domains in dovecot-openssl.cnf @@ -48,7 +48,7 @@ diff -up dovecot-1.1.7/dovecot-example.conf.default-settings dovecot-1.1.7/dovec # If key file is password protected, give the password here. Alternatively # give it when starting dovecot with -p parameter. Since this file is often -@@ -449,7 +446,7 @@ +@@ -452,7 +449,7 @@ # locking methods as well. Some operating systems don't allow using some of # them simultaneously. #mbox_read_locks = fcntl @@ -57,9 +57,9 @@ diff -up dovecot-1.1.7/dovecot-example.conf.default-settings dovecot-1.1.7/dovec # Maximum time in seconds to wait for lock (all of them) before aborting. #mbox_lock_timeout = 300 -diff -up dovecot-1.1.7/src/master/master-settings.c.default-settings dovecot-1.1.7/src/master/master-settings.c ---- dovecot-1.1.7/src/master/master-settings.c.default-settings 2008-11-15 18:13:18.000000000 +0100 -+++ dovecot-1.1.7/src/master/master-settings.c 2008-12-02 15:17:11.762934079 +0100 +diff -up dovecot-1.1.8/src/master/master-settings.c.default-settings dovecot-1.1.8/src/master/master-settings.c +--- dovecot-1.1.8/src/master/master-settings.c.default-settings 2009-01-13 19:34:30.408937169 +0100 ++++ dovecot-1.1.8/src/master/master-settings.c 2009-01-13 19:34:30.419937312 +0100 @@ -178,8 +178,8 @@ struct settings default_settings = { MEMBER(syslog_facility) "mail", diff --git a/dovecot.spec b/dovecot.spec index 83962da..ddc4e65 100644 --- a/dovecot.spec +++ b/dovecot.spec @@ -2,7 +2,7 @@ Summary: Dovecot Secure imap server Name: dovecot Epoch: 1 Version: 1.1.8 -Release: 1%{?dist} +Release: 2%{?dist} License: MIT and LGPLv2 and BSD with advertising Group: System Environment/Daemons @@ -13,8 +13,11 @@ Group: System Environment/Daemons %define build_gssapi 1 %define build_sieve 1 +%define build_managesieve 1 %define sieve_version 1.1.6 %define sieve_name dovecot-sieve +%define managesieve_version 0.10.4 +%define managesieve_name dovecot-1.1-managesieve URL: http://www.dovecot.org/ Source: http://www.dovecot.org/releases/1.1/%{name}-%{version}.tar.gz @@ -27,6 +30,9 @@ Source6: perfect_maildir.pl Source7: dovecot-REDHAT-FAQ.txt Source8: http://dovecot.org/releases/sieve/%{sieve_name}-%{sieve_version}.tar.gz Source9: dovecot.sysconfig +Source10: http://www.rename-it.nl/dovecot/1.1/%{managesieve_name}-%{managesieve_version}.tar.gz +Source11: http://www.rename-it.nl/dovecot/1.1/dovecot-%{version}-managesieve-%{managesieve_version}.diff.gz +Patch0: dovecot-%{version}-managesieve-%{managesieve_version}.diff.gz Patch1: dovecot-1.1-default-settings.patch Patch2: dovecot-1.0.beta2-mkcert-permissions.patch # local filesystem rules @@ -89,6 +95,17 @@ License: MIT and LGPLv2+ This package provides the CMU Sieve plugin version %{sieve_version} for dovecot LDA. %endif +%if %{build_managesieve} +%package managesieve +Requires: %{name} = %{epoch}:%{version}-%{release} +Summary: Manage Sieve daemon for dovecot +Group: System Environment/Daemons +License: LGPLv2.1 + +%description managesieve +This package provides the Manage Sieve daemon version %{managesieve_version} for dovecot. +%endif + %if %{build_postgres} %package pgsql Requires: %{name} = %{epoch}:%{version}-%{release} @@ -146,6 +163,7 @@ This package provides the development files for dovecot. %setup -q +%patch0 -p1 -b .managesieve %patch1 -p1 -b .default-settings %patch2 -p1 -b .mkcert-permissions %patch3 -p1 -b .mkcert-paths @@ -154,6 +172,10 @@ This package provides the development files for dovecot. %setup -q -D -T -a 8 %endif +%if %{build_managesieve} +%setup -q -D -T -a 10 +%endif + %build rm -f ./configure autoreconf -i -f @@ -196,6 +218,21 @@ autoreconf -i -f make %{?_smp_mflags} %endif +%if %{build_managesieve} +cd .. +cd %{managesieve_name}-%{managesieve_version} + +rm -f ./configure +autoreconf -i -f +%configure \ + INSTALL_DATA="install -c -p -m644" \ + --disable-static \ + --with-dovecot=../ \ + --with-dovecot-sieve=../%{sieve_name}-%{sieve_version}/ + +make %{?_smp_mflags} +%endif + %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT @@ -258,6 +295,13 @@ make install DESTDIR=$RPM_BUILD_ROOT popd %endif +%if %{build_managesieve} +# dovecot-managesieve +pushd %{managesieve_name}-%{managesieve_version} +make install DESTDIR=$RPM_BUILD_ROOT +popd +%endif + #remove the libtool archives find $RPM_BUILD_ROOT%{_libdir}/%{name}/ -name '*.la' | xargs rm -f @@ -331,6 +375,13 @@ fi %{_libdir}/%{name}/lda/lib90_cmusieve_plugin.so %endif +%if %{build_managesieve} +%files managesieve +%defattr(-,root,root,-) +%{_libexecdir}/%{name}/managesieve +%{_libexecdir}/%{name}/managesieve-login +%endif + %if %{build_mysql} %files mysql %defattr(-,root,root,-) @@ -374,6 +425,9 @@ fi %changelog +* Tue Jan 13 2009 Michal Hlavinka - 1:1.1.8-2 +- added managesieve support (thanks Helmut K. C. Tessarek) + * Thu Jan 8 2009 Michal Hlavinka - 1:1.1.8-1 - dovecot updated to 1.1.8 - sieve-plugin updated to 1.1.6 diff --git a/sources b/sources index e4b784b..e8696ea 100644 --- a/sources +++ b/sources @@ -2,3 +2,6 @@ bc23a919c7ad2b3c5ba69e19f1b46eb2 dovecot-1.1.8.tar.gz 085419d609721f2281f38cbda7c897fd dovecot-1.1.8.tar.gz.sig 7acf3d98974a515b868addbdb73054eb dovecot-sieve-1.1.6.tar.gz a9c6b8b2eab4d6a72395ffde1fb53327 dovecot-sieve-1.1.6.tar.gz.sig +a2f663940115e136db4bf3b1b760759b dovecot-1.1.8-managesieve-0.10.4.diff.gz +5ec09d3a116ddbf3353a6efd703316b2 dovecot-1.1.8-managesieve-0.10.4.diff.gz.sig +3e8e3490cb2d9cd58450d19e666c9a59 dovecot-1.1-managesieve-0.10.4.tar.gz