| |
@@ -2,13 +2,8 @@
|
| |
|
| |
%global _hardened_build 1
|
| |
|
| |
- ## Fedora Extras specific customization below...
|
| |
- # EL7's curl is too old
|
| |
- %if 0%{?fedora} || 0%{?rhel} >= 8
|
| |
+ ## Fedora specific customization below...
|
| |
%bcond_without clamonacc
|
| |
- %else
|
| |
- %bcond_with clamonacc
|
| |
- %endif
|
| |
%bcond_without tmpfiles
|
| |
%bcond_with unrar
|
| |
%ifnarch ppc64
|
| |
@@ -46,7 +41,7 @@
|
| |
Summary: End-user tools for the Clam Antivirus scanner
|
| |
Name: clamav
|
| |
Version: 0.102.2
|
| |
- Release: 4%{?dist}
|
| |
+ Release: 7%{?dist}
|
| |
License: %{?with_unrar:proprietary}%{!?with_unrar:GPLv2}
|
| |
URL: https://www.clamav.net/
|
| |
%if %{with unrar}
|
| |
@@ -72,6 +67,8 @@
|
| |
Source11: daily-25719.cvd
|
| |
#http://database.clamav.net/bytecode.cvd
|
| |
Source12: bytecode-331.cvd
|
| |
+ #for clamonacc
|
| |
+ Source100: clamonacc.service
|
| |
#for update
|
| |
Source200: freshclam-sleep
|
| |
Source201: freshclam.sysconfig
|
| |
@@ -92,6 +89,8 @@
|
| |
Patch1: clamav-default_confs.patch
|
| |
# Fix pkg-config flags for static linking, multilib
|
| |
Patch2: clamav-0.99-private.patch
|
| |
+ # Patch to use EL7 libcurl
|
| |
+ Patch3: clamav-curl.patch
|
| |
|
| |
BuildRequires: autoconf automake gettext-devel libtool libtool-ltdl-devel
|
| |
BuildRequires: gcc-c++
|
| |
@@ -117,6 +116,7 @@
|
| |
#for milter
|
| |
BuildRequires: sendmail-devel
|
| |
|
| |
+ Requires: clamav-filesystem = %version-%release
|
| |
Requires: clamav-lib = %version-%release
|
| |
Requires: data(clamav)
|
| |
|
| |
@@ -247,6 +247,8 @@
|
| |
%endif
|
| |
%patch1 -p1 -b .default_confs
|
| |
%patch2 -p1 -b .private
|
| |
+ # Patch to use older libcurl
|
| |
+ %{?el7:%patch3 -p1 -b .curl}
|
| |
|
| |
install -p -m0644 %SOURCE300 clamav-milter/
|
| |
|
| |
@@ -316,6 +318,8 @@
|
| |
install -D -m 0644 -p %SOURCE3 _doc_server/clamd.logrotate
|
| |
install -D -m 0644 -p %SOURCE5 _doc_server/README
|
| |
|
| |
+ install -D -p -m 0644 %SOURCE100 $RPM_BUILD_ROOT%_unitdir/clamonacc.service
|
| |
+
|
| |
install -D -p -m 0644 %SOURCE530 $RPM_BUILD_ROOT%_unitdir/clamd@.service
|
| |
|
| |
## prepare the update-files
|
| |
@@ -332,7 +336,6 @@
|
| |
sed -ri \
|
| |
-e 's!^Example!#Example!' \
|
| |
-e 's!^#?(UpdateLogFile )!#\1!g;' \
|
| |
- -e 's!^#?(LogSyslog).*!\1 yes!g' \
|
| |
-e 's!(DatabaseOwner *)clamav$!\1%updateuser!g' $RPM_BUILD_ROOT%_sysconfdir/freshclam.conf.sample
|
| |
|
| |
mv $RPM_BUILD_ROOT%_sysconfdir/freshclam.conf{.sample,}
|
| |
@@ -408,6 +411,16 @@
|
| |
make check
|
| |
|
| |
|
| |
+ %post
|
| |
+ %systemd_post clamonacc.service
|
| |
+
|
| |
+ %preun
|
| |
+ %systemd_preun clamonacc.service
|
| |
+
|
| |
+ %postun
|
| |
+ %systemd_postun_with_restart clamonacc.service
|
| |
+
|
| |
+
|
| |
%pre filesystem
|
| |
getent group %{updateuser} >/dev/null || groupadd -r %{updateuser}
|
| |
getent passwd %{updateuser} >/dev/null || \
|
| |
@@ -512,6 +525,7 @@
|
| |
%_mandir/man[15]/*
|
| |
%exclude %_mandir/*/freshclam*
|
| |
%exclude %_mandir/man5/clamd.conf.5*
|
| |
+ %_unitdir/clamonacc.service
|
| |
|
| |
|
| |
%files lib
|
| |
@@ -532,6 +546,8 @@
|
| |
%files filesystem
|
| |
%attr(-,%updateuser,%updateuser) %dir %homedir
|
| |
%dir %_sysconfdir/clamd.d
|
| |
+ # Used by both clamd, clamdscan, and clamonacc
|
| |
+ %config(noreplace) %_sysconfdir/clamd.d/scan.conf
|
| |
|
| |
|
| |
%files data
|
| |
@@ -566,7 +582,6 @@
|
| |
%_sbindir/clamd
|
| |
%_unitdir/clamd@.service
|
| |
|
| |
- %config(noreplace) %_sysconfdir/clamd.d/scan.conf
|
| |
%ghost %scanstatedir/clamd.sock
|
| |
%if %{with tmpfiles}
|
| |
%_tmpfilesdir/clamd.scan.conf
|
| |
@@ -595,7 +610,20 @@
|
| |
|
| |
|
| |
%changelog
|
| |
- * Mon Mar 16 2020 Orion Poplawski <orion@cora.nwra.com> - 0.102.2-4
|
| |
+ * Wed Apr 29 2020 Orion Poplawski <orion@nwra.com> - 0.102.2-7
|
| |
+ - Move /etc/clamd.d/scan.conf to clamav-filesystem
|
| |
+ - Add patch to build with EL7 libcurl - re-enable on-access scanning
|
| |
+ (bz#1820395)
|
| |
+ - Add clamonacc.service
|
| |
+
|
| |
+ * Tue Apr 21 2020 Björn Esser <besser82@fedoraproject.org> - 0.102.2-6
|
| |
+ - Rebuild (json-c)
|
| |
+
|
| |
+ * Wed Apr 8 2020 Orion Poplawski <orion@nwra.com> - 0.102.2-5
|
| |
+ - Do not log freshclam output to syslog by default - creates double entries
|
| |
+ in the journal (bz#1822012)
|
| |
+
|
| |
+ * Mon Mar 16 2020 Orion Poplawski <orion@nwra.com> - 0.102.2-4
|
| |
- Quiet freshclam-sleep when used with proxy
|
| |
|
| |
* Sat Feb 29 2020 Orion Poplawski <orion@nwra.com> - 0.102.2-3
|
| |
here emphasizes that service needs clamd