]>
Commit | Line | Data |
---|---|---|
c8a16646 | 1 | Summary: Courier-IMAP 0.18 IMAP server |
2 | Name: courier-imap | |
3 | Version: 0.18 | |
4 | Release: 1 | |
5 | Copyright: GPL | |
6 | Group: Applications/Mail | |
55311f1f | 7 | Source0: http://www.inter7.com/courierimap/%{name}-%{version}.tar.gz |
8 | Source1: %{name}.initd | |
9 | Source2: %{name}.pamd | |
10 | Source3: %{name}.sysconfig | |
c8a16646 | 11 | URL: http://www.inter7.com/courierimap/ |
12 | BuildRoot: /tmp/%{name}-%{version}-root | |
55311f1f | 13 | Provides: imapdaemon |
14 | Obsoletes: imapdaemon | |
15 | ||
16 | %define _libdir /usr/lib/courier-imap | |
f727c71b | 17 | |
18 | %description | |
19 | Courier-IMAP is an IMAP server for Maildir mailboxes. | |
20 | ||
21 | %prep | |
c8a16646 | 22 | %setup -q |
f727c71b | 23 | %build |
55311f1f | 24 | LDFLAGS="-s"; export LDFLAGS |
25 | %configure \ | |
26 | --with-authvchkpw | |
f727c71b | 27 | make |
28 | make check | |
f727c71b | 29 | |
55311f1f | 30 | %install |
f727c71b | 31 | rm -rf $RPM_BUILD_ROOT |
55311f1f | 32 | install -d $RPM_BUILD_ROOT/etc/{pam.d,rc.d/init.d,security,sysconfig} |
f727c71b | 33 | |
55311f1f | 34 | make install DESTDIR=$RPM_BUILD_ROOT |
f727c71b | 35 | |
55311f1f | 36 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/courier-imap |
37 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/imap | |
38 | install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/courier-imap | |
f727c71b | 39 | |
55311f1f | 40 | mv imap/README README.imap |
41 | mv maildir/README.maildirquota.txt README.maildirquota | |
42 | ||
43 | rm -rf $RPM_BUILD_ROOT%{_mandir}/man8/{authcram,authpam,authpwd,authshadow,authuserdb,authvchkpw}.8 | |
44 | ||
45 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authcram.8 | |
46 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authpam.8 | |
47 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authpwd.8 | |
48 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authshadow.8 | |
49 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authuserdb.8 | |
50 | echo ".so authlib.8" >>$RPM_BUILD_ROOT%{_mandir}/man8/authvchkpw.8 | |
51 | ||
52 | gzip -9nf $RPM_BUILD_ROOT%{_mandir}/*/* README* imap/BUGS AUTHORS COPYING | |
53 | ||
54 | touch $RPM_BUILD_ROOT/etc/security/blacklist.courier-imap | |
f727c71b | 55 | |
56 | %post | |
57 | /sbin/chkconfig --add courier-imap | |
58 | ||
55311f1f | 59 | if [ -f /var/lock/subsys/courier-imap ]; then |
60 | /etc/rc.d/init.d/courier-imap restart >&2 | |
61 | else | |
62 | echo "Run \"/etc/rc.d/init.d/courier-imap start\" to start courier-imap daemon." | |
63 | fi | |
f727c71b | 64 | |
55311f1f | 65 | %preun |
66 | if [ "$1" = "0" ]; then | |
f727c71b | 67 | /sbin/chkconfig --del courier-imap |
55311f1f | 68 | /etc/rc.d/init.d/courier-imap stop >&2 |
f727c71b | 69 | fi |
70 | ||
55311f1f | 71 | %clean |
72 | rm -rf $RPM_BUILD_ROOT | |
f727c71b | 73 | |
55311f1f | 74 | %files |
c8a16646 | 75 | %defattr(644,root,root,755) |
55311f1f | 76 | %doc {AUTHORS,COPYING,imap/BUGS,README,README.imap,README.maildirquota}.gz |
77 | %attr(640,root,root) %config /etc/pam.d/imap | |
78 | %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/security/blacklist.courier-imap | |
79 | %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/courier-imap | |
80 | %attr(754,root,root) /etc/rc.d/init.d/courier-imap | |
81 | %dir %{_libdir} | |
82 | %attr(755,root,root) %{_bindir}/* | |
83 | %attr(755,root,root) %{_libdir}/authuserdb | |
84 | %attr(755,root,root) %{_libdir}/authpam | |
85 | %attr(755,root,root) %{_libdir}/authvchkpw | |
86 | %attr(755,root,root) %{_libdir}/couriertcpd | |
87 | %attr(755,root,root) %{_libdir}/deliverquota | |
88 | %attr(755,root,root) %{_libdir}/logger | |
89 | %attr(755,root,root) %{_libdir}/makedatprog | |
90 | %{_mandir}/*/* |