[packages/avscan] - added clamav patch (fix build with clamav 0.101); release 2

qboosh qboosh at pld-linux.org
Mon Dec 10 21:15:07 CET 2018


commit b3cb60936643335a94d9105f274d738ab67c9dfc
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Mon Dec 10 21:18:26 2018 +0100

    - added clamav patch (fix build with clamav 0.101); release 2

 avscan-clamav.patch | 34 ++++++++++++++++++++++++++++++++++
 avscan.spec         |  2 ++
 2 files changed, 36 insertions(+)
---
diff --git a/avscan.spec b/avscan.spec
index 6a19c25..d582e7a 100644
--- a/avscan.spec
+++ b/avscan.spec
@@ -8,6 +8,7 @@ Group:		X11/Applications
 Source0:	http://wolfsinger.com/~wolfpack/packages/%{name}-%{version}-openssl.tar.bz2
 # Source0-md5:	e8e76867fbdf4ddef9504b604db95667
 Patch0:		%{name}-verbose.patch
+Patch1:		%{name}-clamav.patch
 URL:		http://freecode.com/projects/avscan
 BuildRequires:	clamav-devel
 BuildRequires:	endeavour-devel >= 3
@@ -34,6 +35,7 @@ graficznym.
 %prep
 %setup -q -n %{name}-%{version}-openssl
 %patch0 -p1
+%patch1 -p1
 
 %build
 ./configure Linux
diff --git a/avscan-clamav.patch b/avscan-clamav.patch
new file mode 100644
index 0000000..b7d46cf
--- /dev/null
+++ b/avscan-clamav.patch
@@ -0,0 +1,34 @@
+--- avscan-5.1.1-openssl/avscan/avs_avengine_scan.c.orig	2009-04-07 02:00:00.000000000 +0200
++++ avscan-5.1.1-openssl/avscan/avs_avengine_scan.c	2018-12-10 20:57:11.242064885 +0100
+@@ -750,6 +750,13 @@
+ 	guint options;
+ 	gchar *s;
+ 	const gchar *virus_name = NULL;
++#ifdef CL_SCAN_GENERAL_ALLMATCHES
++	struct cl_scan_options scan_options = {CL_SCAN_GENERAL_ALLMATCHES,
++		                               0x3FF, // where is the convenience alias for all?
++					       0,
++					       0,
++					       0};
++#endif
+ 
+ 	/* Interrupted? */
+ 	if(*stop_count > 0)
+@@ -833,10 +841,17 @@
+ 	/* Scan this file */
+ 	status = (gint)cl_scandesc(
+ 		fd,
++#ifdef CL_SCAN_GENERAL_ALLMATCHES
++		path,
++#endif
+ 		&virus_name,
+ 		&scanned_blocks,
+ 		d->engine,
++#ifdef CL_SCAN_GENERAL_ALLMATCHES
++		&scan_options
++#else
+ 		(unsigned int)options
++#endif
+ 	);
+ 
+ 	/* Close the file */
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/avscan.git/commitdiff/b3cb60936643335a94d9105f274d738ab67c9dfc



More information about the pld-cvs-commit mailing list