-%define database_version 20030207
+%define database_version 20030621
Summary: An anti-virus utility for Unix
Summary(pl): Antywirusowe narzêdzie dla Unixów
Name: clamav
-Version: 0.54
-Release: 4
+Version: 0.60
+Release: 1
License: GPL
Group: Applications
-Source0: http://clamav.elektrapro.com/stable/%{name}-%{version}.tar.gz
+Source0: http://dl.sourceforge.net/clamav/%{name}-%{version}.tar.gz
+# Source0-md5: eddeba4e1f399f65bc71aa2b3e901543
Source1: %{name}.init
Source2: %{name}.sysconfig
# gziped from http://clamav.elektrapro.com/database/:
Source3: %{name}-database-%{database_version}.tar.gz
-URL: http://clamav.elektrapro.com/
+# Source3-md5: 26ba23c5a6e6131e1a8efb397e4be9f2
+URL: http://www.clamav.net/
Requires: %{name}-database
BuildRequires: autoconf
BuildRequires: automake
exit 1
fi
else
- echo "Adding group clamav GID=43"
+ echo "Adding group clamav GID=43"
/usr/sbin/groupadd -g 43 -r -f clamav
fi
if [ -n "`id -u clamav 2>/dev/null`" ]; then
- if [ "`id -u clamav`" != "43" ]; then
- echo "Warning: user clamav doesn't have uid=43. Correct this before installing clamav" 1>&2
- exit 1
- fi
+ if [ "`id -u clamav`" != "43" ]; then
+ echo "Warning: user clamav doesn't have uid=43. Correct this before installing clamav" 1>&2
+ exit 1
+ fi
else
- echo "Adding user clamav UID=43"
- /usr/sbin/useradd -u 43 -r -d /tmp -s /bin/false -c "Clam Anti Virus Checker" -g clamav clamav 1>&2
+ echo "Adding user clamav UID=43"
+ /usr/sbin/useradd -u 43 -r -d /tmp -s /bin/false -c "Clam Anti Virus Checker" -g clamav clamav 1>&2
fi
%post
echo "Run \"/etc/rc.d/init.d/clamd start\" to start Clam Antivirus daemon." >&2
fi
-%postun
-if [ "$1" = "0" ]; then
- echo "Removing user clamav"
- /usr/sbin/userdel clamav
- echo "Removing group clamav"
- /usr/sbin/groupdel clamav
-fi
-
%preun
if [ "$1" = "0" ]; then
if [ -f /var/lock/subsys/clamd ]; then
/sbin/chkconfig --del clamd
fi
+%postun
+if [ "$1" = "0" ]; then
+ echo "Removing user clamav"
+ /usr/sbin/userdel clamav
+ echo "Removing group clamav"
+ /usr/sbin/groupdel clamav
+fi
+
%post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
%files database
%defattr(644,root,root,755)
%attr(644,clamav,root) %verify(not md5 size mtime) /var/lib/%{name}/*.db*
+%attr(644,clamav,root) %verify(not md5 size mtime) /var/lib/%{name}/mirrors.txt