]> git.pld-linux.org Git - packages/postfix.git/blob - postfix.spec
f35dece8fcdc70dcc8b49040de7d9b4c5d6ee64a
[packages/postfix.git] / postfix.spec
1 Summary:     Postfix Mail Transport Agent
2 Name:        postfix
3 Version:     19990122-pl01
4 Release:     3
5 URL:         http://www.postfix.org/
6 Source0:     ftp://postfix.cloud9.net/%{name}-beta-%{version}.tar.gz
7 Source1:     postfix.aliases
8 Source2:     postfix.cron
9 Source3:     postfix.init
10 Source4:     postfix-contrib-beta.tar.gz
11 Source5:     postfix-beta-19990122-pl01.tar.gz.sig
12 Source6:     postfix-contrib-beta.tar.gz.sig
13 Source7:     mail.sh
14 Patch0:      postfix-config.patch
15 Patch1:      postfix-postconf.diff
16 Copyright:   Distributable
17 Group:       Networking/Daemons
18 Provides:    smtpdaemon
19 Conflicts:   sendmail
20 Conflicts:   smail
21 Conflicts:   zmailer
22 Conflicts:   zmail
23 Conflicts:   exim
24 Conflicts:   qmail
25 Prereq:      /sbin/chkconfig
26 BuildRoot:      /tmp/%{name}-%{version}-root
27 Summary(pl): Agent Pocztowy Postfix
28
29 %description
30 Postfix is attempt to provide an alternative to the widely-used
31 Sendmail program. Postfix attempts to be fast, easy to administer,
32 and hopefully secure, while at the same time being sendmail
33 compatible enough to not upset your users.
34          
35 %description -l pl
36 Postfix jest prób± dostarczenia alternatywnego MTA w stosunku
37 do szeroko u¿ywanego sendmaila. Postfix w zamierzeniu ma byæ szybki,
38 ³atwy w administrowaniu, bezpieczny oraz ma byæ na tyle kompatybilny
39 z sendmailem by nie denerwowaæ Twoich u¿ytkowników.
40
41 %prep
42 %setup -q -n %{name}-beta-%{version}
43 %patch0 -p1
44 %patch1 -p1
45
46 %build
47 make -f Makefile.init makefiles
48 make tidy
49 make DEBUG="" OPT="$RPM_OPT_FLAGS"
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53 rm -f html/Makefile.in
54
55 install -d $RPM_BUILD_ROOT/etc/{cron.daily,profile.d,mail,rc.d/init.d}
56 install -d $RPM_BUILD_ROOT/usr/{bin,lib/postfix,man/man{1,5,8},sbin}
57 install -d $RPM_BUILD_ROOT/var/spool/postfix/{active,corrupt,deferred,maildrop,private,saved,bounce,defer,incoming,pid,public}
58
59 install -m755 bin/sendmail bin/post* $RPM_BUILD_ROOT/usr/sbin
60 install -m755 `ls bin/*|egrep -v 'post|fsstone|smtp-|sendmail'` $RPM_BUILD_ROOT/usr/lib/postfix
61 install -m644 conf/access $RPM_BUILD_ROOT/etc/mail
62 install -m644 conf/canonical $RPM_BUILD_ROOT/etc/mail
63 install -m644 conf/main.cf $RPM_BUILD_ROOT/etc/mail
64 install -m644 conf/master.cf $RPM_BUILD_ROOT/etc/mail
65 install -m755 conf/postfix-script-nosgid $RPM_BUILD_ROOT/etc/mail/postfix-script
66 install -m644 conf/relocated $RPM_BUILD_ROOT/etc/mail
67 install -m644 conf/transport $RPM_BUILD_ROOT/etc/mail
68 install -m644 conf/virtual $RPM_BUILD_ROOT/etc/mail
69 install -m644 man/man1/* $RPM_BUILD_ROOT/usr/man/man1
70 install -m644 man/man5/* $RPM_BUILD_ROOT/usr/man/man5
71 install -m644 man/man8/* $RPM_BUILD_ROOT/usr/man/man8
72
73 install -d sample; install -m644 conf/sample* sample
74
75 install -m644 %{SOURCE1} $RPM_BUILD_ROOT/etc/mail/aliases
76 install -m755 %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.daily/postfix
77 install -m755 %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/postfix
78
79 install -m755 %{SOURCE7} $RPM_BUILD_ROOT/etc/profile.d
80
81 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT/usr/bin/mailq
82 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT/usr/bin/newaliases
83 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT/usr/lib/sendmail
84
85 for I in etc/mail/{aliases,access,canonical,relocated,transport,virtual}
86 do
87    touch $RPM_BUILD_ROOT/$I{,.db}
88 done
89
90 strip $RPM_BUILD_ROOT/usr/lib/postfix/* || :
91 gzip -9nf $RPM_BUILD_ROOT/usr/man/man*/*
92 touch $RPM_BUILD_ROOT/var/spool/postfix/.nofinger
93
94 %pre
95 if [ -f /var/lock/subsys/postfix ]; then
96    /etc/rc.d/init.d/postfix stop 2> /dev/null
97 fi
98
99 %post
100 /sbin/chkconfig --add postfix
101
102 if ! grep -q "^hostmaster:" /etc/mail/aliases; then
103         echo "Adding Entry for hostmaster in /etc/mail/aliases"
104         echo "hostmaster:       root" >>/etc/mail/aliases
105 fi
106
107 for i in postmaster postoffice MAILER-DAEMON postmast nobody webmaster administrator \
108 ftpmaster newsmaster w3cache squid news proxy abuse ircd postfix; do
109         if ! grep -q "^$i:" /etc/mail/aliases; then
110                 echo "Adding Entry for $i in /etc/mail/aliases"
111                 echo "$i:       hostmaster" >>/etc/mail/aliases
112         fi
113 done
114 newaliases
115
116 echo "
117 UWAGA ! Postfix standardowo jest skonfigurowany do dostarczania
118 poczty do prywatnych katalogów u¿ytkowników (\$HOME/Mailbox).
119 By u¿ytkownicy mogli czytaæ nadchodz±c± pocztê musisz
120 w pliku konfiguracyjnym /etc/sysconfig/system umie¶ciæ liniê:
121 HOME_MAIL=yes
122 Mo¿esz tak¿e uaktywniæ dostarczanie poczty w standardowe miejsce
123 (/var/spool/mail/\$USER). By to uczyniæ wyedytuj plik
124 /etc/mail/main.cf i zakomentuj liniê:
125 home_mailbox = Mailbox
126
127                                 PLD Team
128 "
129
130 %preun
131 if [ $1 = 0 ]; then
132    if [ -f /var/lock/subsys/postfix ]; then
133       /etc/rc.d/init.d/postfix stop 2> /dev/null
134    fi
135    /sbin/chkconfig --del postfix
136 fi
137
138 %clean
139 rm -rf $RPM_BUILD_ROOT
140
141 %files
142 %defattr(644,root,root,755)
143 %doc html sample 0README COMPATIBILITY HISTORY LICENSE RELEASE_NOTES TODO
144 %config(noreplace) %verify(not size mtime md5) /etc/mail/aliases
145 %ghost /etc/mail/aliases.db
146 %attr(740,root,root) /etc/cron.daily/postfix
147 %dir /etc/mail
148 %config(noreplace) %verify(not size mtime md5) /etc/mail/access
149 %ghost /etc/mail/access.db
150 %config(noreplace) %verify(not size mtime md5) /etc/mail/canonical
151 %ghost /etc/mail/canonical.db
152 %config(noreplace) %verify(not size mtime md5) /etc/mail/main.cf
153 %config(noreplace) %verify(not size mtime md5) /etc/mail/master.cf
154 %attr(755,root,root) %config(noreplace) %verify(not size mtime md5) /etc/mail/postfix-script
155 %config(noreplace) %verify(not size mtime md5) /etc/mail/relocated
156 %ghost /etc/mail/relocated.db
157 %config(noreplace) %verify(not size mtime md5) /etc/mail/transport
158 %ghost /etc/mail/transport.db
159 %config(noreplace) %verify(not size mtime md5) /etc/mail/virtual
160 %ghost /etc/mail/virtual.db
161 %attr(740,root,root) /etc/rc.d/init.d/postfix
162 %attr(755,root,root) /etc/profile.d/mail.sh
163 %attr(755,root,root) /usr/bin/*
164 %attr(755,root,root) /usr/sbin/*
165 %attr(755,root,root) /usr/lib/sendmail
166 %attr(644,root, man) /usr/man/*/*
167 %attr(755,root,root,755) /usr/lib/postfix
168 %attr(755,root,root,755) %dir /var/spool/postfix
169 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/active
170 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/bounce
171 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/corrupt
172 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/defer
173 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/deferred
174 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/incoming
175 %dir %attr(1733,postfix,root,1733) %dir /var/spool/postfix/maildrop
176 %dir %attr(755, postfix,root,755) %dir /var/spool/postfix/pid
177 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/private
178 %dir %attr(755, postfix,root,755) %dir /var/spool/postfix/public
179 %dir %attr(700, postfix,root, 700) %dir /var/spool/postfix/saved
180 %attr(644, postfix,root) /var/spool/postfix/.nofinger
181
182 %changelog
183 * Thu Feb 25 1999 Arkadiusz Mi¶kiewicz <misiek@pld.org.pl>
184 - PLDized
185
186 * Tue Feb 16 1999 Edgard Castro <castro@usmatrix.net>
187   [19990122-pl01-1]
188
189 * Sun Jan 24 1999 Arne Coucheron <arneco@online.no>
190   [19990122-1]
191 - shell for postfix user changed to /bin/true to avoid logins to the account
192 - files in /usr/libexec/postfix moved to /usr/lib/postfix since this complies
193   more with the Red Hat standard
194
195 * Wed Jan 06 1999 Arne Coucheron <arneco@online.no>
196   [19981230-2]
197 - added URL for the source
198 - added a cron job for daily check of errors
199 - sample config files moved from /etc/postfix/sample to the docdir 
200 - dropped making of symlinks in /usr/sbin and instead installing the real
201   files there
202 - because of the previous they're not needed anymore in /usr/libexec/postfix,
203   so they are removed from that place
204
205 * Fri Jan 01 1999 Arne Coucheron <arneco@online.no>
206   [19981230-1]
207
208 * Tue Dec 29 1998 Arne Coucheron <arneco@online.no>
209   [19981222-1]
210 - first build of rpm version
This page took 0.054299 seconds and 3 git commands to generate.