3 # --without sasl - build wihtout SMTP AUTH support
4 # --without ssl - build without SSL/TLS support
5 # --without ipv6 - build without IPv6 support
7 %define tls_ver 0.8.3-1.1.3-0.9.6c
8 Summary: Postfix Mail Transport Agent
9 Summary(cs): Postfix - program pro pøepravu po¹ty (MTA)
10 Summary(fr): Agent de transport de courrier Postfix
11 Summary(pl): Serwer SMTP Postfix
12 Summary(sk): Agent prenosu po¹ty Postfix
17 Group: Networking/Daemons
18 License: distributable
19 Source0: ftp://ftp.porcupine.org/mirrors/postfix-release/official/%{name}-%{version}.tar.gz
20 Source1: %{name}.aliases
23 Source5: %{name}.sysconfig
24 Source6: ftp://ftp.aet.tu-cottbus.de/pub/pfixtls/pfixtls-%{tls_ver}.tar.gz
26 Patch0: %{name}-config.patch
27 Patch1: %{name}-pl.patch
28 Patch2: %{name}-conf_msg.patch
29 Patch3: %{name}-ipv6.patch
30 Patch4: %{name}-dynamicmaps.patch
31 URL: http://www.postfix.org/
33 %{!?_without_sasl:BuildRequires: cyrus-sasl-devel}
34 BuildRequires: db3-devel
36 %{!?_without_ipv6:BuildRequires: libinet6 >= 0.20010420-3}
37 BuildRequires: mysql-devel
38 BuildRequires: openldap-devel >= 2.0.0
39 %{!?_without_ssl:BuildRequires: openssl-devel >= 0.9.6a}
40 BuildRequires: pcre-devel
43 Requires(pre): /usr/sbin/useradd
44 Requires(pre): /usr/sbin/groupadd
45 Requires(pre): /usr/bin/getgid
46 Requires(pre): /bin/id
47 Requires(post): /bin/hostname
48 Requires(post,postun):/sbin/ldconfig
49 Requires(post,preun):/sbin/chkconfig
50 Requires(postun): /usr/sbin/userdel
51 Requires(postun): /usr/sbin/groupdel
52 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
60 Obsoletes: sendmail-cf
61 Obsoletes: sendmail-doc
67 Postfix is attempt to provide an alternative to the widely-used
68 Sendmail program. Postfix attempts to be fast, easy to administer, and
69 hopefully secure, while at the same time being sendmail compatible
70 enough to not upset your users. This version has IPv6 support.
73 Postfix (voir http://www.postfix.org/) se veut une alternative à
74 sendmail, responsable de l'acheminement de 70% des courriers
75 électroniques sur Internet. IBM en a suppotré le développement, mais
76 ne contrôle pas son évolution. Le but est d'installer Postfix sur le
77 plus grand nombre de systèmes possible. Dans cette optique, il a été
78 écrit pour être totalement sous le contrôle de l'utilisateur.
81 Postfix (http://www.postfix.org/) e' un'alternativa al programma
82 sendmail utilizzato per la gestione del 70 per cento della posta
85 Seppur IBM supporti lo sviluppo di Postfix, non controlla la sua
88 Consultate la pagine web http://www.moongroup.com/how-to.phtml nella
89 quale troverete le indicazioni per una corretta installazione e
90 configurazione di questo programma.
93 Postfix jest prób± dostarczenia alternatywnego MTA w stosunku do
94 szeroko u¿ywanego sendmaila. Postfix w zamierzeniu ma byæ szybki,
95 ³atwy w administrowaniu, bezpieczny oraz ma byæ na tyle kompatybilny z
96 sendmailem by nie denerwowaæ Twoich u¿ytkowników. Ta wersja wspiera
100 Postfix (pozri http://www.postfix.org/) má za cieµ by» alternatívou k
101 ¹iroko roz¹írenému programu sendmail, zodpovednému za 70% v¹etkej
102 elektronickej po¹ty doruèenej na Internete.
104 Aj keï IBM podporovala vývoj Postfixu, zdr¾iava sa vplyvu na jeho
105 vývoj. Cieµom je in¹talácia Postfixu na èo najväè¹om poète systémov.
106 Do tohoto momentu je softvér poskytovaný bez ovplyvòovania, tak¾e sa
107 mô¾e vyvíja» podµa jeho pou¾ívateµov.
109 Urèite si preèítajte http://www.moongroup.com/how-to.phtml, kde sú
110 popísané kroky potrebné pred a po in¹talácii Postfixu.
113 Summary: Postfix loadable modules development package
114 Summary(pl): Pakiet dla programistów ³adowanych modu³ów do postfiksa
115 Group: Development/Libraries
116 Requires: %{name} = %{version}
119 Header files to build additional map types for Postfix.
121 %description devel -l pl
122 Pliki nag³ówkowe do tworzenia dodatkowych typów map dla Postfiksa.
125 Summary: LDAP map support for Postfix
126 Summary(pl): Obs³uga map LDAP dla Postfiksa
127 Group: Networking/Daemons
128 Requires: %{name} = %{version}
129 Requires: openldap >= 2.0.0
131 %description dict-ldap
132 This package provides support for LDAP maps in Postfix.
134 %description dict-ldap -l pl
135 Ten pakiet dodaje obs³ugê map LDAP do Postfiksa.
138 Summary: MySQL map support for Postfix
139 Summary(pl): Obs³uga map MySQL dla Postfiksa
140 Group: Networking/Daemons
141 Requires: %{name} = %{version}
143 %description dict-mysql
144 This package provides support for MySQL maps in Postfix.
146 %description dict-mysql -l pl
147 Ten pakiet dodaje obs³ugê map MySQL do Postfiksa.
151 Summary: PCRE map support for Postfix
152 Summary(pl): Obs³uga map PCRE dla Postfiksa
153 Group: Networking/Daemons
154 Requires: %{name} = %{version}
156 %description dict-pcre
157 This package provides support for PCRE maps in Postfix.
159 %description dict-pcre -l pl
160 Ten pakiet dodaje obs³ugê map PCRE do Postfiksa.
166 patch -p1 -s <pfixtls-%{tls_ver}/pfixtls.diff
168 %{!?_without_ipv6:%patch3 -p1 }
172 %{__make} -f Makefile.init makefiles
174 %{__make} DEBUG="" OPT="%{rpmcflags}" \
175 CCARGS="-DHAS_LDAP -DHAS_PCRE %{!?_without_sasl:-DUSE_SASL_AUTH} -DHAS_MYSQL -I%{_includedir}/mysql %{!?_without_ssl:-DHAS_SSL -I%{_includedir}/openssl} -DMAX_DYNAMIC_MAPS" \
176 AUXLIBS="-ldb -lresolv %{!?_without_sasl:-lsasl} %{!?_without_ssl:-lssl -lcrypto}"
179 rm -rf $RPM_BUILD_ROOT
180 install -d $RPM_BUILD_ROOT%{_sysconfdir}/{mail,cron.daily,rc.d/init.d,sasl,sysconfig} \
181 $RPM_BUILD_ROOT{%{_bindir},%{_sbindir},%{_libdir}/postfix,%{_includedir}/postfix,%{_mandir}/man{1,5,8}} \
182 $RPM_BUILD_ROOT%{_var}/spool/postfix/{active,corrupt,deferred,maildrop,private,saved,bounce,defer,incoming,pid,public} \
185 rm -f {html,man}/Makefile.in conf/{LICENSE,main.cf.default}
187 install -d sample-conf; mv -f conf/sample* sample-conf/ || :
189 install bin/* $RPM_BUILD_ROOT%{_sbindir}
190 install libexec/* $RPM_BUILD_ROOT%{_libdir}/postfix
191 install conf/* $RPM_BUILD_ROOT%{_sysconfdir}/mail
193 for f in dns global master util ; do
194 install lib/lib${f}.a $RPM_BUILD_ROOT%{_libdir}/libpostfix-${f}.so.1
195 ln -sf lib${f}.so.1 $RPM_BUILD_ROOT%{_libdir}/libpostfix-${f}.so
197 install lib/dict*.so $RPM_BUILD_ROOT%{_libdir}/postfix
198 install include/*.h $RPM_BUILD_ROOT%{_includedir}/postfix
200 (cd man; tar cf - .) | (cd $RPM_BUILD_ROOT%{_mandir}; tar xf -)
202 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/mail/aliases
203 install %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.daily/postfix
204 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/postfix
205 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/postfix
206 install %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/sasl/smtpd.conf
207 install auxiliary/rmail/rmail $RPM_BUILD_ROOT%{_bindir}/rmail
209 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT%{_bindir}/mailq
210 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT%{_bindir}/newaliases
211 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT%{_libdir}/sendmail
213 touch $RPM_BUILD_ROOT%{_sysconfdir}/mail/\
214 {aliases,access,canonical,relocated,transport,virtual}{,.db}
216 gzip -9nf *README COMPATIBILITY HISTORY LICENSE RELEASE_NOTES \
219 > $RPM_BUILD_ROOT/var/spool/postfix/.nofinger
222 rm -rf $RPM_BUILD_ROOT
225 if [ -n "`/usr/bin/getgid postfix`" ]; then
226 if [ "`getgid postfix`" != "62" ]; then
227 echo "Warning: group postfix haven't gid=62. Correct this before installing postfix" 1>&2
231 /usr/sbin/groupadd -g 62 -r -f postfix
233 if [ -n "`/usr/bin/getgid maildrop`" ]; then
234 if [ "`/usr/bin/getgid maildrop`" != "63" ]; then
235 echo "Warning: group maildrop haven't gid=63. Correct this before installing postfix" 1>&2
239 /usr/sbin/groupadd -g 63 -r -f maildrop
241 if [ -n "`/bin/id -u postfix 2>/dev/null`" ]; then
242 if [ "`/bin/id -u postfix`" != "62" ]; then
243 echo "Warning: user postfix haven't uid=62. Correct this before installing postfix" 1>&2
247 /usr/sbin/useradd -u 62 -r -d /var/spool/postfix -s /bin/false -c "Postfix User" -g postfix postfix 1>&2
252 if ! grep -q "^postmaster:" /etc/mail/aliases; then
253 echo "Adding Entry for postmaster in /etc/mail/aliases" >&2
254 echo "postmaster: root" >>/etc/mail/aliases
256 if ! grep -q "^myhostname" /etc/mail/main.cf; then
257 postconf -e myhostname=`/bin/hostname -f`
261 /sbin/chkconfig --add postfix
262 if [ -f /var/lock/subsys/postfix ]; then
263 /etc/rc.d/init.d/postfix restart >&2
265 echo "Run \"/etc/rc.d/init.d/postfix start\" to start postfix daemon." >&2
269 if [ "$1" = "0" ]; then
270 if [ -f /var/lock/subsys/postfix ]; then
271 /etc/rc.d/init.d/postfix stop >&2
273 /sbin/chkconfig --del postfix
278 if [ "$1" = "0" ]; then
279 /usr/sbin/groupdel maildrop 2> /dev/null
280 /usr/sbin/userdel postfix 2> /dev/null
281 /usr/sbin/groupdel postfix 2> /dev/null
284 %triggerpostun -- postfix < 1:1.1.2
285 sed -e 's/^\(pickup[ ]\+fifo[ ]\+[^ ]\+[ ]\+\)[^ ]\+\([ ]\)/\1-\2/;
286 s/^\(cleanup[ ]\+unix[ ]\+\)[^ ]\+\([ ]\)/\1n\2/' /etc/mail/master.cf \
287 > /etc/mail/master.cf.rpmtmp
288 mv -f /etc/mail/master.cf.rpmtmp /etc/mail/master.cf
291 %defattr(644,root,root,755)
292 %doc html *.gz README_FILES/*.gz
294 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/access
295 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/aliases
296 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/canonical
297 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/relocated
298 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/transport
299 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/virtual
300 #%ghost %{_sysconfdir}/mail/*.db
301 %dir %{_sysconfdir}/mail
302 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/dynamicmaps.cf
303 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/main.cf
304 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/master.cf
305 %attr(755,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/mail/postfix-script
306 %attr(755,root,root) %{_sysconfdir}/mail/post-install
307 %{_sysconfdir}/mail/postfix-files
308 %attr(740,root,root) /etc/cron.daily/postfix
309 %attr(754,root,root) /etc/rc.d/init.d/postfix
310 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/postfix
311 %{!?_without_sasl:%config(noreplace) %verify(not size mtime md5) /etc/sasl/smtpd.conf}
312 %attr(755,root,root) %{_libdir}/libpostfix-*.so.*
313 %attr(755,root,root) %{_bindir}/*
314 %attr(755,root,root) %{_sbindir}/s*
315 %attr(755,root,root) %{_sbindir}/postfix
316 %attr(755,root,root) %{_sbindir}/postalias
317 %attr(755,root,root) %{_sbindir}/postkick
318 %attr(755,root,root) %{_sbindir}/postl*
319 %attr(755,root,root) %{_sbindir}/postc*
320 %attr(755,root,root) %{_sbindir}/postmap
321 %attr(2755,root,maildrop) %{_sbindir}/postqueue
322 %attr(755,root,root) %{_sbindir}/postsuper
323 %attr(2755,root,maildrop) %{_sbindir}/postdrop
324 %attr(755,root,root) %{_sbindir}/qmqp-source
325 %attr(755,root,root) %{_libdir}/sendmail
326 %dir %{_libdir}/postfix
327 %attr(755,root,root) %{_libdir}/postfix/[^d]*
328 %attr(755,root,root) %dir %{_var}/spool/postfix
329 %attr(700, postfix,root) %dir %{_var}/spool/postfix/active
330 %attr(700, postfix,root) %dir %{_var}/spool/postfix/bounce
331 %attr(700, postfix,root) %dir %{_var}/spool/postfix/corrupt
332 %attr(700, postfix,root) %dir %{_var}/spool/postfix/defer
333 %attr(700, postfix,root) %dir %{_var}/spool/postfix/deferred
334 %attr(700, postfix,root) %dir %{_var}/spool/postfix/incoming
335 %attr(1730,postfix,maildrop) %dir %{_var}/spool/postfix/maildrop
336 %attr(755, postfix,root) %dir %{_var}/spool/postfix/pid
337 %attr(700, postfix,root) %dir %{_var}/spool/postfix/private
338 %attr(710, postfix,maildrop) %dir %{_var}/spool/postfix/public
339 %attr(700, postfix,root) %dir %{_var}/spool/postfix/saved
340 %attr(644, postfix,root) %{_var}/spool/postfix/.nofinger
344 %defattr(644,root,root,755)
345 %attr(755,root,root) %{_libdir}/libpostfix-*.so
346 %{_includedir}/postfix
349 %defattr(644,root,root,755)
350 %attr(755,root,root) %{_libdir}/postfix/dict_ldap.so
353 %defattr(644,root,root,755)
354 %attr(755,root,root) %{_libdir}/postfix/dict_mysql.so
357 %defattr(644,root,root,755)
358 %attr(755,root,root) %{_libdir}/postfix/dict_pcre.so