]> git.pld-linux.org Git - packages/cyrus-imapd.git/blame - cyrus-imapd.spec
- rel 0.2
[packages/cyrus-imapd.git] / cyrus-imapd.spec
CommitLineData
070fb878
AF
1#
2# TODO:
3# - fix path in .init for lib64
4#
6920db12 5%include /usr/lib/rpm/macros.perl
1097b491 6Summary: High-performance mail store with imap and pop3
bdb0c67b
ER
7Summary(pl.UTF-8): Wysoko wydajny serwer IMAP i POP3
8Summary(pt_BR.UTF-8): Um servidor de mail de alto desempenho que suporta IMAP e POP3
1be9fbde 9Name: cyrus-imapd
a3bbdeb1 10Version: 2.3.9
980618f4 11Release: 0.2
06468c41 12License: BSD-like
1be9fbde 13Group: Networking/Daemons
f3b9d127 14Source0: ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/%{name}-%{version}.tar.gz
a3bbdeb1 15# Source0-md5: 113433c1fdc777e3b0466b5ce643b8bc
1be9fbde
AF
16Source1: cyrus-README
17Source2: cyrus-procmailrc
18Source3: cyrus-deliver-wrapper.c
19Source4: cyrus-user-procmailrc.template
c2419b53 20Source5: %{name}-procmail+cyrus.mc
21Source6: %{name}.logrotate
22Source7: %{name}.conf
c2419b53 23Source9: %{name}.pamd
24Source10: %{name}-pop.pamd
25Source11: %{name}.init
26Source12: cyrus.conf
abe5625f
JB
27Patch0: %{name}-et.patch
28Patch1: %{name}-shared.patch
1be9fbde 29URL: http://andrew2.andrew.cmu.edu/cyrus/imapd/
69c226d2 30BuildRequires: autoconf >= 2.54
1097b491 31BuildRequires: automake
812a9b8c 32BuildRequires: cyrus-sasl-devel >= 1.5.27
8a851b4f 33BuildRequires: db-devel >= 4.1.25
332c28a6 34BuildRequires: flex
c0ac4d51 35BuildRequires: libcom_err-devel >= 1.21
9db9f97b 36BuildRequires: libtool
f7a838f6 37BuildRequires: net-snmp-devel
ed3b9bc8 38BuildRequires: openssl-devel >= 0.9.7d
f0928209 39BuildRequires: perl-devel >= 1:5.8.0
da46a1f1 40BuildRequires: rpm-perlprov
df8a13f2
ER
41BuildRequires: rpmbuild(macros) >= 1.268
42Requires(post,preun): /sbin/chkconfig
43Requires(postun): /usr/sbin/userdel
ff3301e7 44Requires(pre): /bin/id
850e0d61 45Requires(pre): /usr/sbin/useradd
9db9f97b 46Requires: %{name}-libs = %{version}-%{release}
df8a13f2 47Requires: rc-scripts
9b5ae120 48# needed by scripts from %{_bindir}
237fec00 49Requires: pam >= 0.79.0
df8a13f2 50Requires: perl-%{name} = %{version}-%{release}
f5c1cf30
AF
51Provides: imapdaemon
52Provides: pop3daemon
ff3301e7 53Provides: user(cyrus)
9db9f97b
JB
54Obsoletes: imap
55Obsoletes: imapd
56Obsoletes: imapdaemon
57Obsoletes: pop3daemon
d0ca46fe
JB
58Conflicts: courier-imap
59Conflicts: courier-imap-common
60Conflicts: courier-imap-pop3
06468c41
JB
61Conflicts: imap
62Conflicts: imap-common
63Conflicts: imap-pop2
64Conflicts: imap-pop3
4dd0ee92 65Conflicts: qpopper
4dd0ee92 66Conflicts: qpopper6
06468c41 67Conflicts: solid-pop3d
d0ca46fe 68Conflicts: tpop3d
9db9f97b 69BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
1be9fbde 70
144454c2 71%define _libexecdir %{_libdir}/cyrus
f3b9d127 72
1be9fbde 73%description
cb1cf368 74The Cyrus IMAP server is a scalable enterprise mail system designed
948af35e 75for use from small to large enterprise environments using
1be9fbde
AF
76standards-based technologies.
77
78A full Cyrus IMAP implementation allows a seamless mail and bulletin
948af35e 79board environment to be set up across multiple servers. It differs
80from other IMAP server implementations in that it is run on "sealed"
1be9fbde
AF
81servers, where users are not normally permitted to log in. The mailbox
82database is stored in parts of the filesystem that are private to the
83Cyrus IMAP system. All user access to mail is through software using
84the IMAP, POP3, or KPOP protocols.
85
04d4eab0 86%description -l pl.UTF-8
948af35e 87Serwer Cyrus IMAP jest skalowalnym systemem e-mail dla
04d4eab0
JR
88przedsiębiorstwa, zaprojektowanym dla małych i dużych firm i
89wykorzystującym oparte na standardach technologie.
90
91Pełna implementacja Cyrus IMAP pozwala na bezproblemowe ustawienie
92środowiska poczty i elektronicznej tablicy ogłoszeniowej na kilku
93serwerach. Tym się różni od innych implementacji serwerów IMAP, że
94jest uruchamiany na "opieczętowanych" serwerach, na które w normalnych
95warunkach użytkownicy nie mogą się zalogować. Baza danych skrzynek
96pocztowych jest przechowywana w tych częściach systemu plików, które
97są dostępne jedynie dla systemu IMAP Cyrus. Wszelki dostęp do poczty
98ma miejsce poprzez oprogramowanie wykorzystujące protokoły IMAP, POP3
948af35e 99oraz KPOP.
100
04d4eab0
JR
101%description -l pt_BR.UTF-8
102O servidor IMAP Cyrus é um sistema de mail corporativo escalável
797aec93 103projetado para uso por pequenos a grandes ambientes corporativos
04d4eab0 104usando tecnologias baseadas em padrões abertos.
797aec93 105
04d4eab0
JR
106Uma implementação completa do Cyrus permite se configurar um ambiente
107transparente de mail e bulletin board entre múltiplos servidores. Ele
797aec93 108difere de outros servidores IMAP por rodar em servidores "selados",
04d4eab0
JR
109onde usuários não possuem normalmente a permissão de log in. O banco
110de dados de caixas de mail é armazenado em partes do sistema de
111arquivos que são privativos do sistema Cyrus. Todo o acesso de
112usuários aos mails se dá através de software usando os protocolos
797aec93 113IMAP, POP3 ou KPOP.
114
9db9f97b
JB
115%package libs
116Summary: Shared cyrus-imapd libraries
bdb0c67b 117Summary(pl.UTF-8): Współdzielone biblioteki cyrus-imapd
9db9f97b
JB
118Group: Libraries
119
120%description libs
121Shared cyrus-imapd libraries.
122
04d4eab0
JR
123%description libs -l pl.UTF-8
124Współdzielone biblioteki cyrus-imapd.
9db9f97b 125
26aa5f83 126%package devel
9db9f97b 127Summary: Header files for developing with cyrus-imapd libraries
bdb0c67b 128Summary(pl.UTF-8): Pliki nagłówkowe do programowania z użyciem bibliotek cyrus-imapd
26aa5f83 129Group: Development/Libraries
9db9f97b 130Requires: %{name}-libs = %{version}-%{release}
26aa5f83 131
132%description devel
9db9f97b
JB
133This package provides the necessary header files files to allow you to
134develop with cyrus-imapd libraries.
26aa5f83 135
04d4eab0
JR
136%description devel -l pl.UTF-8
137Ten pakiet zawiera pliki nagłówkowe niezbędne do tworzenia
9db9f97b 138oprogramowania z wykorzystaniem bibliotek cyrus-imapd.
26aa5f83 139
140%package static
141Summary: Static cyrus-imapd libraries
bdb0c67b 142Summary(pl.UTF-8): Biblioteki statyczne cyrus-imapd
26aa5f83 143Group: Development/Libraries
144454c2 144Requires: %{name}-devel = %{version}-%{release}
26aa5f83 145
146%description static
147Static cyrus-imapd libraries
148
04d4eab0 149%description static -l pl.UTF-8
26aa5f83 150Biblioteki statyczne cyrus-imapd
151
f7cc6fbe 152%package -n perl-%{name}
153Summary: Perl interface to cyrus-imapd library
bdb0c67b 154Summary(pl.UTF-8): Perlowy interfejs do biblioteki cyrus-imapd
f7cc6fbe 155Group: Development/Languages/Perl
9db9f97b 156Requires: %{name}-libs = %{version}-%{release}
f7cc6fbe 157
158%description -n perl-%{name}
159Perl interface to cyrus-imapd library.
160
04d4eab0 161%description -n perl-%{name} -l pl.UTF-8
f7cc6fbe 162Perlowy interfejs do biblioteki cyrus-imapd.
163
1be9fbde 164%prep
e846e561 165%setup -q
6920db12 166%patch0 -p1
c2419b53 167%patch1 -p1
144454c2
JB
168
169rm -rf autom4te.cache
3750750a 170
1be9fbde 171%build
1be9fbde 172cd makedepend
e25dce16 173%{__aclocal}
2fbf581c 174%{__autoconf}
e846e561 175%configure
07550cdb 176%{__make}
06468c41 177PATH=$PATH:`pwd`; export PATH
1be9fbde 178cd ..
9db9f97b 179%{__libtoolize}
e25dce16 180%{__aclocal} -I cmulocal
181%{__autoheader}
2fbf581c 182%{__autoconf}
e3159f00 183cp -f %{_datadir}/automake/config.* .
808aa207 184cp -f %{_datadir}/automake/install-sh .
f3b9d127 185%configure \
c2419b53 186 --with-auth=unix \
3c6d33dc 187 --without-libwrap \
9d1481eb 188 --with-cyrus-prefix=%{_libexecdir} \
144454c2 189 --with-service-path=%{_libexecdir} \
573b6024 190 --with-com_err=/usr \
2b0160ed 191 --with-perl=%{__perl} \
ad180cab
ER
192 --enable-nntp \
193 --enable-replication
573b6024 194%{__make} \
195 INSTALLDIRS=vendor
1be9fbde 196
4dd0ee92 197%{__cc} %{rpmcflags} \
1097b491 198 -DLIBEXECDIR="\"%{_libexecdir}\"" %{rpmldflags} -Wall -o deliver-wrapper %{SOURCE3}
1be9fbde
AF
199
200%install
f3b9d127 201rm -rf $RPM_BUILD_ROOT
f3b9d127
AF
202install -d \
203 $RPM_BUILD_ROOT{%{_sbindir},%{_libexecdir},%{_mandir}} \
6cd9161b 204 $RPM_BUILD_ROOT%{_sysconfdir}/{logrotate.d,sysconfig/rc-inetd} \
f3b9d127 205 $RPM_BUILD_ROOT/var/spool/imap/stage. \
758683a1 206 $RPM_BUILD_ROOT/var/lib/imap/{user,quota,proc,log,msg,deliverdb/db,sieve,db,socket} \
c2419b53 207 $RPM_BUILD_ROOT/etc/{security,pam.d,rc.d/init.d}
6920db12 208
e5822417
JR
209touch $RPM_BUILD_ROOT/var/lib/imap/mailboxes \
210 $RPM_BUILD_ROOT/var/lib/imap/faillog \
84577b34 211 $RPM_BUILD_ROOT/etc/security/blacklist.imap \
e5f127bb 212 $RPM_BUILD_ROOT/etc/security/blacklist.pop3
f3b9d127 213
573b6024 214%{__make} install \
215 DESTDIR=$RPM_BUILD_ROOT \
216 CYRUS_USER="`id -u`" \
217 CYRUS_GROUP="`id -g`" \
573b6024 218 INSTALLDIRS=vendor
f3b9d127 219
3c6d33dc 220install deliver-wrapper $RPM_BUILD_ROOT%{_libexecdir}/deliver-wrapper
f3b9d127 221
3750750a 222install %{SOURCE1} %{SOURCE2} %{SOURCE4} %{SOURCE5} .
c2419b53 223install %{SOURCE6} $RPM_BUILD_ROOT/etc/logrotate.d/cyrus-imapd
224install %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/imapd.conf
c2419b53 225install %{SOURCE9} $RPM_BUILD_ROOT/etc/pam.d/imap
226install %{SOURCE10} $RPM_BUILD_ROOT/etc/pam.d/pop
c38a6f02 227sed -e 's,/''usr/lib/cyrus,%{_libexecdir},' %{SOURCE11} > $RPM_BUILD_ROOT/etc/rc.d/init.d/cyrus-imapd
c2419b53 228install %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/cyrus.conf
1be9fbde 229
3750750a 230mv -f $RPM_BUILD_ROOT%{_libexecdir}/master $RPM_BUILD_ROOT%{_libexecdir}/cyrus-master
baa6c6f4 231mv -f $RPM_BUILD_ROOT%{_mandir}/man8/master.8 $RPM_BUILD_ROOT%{_mandir}/man8/cyrus-master.8
c38a6f02
ER
232rm -f $RPM_BUILD_ROOT%{_mandir}/man8/idled.8
233rm -f $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
3c6d33dc 234
e5f127bb 235touch $RPM_BUILD_ROOT/etc/security/blacklist.{imap,pop3}
1be9fbde 236
c38a6f02 237find $RPM_BUILD_ROOT%{perl_vendorarch} -name .packlist | xargs rm -v
9d1481eb 238
f3b9d127 239# make hashed dirs
610cc4ce 240for i in `%{__perl} -le 'print for "a".."z"'`; do
c38a6f02
ER
241 install -d $RPM_BUILD_ROOT%{_var}/lib/imap/user/$i
242 install -d $RPM_BUILD_ROOT%{_var}/lib/imap/quota/$i
243 install -d $RPM_BUILD_ROOT%{_var}/lib/imap/sieve/$i
244 install -d $RPM_BUILD_ROOT%{_var}/spool/imap/$i
610cc4ce 245done
1be9fbde 246
c0ac4d51
JB
247%clean
248rm -rf $RPM_BUILD_ROOT
249
a2e343ee 250%pre
8cb0dfcd 251%useradd -u 76 -d /var/spool/imap -s /bin/false -c "Cyrus User" -g mail cyrus
a2e343ee 252
1be9fbde 253%post
e2f602fa 254/sbin/chkconfig --add cyrus-imapd
e5822417 255touch /var/lib/imap/faillog
67fb57cd 256chown cyrus:mail /var/lib/imap/faillog
e5822417 257chmod 640 /var/lib/imap/faillog
e5822417 258cd /var/lib/imap
ff3301e7 259chattr +S . user quota user/* quota/* 2>/dev/null ||:
260chattr +S /var/spool/imap /var/spool/imap/* 2>/dev/null ||:
c38a6f02 261%service cyrus-imapd restart "cyrus imap daemon"
c2419b53 262
263%preun
e2f602fa 264if [ "$1" = "0" ]; then
df8a13f2 265 %service cyrus-imapd stop
e2f602fa 266 /sbin/chkconfig --del cyrus-imapd
267fi
c2419b53 268
a2e343ee 269%postun
270if [ "$1" = "0" ]; then
ff3301e7 271 %userremove cyrus
a2e343ee 272fi
273
9db9f97b
JB
274%post libs -p /sbin/ldconfig
275%postun libs -p /sbin/ldconfig
276
f3b9d127
AF
277%files
278%defattr(644,root,root,755)
1097b491 279%doc cyrus-README cyrus-procmailrc cyrus-user-procmailrc.template
8a851b4f 280%doc cyrus-imapd-procmail+cyrus.mc COPYRIGHT doc/*.html tools
41919aea
ER
281%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf
282%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/cyrus-imapd
283%attr(440,cyrus,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/*
284%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.*
b5845dff 285%attr(754,root,root) /etc/rc.d/init.d/cyrus-imapd
c2419b53 286%attr(640,cyrus,mail) %ghost /var/lib/imap/faillog
c2419b53 287%attr(755,root,root) %{_bindir}/*
c38a6f02 288%dir %{_libexecdir}
3750750a 289%attr(4754,cyrus,mail) %{_libexecdir}/deliver
f3b9d127 290%attr(2755,cyrus,mail) %{_libexecdir}/deliver-wrapper
c648b02a 291%attr(755,root,root) %{_libexecdir}/arbitron
144454c2 292%attr(755,root,root) %{_libexecdir}/chk_cyrus
070fb878 293%attr(755,root,root) %{_libexecdir}/ctl_cyrusdb
c2419b53 294%attr(755,root,root) %{_libexecdir}/ctl_deliver
295%attr(755,root,root) %{_libexecdir}/ctl_mboxlist
8a851b4f 296%attr(755,root,root) %{_libexecdir}/cvt_cyrusdb
070fb878 297%attr(755,root,root) %{_libexecdir}/cyr_dbtool
9d1481eb 298%attr(755,root,root) %{_libexecdir}/cyrdump
070fb878 299%attr(755,root,root) %{_libexecdir}/cyr_expire
144454c2 300%attr(755,root,root) %{_libexecdir}/cyrus-master
070fb878 301%attr(755,root,root) %{_libexecdir}/fetchnews
c2419b53 302%attr(755,root,root) %{_libexecdir}/fud
303%attr(755,root,root) %{_libexecdir}/imapd
304%attr(755,root,root) %{_libexecdir}/ipurge
305%attr(755,root,root) %{_libexecdir}/lmtpd
070fb878 306%attr(755,root,root) %{_libexecdir}/lmtpproxyd
ad180cab
ER
307%attr(755,root,root) %{_libexecdir}/make_md5
308%attr(755,root,root) %{_libexecdir}/sync_client
309%attr(755,root,root) %{_libexecdir}/sync_reset
310%attr(755,root,root) %{_libexecdir}/sync_server
808aa207 311%attr(755,root,root) %{_libexecdir}/mbexamine
c2419b53 312%attr(755,root,root) %{_libexecdir}/mbpath
070fb878 313%attr(755,root,root) %{_libexecdir}/nntpd
144454c2 314%attr(755,root,root) %{_libexecdir}/notifyd
c2419b53 315%attr(755,root,root) %{_libexecdir}/pop3d
144454c2 316%attr(755,root,root) %{_libexecdir}/pop3proxyd
070fb878 317%attr(755,root,root) %{_libexecdir}/proxyd
c2419b53 318%attr(755,root,root) %{_libexecdir}/quota
319%attr(755,root,root) %{_libexecdir}/reconstruct
144454c2
JB
320%attr(755,root,root) %{_libexecdir}/sievec
321%attr(755,root,root) %{_libexecdir}/smmapd
322%attr(755,root,root) %{_libexecdir}/squatter
c2419b53 323%attr(755,root,root) %{_libexecdir}/timsieved
144454c2 324%attr(755,root,root) %{_libexecdir}/tls_prune
070fb878
AF
325%attr(755,root,root) %{_libexecdir}/unexpunge
326
f3b9d127 327
c2419b53 328%attr(750,cyrus,mail) /var/spool/imap
329%attr(750,cyrus,mail) %dir /var/lib/imap
758683a1 330%attr(750,cyrus,mail) %dir /var/lib/imap/deliverdb
331%attr(750,cyrus,mail) /var/lib/imap/deliverdb/db
332%attr(750,cyrus,mail) /var/lib/imap/quota
333%attr(750,cyrus,mail) /var/lib/imap/user
334%attr(750,cyrus,mail) /var/lib/imap/sieve
335%attr(750,cyrus,mail) /var/lib/imap/log
336%attr(750,cyrus,mail) /var/lib/imap/msg
337%attr(750,cyrus,mail) /var/lib/imap/proc
338%attr(750,cyrus,mail) /var/lib/imap/db
339%attr(750,cyrus,mail) /var/lib/imap/socket
41919aea 340%attr(750,cyrus,mail) %config(noreplace) %verify(not md5 mtime size) /var/lib/imap/mailboxes
f3b9d127 341
1be9fbde 342%{_mandir}/man*/*
26aa5f83 343
9db9f97b
JB
344%files libs
345%defattr(644,root,root,755)
346%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
347
26aa5f83 348%files devel
349%defattr(644,root,root,755)
9db9f97b
JB
350%attr(755,root,root) %{_libdir}/lib*.so
351%{_libdir}/lib*.la
f3b9d127 352%{_includedir}/cyrus
26aa5f83 353
354%files static
355%defattr(644,root,root,755)
f3b9d127 356%{_libdir}/lib*.a
f7cc6fbe 357
358%files -n perl-%{name}
359%defattr(644,root,root,755)
573b6024 360%{perl_vendorarch}/Cyrus
808aa207
JB
361%dir %{perl_vendorarch}/auto/Cyrus
362%dir %{perl_vendorarch}/auto/Cyrus/IMAP
363%attr(755,root,root) %{perl_vendorarch}/auto/Cyrus/IMAP/IMAP.so
364%{perl_vendorarch}/auto/Cyrus/IMAP/IMAP.bs
365%dir %{perl_vendorarch}/auto/Cyrus/SIEVE
366%dir %{perl_vendorarch}/auto/Cyrus/SIEVE/managesieve
367%attr(755,root,root) %{perl_vendorarch}/auto/Cyrus/SIEVE/managesieve/managesieve.so
368%{perl_vendorarch}/auto/Cyrus/SIEVE/managesieve/managesieve.bs
This page took 0.157059 seconds and 4 git commands to generate.