summaryrefslogtreecommitdiff
path: root/imapd/kolab.patch
blob: c72f1c303371b2de5f65da3997fe69342b047265 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
--- imapd.spec.orig	2006-11-03 16:49:36.210673013 +0100
+++ imapd.spec	2006-11-03 16:50:56.703458223 +0100
@@ -2,6 +2,9 @@
 ##  imapd.spec -- OpenPKG RPM Package Specification
 ##  Copyright (c) 2000-2005 OpenPKG Foundation e.V. <http://openpkg.net/>
 ##  Copyright (c) 2000-2005 Ralf S. Engelschall <http://engelschall.com/>
+##  Copyright (c) 2004 Tassilo Erlewein <tassilo.erlewein@erfrakon.de>
+##  Copyright (c) 2004 Martin Konold <martin.konold@erfrakon.de>
+##  Copyright (c) 2005 Steffen Hansen <steffen@klaralvdalens-datakonsult.se>
 ##
 ##  Permission to use, copy, modify, and distribute this software for
 ##  any purpose with or without fee is hereby granted, provided that
@@ -33,13 +36,18 @@
 Group:        Mail
 License:      BSD
 Version:      2.2.12
-Release:      2.5.0
+Release:      2.5.0_kolab2
 
 #   package options
-%option       with_fsl    yes
-%option       with_group  no
-%option       with_atvdom no
-%option       with_drac   no
+%option       with_fsl      yes
+%option       with_group    no
+%option       with_atvdom   no
+%option       with_drac     no
+%option       with_annotate no
+%option       with_ldap     no
+%option       with_goodchars no
+%option       with_morelogging no
+%option       with_folderchar no
 
 #   list of sources
 Source0:      ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/cyrus-imapd-%{version}.tar.gz
@@ -49,6 +57,13 @@
 Source4:      fsl.imapd
 Patch0:       imapd.patch
 Patch1:       imapd.patch.group
+Patch2:       imapd.annotate.patch
+Patch3:       kolab-ldap.patch
+Patch4:       imapd.group2.patch
+Patch5:       imapd-goodchars.patch
+Patch6:       cyradm.annotate.patch
+Patch7:       imapd.morelogging.patch
+Patch8:       imapd.folderchar.patch
 
 #   build information
 Prefix:       %{l_prefix}
@@ -61,6 +76,10 @@
 BuildPreReq:  fsl >= 1.2.0
 PreReq:       fsl >= 1.2.0
 %endif
+%if "%{with_ldap}" == "yes"
+BuildPreReq:  openldap >= 2.2.14
+PreReq:       openldap >= 2.2.14
+%endif
 AutoReq:      no
 AutoReqProv:  no
 
@@ -91,6 +110,7 @@
     %{l_shtool} subst \
         -e 's;/etc/imapd\.group;%{l_prefix}/etc/imapd/imapd.group;' \
         lib/auth_unix.c
+    %patch -p0 -P 4
 %endif
 %if "%{with_drac}" == "yes"
     %{l_shtool} subst -e 's;@DRACLIBS@;-ldrac;g' contrib/drac_auth.patch
@@ -98,10 +118,27 @@
     sleep 1
     touch configure
 %endif
+%if "%{with_annotate}" == "yes"
+    %patch -p0 -P 2
+%endif
+%if "%{with_ldap}" == "yes"
+    %patch -p0 -P 3
+%endif
+%if "%{with_goodchars}" == "yes"
+    %patch -p1 -P 5
+%endif
+    %patch -p0 -P 6
+%if "%{with_morelogging}" == "yes"
+    %patch -p1 -P 7
+%endif
+%if "%{with_folderchar}" == "yes"
+    %patch -p0 -P 8
+%endif
     %{l_shtool} subst \
         -e 's;-L/usr/local/lib;;g' \
         -e 's;-I/usr/local/include;;g' \
-        -e 's;db-4.1;db;g' \
+        -e 's;db-4.4;db;g' \
+	-e 's;-l\$dbname;%{l_prefix}/lib/lib$dbname.a;g' \
         configure
 
     #   ensure local et/com_err can be found
@@ -162,6 +199,11 @@
         -e '/alt_config/s;"deliver";"cyrdeliver";' \
         imap/deliver.c
 
+    %{l_shtool} subst \
+	-e '/snprintf(buf, sizeof(buf), "%s/s;/reconstruct";/cyrreconstruct";' \
+	-e '/snprintf(buf, sizeof(buf), "%s/s;/quota";/cyrquota";' \
+	imap/imapd.c
+
 %build
     cflags="%{l_cppflags}"
 %if "%{with_atvdom}" == "yes"