]> git.pld-linux.org Git - packages/sendmail.git/blob - sendmail.spec
- 'if you want to use e-mail - you have to use sendmail' removed :)
[packages/sendmail.git] / sendmail.spec
1 Summary:        Sendmail -- mail transport agent
2 Summary(pl):    Sendmail -- aplikacja do obs³ugi poczty elektronicznej
3 Name:           sendmail
4 Version:        8.9.3
5 Release:        4
6 Copyright:      distributable (similar to, but not quite BSD)
7 Group:          Networking/Daemons
8 Group(pl):      Sieciowe/Serwery
9 Source0:        ftp://ftp.sendmail.org/pub/sendmail/%{name}.%{version}.tar.gz
10 Source1:        site.Linux.m4
11 Source2:        aliases
12 Source3:        %{name}.init
13 Source4:        site.Linux.ppc.m4
14 Source5:        %{name}.sysconfig
15 Patch0:         %{name}-ipv6.patch
16 Patch1:         %{name}-dtelnet.patch
17 Patch2:         %{name}-path.patch
18 Patch3:         %{name}-rmail.patch
19 Patch4:         %{name}-pld.mc.patch
20 Patch5:         %{name}-redirect.patch
21 Patch6:         %{name}-smrsh.patch
22 Patch7:         %{name}-release.patch
23 BuildRoot:      /tmp/%{name}-%{version}-root
24 URL:            http://www.sendmail.org
25 Prereq:         /sbin/chkconfig
26 Requires:       rc-scripts
27 Obsoletes:      zmail
28 Obsoletes:      qmail
29 Obsoletes:      smail
30
31 %description 
32 Sendmail is a Mail Transport Agent, which is the program
33 that moves mail from one machine to another.  Sendmail implements a
34 general internetwork mail routing facility, featuring aliasing and
35 forwarding, automatic routing to network gateways, and flexible
36 configuration.
37
38 If you need the ability to send and receive mail via the internet
39 you'll need sendmail or another MTA.
40
41 %description -l pl
42 Sendmail jest programem umo¿liwiaj±cym wymianê poczty elektronicznej
43 miêdzy komputerami w sieci internet. Zajmuje siê przekazywaniem poczty
44 elektronicznej miêdzy bramkami pocztowymi i dostarczaniem przesy³ek na 
45 konta docelowe. Bardzo dobrze obs³uguje aliasy pocztowe a jego dodatkowym 
46 atutem jest prosta konfiguracja. Dziêki rozbudowanym mo¿liwo¶ciom 
47 konfiguracyjnym jest w stanie dostarczaæ przesy³ki za po¶rednictwem 
48 protoko³ów: SMTP, ESMTP, UUCP, X.400 i innych.
49
50 Je¿eli masz zamiar korzystaæ z poczty elektronicznej w sieci internet
51 oraz 6bone to zainstaluj ten pakiet.
52
53 %package        cf
54 Summary:        Sendmail configuration files and m4 macros
55 Summary(pl):    Pliki konfiguracyjne oraz makra m4 dla sendmaila
56 Group:          Daemons
57 Group(pl):      Serwery
58 Requires:       %{name} = %{version}
59
60 %description cf
61 This package contains all the configuration files used to generate
62 the sendmail.cf file distributed with the base sendmail package.
63 You'll want this package if you need to reconfigure and rebuild
64 your sendmail.cf file.  For example, the default sendmail.cf is
65 not configured for UUCP.  If you need to send and receive mail
66 over UUCP, you may need this package to help you reconfigure sendmail.
67
68 %description -l pl cf
69 Pakiet ten zawiera wszystkie pliki konfiguracyjne u¿ywane do gene-
70 rowania pliku sendmail.cf, znajduj±cego siê w pakiecie bazowym.
71 Bêdziesz potrzebowa³ tego pakietu je¿eli chcesz zmieniæ i przebudowaæ
72 konfiguracjê swojego sendmaila. Na przyk³ad, standardowy plik konfigu-
73 racyjny nie zawiera wspomagania dla poczty po UUCP. Je¿eli chcesz wy-
74 sy³aæ i odbieraæ pocztê po UUCP bêdziesz potrzebowa³ tego pakietu.
75
76 %prep
77 %setup -q
78 %patch0 -p1
79 %patch1 -p1
80 %patch2 -p1
81 %patch3 -p1
82 %patch4 -p1
83 %patch5 -p1
84 %patch6 -p1
85 %patch7 -p1
86
87 %build
88 ID="`id -u`"
89 GID="`id -g`"
90 OPT=$RPM_OPT_FLAGS
91
92 cat %{SOURCE1} |sed s/gid/"$GID"/g | sort | sed s/id/"$ID"/g | sort | \
93 sed s/opt/"$OPT"/g > BuildTools/Site/site.Linux.m4
94
95 cd src
96 ./makesendmail
97 cd ../
98 make makemap mailstats praliases rmail 
99 make smrsh LDOPTS="-s -static" 
100 (
101 cd cf/cf
102 /usr/bin/m4 pld.mc >> ./sendmail.cf
103 )
104
105 %install
106 rm -rf $RPM_BUILD_ROOT
107
108 install -d $RPM_BUILD_ROOT/etc/{mail,rc.d/init.d,sysconfig}
109 install -d $RPM_BUILD_ROOT/usr/{bin,lib,sbin,share/sendmail-cf,libexec}
110 install -d $RPM_BUILD_ROOT/usr/share/{man/man{1,5,8},misc}
111 install -d $RPM_BUILD_ROOT/var/{run,spool/{mqueue,mail}}
112
113 install %{SOURCE2} $RPM_BUILD_ROOT/etc/mail/aliases
114 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/sendmail
115
116 touch $RPM_BUILD_ROOT/etc/mail/{sendmail.{ct,cw},relay-domains}
117
118 for i in aliases access domaintable genericstable mailertable majordomo \
119 virtusertable
120 do touch $RPM_BUILD_ROOT/etc/mail/$i{,.db}
121 done
122
123 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/sendmail
124
125 make DESTDIR=$RPM_BUILD_ROOT install
126 make DESTDIR=$RPM_BUILD_ROOT OPTIONS=force-install rmail 
127
128 for i in hoststat mailq newaliases purgestat
129         do ln -sf ../sbin/sendmail  $RPM_BUILD_ROOT/usr/bin/$i
130 done
131 ln -sf ../sbin/sendmail $RPM_BUILD_ROOT/usr/lib/sendmail
132
133 install cf/cf/sendmail.cf $RPM_BUILD_ROOT/etc/mail
134
135 cp cf/* $RPM_BUILD_ROOT/usr/share/sendmail-cf/ -a
136
137 mv $RPM_BUILD_ROOT/etc/mail/*.hf $RPM_BUILD_ROOT/usr/share/misc
138
139 cat $RPM_BUILD_ROOT/etc/mail/sendmail.cf |sed s/DZ8.9.3/DZLinux/g > \
140     $RPM_BUILD_ROOT/etc/mail/sendmail.cf.new
141
142 mv $RPM_BUILD_ROOT/etc/mail/sendmail.cf.new $RPM_BUILD_ROOT/etc/mail/sendmail.cf    
143
144 cp smrsh/README smrsh/SMRSH.txt
145
146 gzip -9fn $RPM_BUILD_ROOT/usr/share/man/man[158]/*
147 gzip -9fn README KNOWNBUGS RELEASE_NOTES smrsh/SMRSH.txt
148
149 %post
150 /sbin/chkconfig --add sendmail
151 if [ -f /var/lock/subsys/sendmail ]; then
152     /etc/rc.d/init.d/sendmail restart >&2
153 fi
154
155 %preun
156 if [ -e /var/lock/sybsys/sendmail ]; then
157     /etc/rc.d/init.d/sendmail stop &>/dev/null
158 fi
159
160 if [ $1 = 0 ]; then
161    /sbin/chkconfig --del sendmail
162 fi
163
164 %clean
165 rm -rf $RPM_BUILD_ROOT
166
167 %files
168 %defattr(644,root,root,755)
169 %doc {README,KNOWNBUGS,RELEASE_NOTES}.gz 
170 %doc smrsh/SMRSH.txt.gz
171
172 %attr(750,root,root) %dir /etc/mail
173 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/mail/*
174 %attr(640,root,root) %config %verify(not size mtime md5) /etc/sysconfig/*
175 %attr(755,root,root) /etc/rc.d/init.d/*
176
177 %attr(755,root,root) /usr/bin/*
178
179 %attr(755,root,root) /usr/sbin/mailstats
180 %attr(755,root,root) /usr/sbin/makemap
181 %attr(755,root,root) /usr/sbin/praliases
182
183 %attr(4711,root,root) /usr/sbin/sendmail
184
185 %attr(755,root,root) /usr/lib/sendmail
186 %attr(755,root,root) /usr/sbin/smrsh
187
188 /usr/share/man/man[158]/*
189 /usr/share/misc/*.hf
190
191 %ghost /var/run/sendmail.st
192
193 %files cf
194 %defattr(644,root,root,755)
195
196 %dir /usr/share/sendmail-cf
197 %attr(-,root,root) /usr/share/sendmail-cf/*
This page took 0.083026 seconds and 4 git commands to generate.