commit 3b3f2bb179814842835d6fa291230779649fa67a
Author: Jan RÄ™korajski <[email protected]>
Date:   Thu Dec 13 23:02:02 2018 +0100

    - fix building with clamav 0.101

 c-icap-modules.spec |  3 +++
 clamav0.101.patch   | 20 ++++++++++++++++++++
 2 files changed, 23 insertions(+)
---
diff --git a/c-icap-modules.spec b/c-icap-modules.spec
index 5019867..d42e69d 100644
--- a/c-icap-modules.spec
+++ b/c-icap-modules.spec
@@ -15,6 +15,7 @@ Group:                Networking/Daemons
 Source0:       
http://downloads.sourceforge.net/c-icap/c_icap_modules-%{version}.tar.gz
 # Source0-md5: 465bb8551bb6039b67b3f785c6d88ee4
 Patch0:                %{name}-build.patch
+Patch1:                clamav0.101.patch
 URL:           http://c-icap.sourceforge.net/
 BuildRequires: bzip2-devel
 BuildRequires: c-icap-devel
@@ -55,9 +56,11 @@ Content filtering service for c-icap.
 %prep
 %setup -q -n c_icap_modules-%{version}
 %patch0 -p1
+%patch1 -p1
 
 %build
 %{__autoconf}
+export CFLAGS="%{rpmcflags} -I/usr/include/clamav"
 %configure
 
 %{__make}
diff --git a/clamav0.101.patch b/clamav0.101.patch
new file mode 100644
index 0000000..7492e5e
--- /dev/null
+++ b/clamav0.101.patch
@@ -0,0 +1,20 @@
+--- c_icap_modules-0.5.2/services/virus_scan/clamav_mod.c.orig 2018-09-11 
16:25:29.000000000 +0200
++++ c_icap_modules-0.5.2/services/virus_scan/clamav_mod.c      2018-12-13 
23:00:00.909055631 +0100
+@@ -123,7 +123,7 @@
+ #ifndef HAVE_LIBCLAMAV_095
+ struct cl_limits limits;
+ #endif
+-unsigned int CLAMSCAN_OPTIONS = CL_SCAN_STDOPT;
++unsigned int CLAMSCAN_OPTIONS = CL_DB_STDOPT;
+ 
+ struct virus_db *virusdb = NULL;
+ struct virus_db *old_virusdb = NULL;
+@@ -489,7 +489,7 @@
+                      CLAMSCAN_OPTIONS);
+ #else
+      ret =
+-         cl_scandesc(fd, &virname, &scanned_data, vdb,
++         cl_scandesc(fd, body->filename, &virname, &scanned_data, vdb,
+                      CLAMSCAN_OPTIONS);
+ #endif
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/c-icap-modules.git/commitdiff/3b3f2bb179814842835d6fa291230779649fa67a

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to