2 # conditional build _with_mks32 support for mks32 i386 _only_
4 %include /usr/lib/rpm/macros.perl
5 Summary: A Mail Virus Scanner
6 Summary(pl): Antywirusowy skaner poczty elektronicznej
10 URL: http://www.amavis.org/
11 Source0: http://www.amavis.org/dist/perl/%{name}-perl-%{version}.tar.gz
12 %{?_with_mks32:Patch0: %{name}-perl-mks32.patch}
14 Group: Applications/Mail
16 BuildRequires: autoconf >= 2.52
18 BuildRequires: perl-modules
19 BuildRequires: perl-Convert-UUlib
20 BuildRequires: perl-Convert-TNEF
21 BuildRequires: perl-Unix-Syslog
22 BuildRequires: perl-Archive-Tar
23 BuildRequires: perl-Archive-Zip
24 BuildRequires: perl-Compress-Zlib
25 BuildRequires: perl-MIME-tools
27 BuildRequires: sh-utils
32 BuildRequires: ncompress
44 Requires: %{_sbindir}/sendmail
45 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48 AMaViS is a script that interfaces a mail transport agent (MTA) with
49 one or more virus scanners.
52 AMaViS to skrypt po¶rednicz±cy pomiêdzy agentem transferu poczty (MTA)
53 a jednym lub wiêcej programów antywirusowych.
56 %setup -q -n %{name}-perl-%{version}
57 %{?_with_mks32:%patch -p1}
63 --with-sendmail-wrapper=%{_sbindir}/sendmail \
64 --with-runtime-dir=/var/spool/amavis/runtime \
65 --with-virusdir=/var/spool/amavis/virusmails \
66 --with-mailto="postmaster" \
67 --with-amavisuser=amavis
71 gzip -9nf README* AUTHORS BUGS ChangeLog FAQ HINTS TODO doc/amavis.html
74 rm -rf $RPM_BUILD_ROOT
78 DESTDIR=$RPM_BUILD_ROOT
81 %defattr(644,root,root,755)
82 %attr(755,root,root) %{_sbindir}/*
83 %doc *.gz doc/*.gz doc/amavis.png
84 %attr(750,amavis,root) /var/spool/amavis
87 if [ -n "`id -u amavis 2>/dev/null`" ]; then
88 if [ "`id -u amavis`" != "97" ]; then
89 echo "Warning: user amavis haven't uid=97. Correct this before installing amavis" 1>&2
93 /usr/sbin/useradd -u 97 -r -d /var/spool/amavis -s /bin/false -c "Anti Virus Checker" -g nobody amavis 1>&2
97 if [ "$1" = "0" ]; then
98 /usr/sbin/userdel amavis
102 rm -rf $RPM_BUILD_ROOT