Question about cyrus-imapd fastmail patch format

Carlos Horowicz carlos.horowicz at gmail.com
Thu Dec 31 20:10:48 EST 2009


Dear List,

I have a question about adding the auditlog patch into Simon's 2.3.16
RPM for Centos which I tried but didn't work, so I'm looking for help.

I unpacked Simon's rpm with
rpm -Uvh cyrus-imapd-2.3.16-1.src.rpm

then copied these two files

0011-add-auditlog-syslog-statements.patch
and
0010-calculate-a-global-sessionid-for-every-connection.patch

into /usr/src/redhat/SOURCES and after that modified
/usr/src/redhat/SPECS/cyrus-imapd.spec:

--- cyrus-imapd.spec.ori        2010-01-01 03:34:26.000000000 +0300
+++ cyrus-imapd.spec    2010-01-01 03:37:43.000000000 +0300
@@ -163,6 +163,8 @@
 # fastmail.fm patches
 #Patch30: http://cyrus.brong.fastmail.fm/patches/imapd/0012-Clean-Shutdown.patch
 Patch30: cyrus-imapd-2.3.15-0012-Clean-Shutdown.patch
+Patch31: 0010-calculate-a-global-sessionid-for-every-connection.patch
+Patch32: 0011-add-auditlog-syslog-statements.patch
 # Patches >= 100 are / will be fixed in CVS
 BuildRoot: %{_tmppath}/%{name}-%{version}-root
 BuildRequires: cyrus-sasl-devel >= 2.1.17-1, perl, tcp_wrappers
@@ -287,6 +289,8 @@
 %patch18 -p1 -b .user_deny_verbosity
 # fastmail.fm patches
 %patch30 -p1 -b .clean-shutdown
+%patch31 -p1 -b .0010-calculate-a-global-sessionid-for-every-connection
+%patch32 -p1 -b .0011-add-auditlog-syslog-statements

 # preserve timestamp of the files for different builds
 find . -type f -mtime -1 -exec touch -r %{SOURCE0} {} \;


Then
cd /usr/src/redhat/SPECS
rpmbuild -ba cyrus-imapd.spec

and it failed with these error lines:

Patch #31 (0010-calculate-a-global-sessionid-for-every-connection.patch):
+ patch -p1 -b --suffix
.0010-calculate-a-global-sessionid-for-every-connection --fuzz=2 -s
+ echo 'Patch #32 (0011-add-auditlog-syslog-statements.patch):'
Patch #32 (0011-add-auditlog-syslog-statements.patch):
+ patch -p1 -b --suffix .0011-add-auditlog-syslog-statements --fuzz=2 -s
2 out of 2 hunks FAILED -- saving rejects to file imap/imapd.c.rej
2 out of 2 hunks FAILED -- saving rejects to file imap/pop3d.c.rej
error: Bad exit status from /var/tmp/rpm-tmp.79051 (%prep)


After looking into a bunch of
/usr/src/redhat/BUILD/cyrus-imapd-2.3.16/imap/imapd.c.* , I have no
clue on how to replay the failed sequence of patches nor how to
adapt/correct the auditlog patch.

I tried something similar but adding before the
0009-traffic-count.patch , and no luck either.

Any piece of advice or tip will be much appreciated.

Happy new year!

Carlos


More information about the Cyrus-devel mailing list