commit 9120b2255bc5d65e48881e66faaec4b17d17aea2
Author: Adam Gołębiowski <[email protected]>
Date:   Mon Dec 10 12:34:16 2018 +0100

    - release 2, fix build against clamav-0.101.0

 cyrus-imapd-clamav-0.101.patch | 34 ++++++++++++++++++++++++++++++++++
 cyrus-imapd.spec               |  4 +++-
 2 files changed, 37 insertions(+), 1 deletion(-)
---
diff --git a/cyrus-imapd.spec b/cyrus-imapd.spec
index de36f90..00f9772 100644
--- a/cyrus-imapd.spec
+++ b/cyrus-imapd.spec
@@ -8,7 +8,7 @@ Summary(pl.UTF-8):      Wysoko wydajny serwer IMAP i POP3
 Summary(pt_BR.UTF-8):  Um servidor de mail de alto desempenho que suporta IMAP 
e POP3
 Name:          cyrus-imapd
 Version:       3.0.8
-Release:       1
+Release:       2
 License:       BSD-like
 Group:         Networking/Daemons/POP3
 Source0:       ftp://ftp.cyrusimap.org/cyrus-imapd/%{name}-%{version}.tar.gz
@@ -27,6 +27,7 @@ Source12:     cyrus.conf
 Source13:      cyrus-sync.init
 Patch0:                %{name}-et.patch
 Patch1:                link.patch
+Patch2:                %{name}-clamav-0.101.patch
 URL:           http://www.cyrusimap.org/
 BuildRequires: autoconf >= 2.54
 BuildRequires: automake
@@ -169,6 +170,7 @@ Perlowy interfejs do biblioteki cyrus-imapd.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 rm -rf autom4te.cache
 
diff --git a/cyrus-imapd-clamav-0.101.patch b/cyrus-imapd-clamav-0.101.patch
new file mode 100644
index 0000000..5a9f23f
--- /dev/null
+++ b/cyrus-imapd-clamav-0.101.patch
@@ -0,0 +1,34 @@
+Support clamav >= 0.101.0, based on changes introduced in:
+
+https://github.com/Cisco-Talos/clamav-devel/commit/048a88e61558726bd9ba66ec3195b63d61d8a430
+
+--- cyrus-imapd-3.0.8/imap/cyr_virusscan.c.orig        2018-08-10 
04:59:00.000000000 +0200
++++ cyrus-imapd-3.0.8/imap/cyr_virusscan.c     2018-12-10 10:51:08.776406893 
+0100
+@@ -193,8 +193,17 @@
+     int r;
+ 
+     /* scan file */
++#if LIBCLAMAV_MAJORVER < 9
+     r = cl_scanfile(fname, virname, NULL, st->av_engine,
+                     CL_SCAN_STDOPT);
++#else 
++    static struct cl_scan_options options;
++    
++    memset(&options, 0, sizeof(struct cl_scan_options));
++    options.parse |= ~0; /* enable all parsers */
++
++    r = cl_scanfile(fname, virname, NULL, st->av_engine, &options);
++#endif
+ 
+     switch (r) {
+     case CL_CLEAN:
+--- cyrus-imapd-3.0.8/Makefile.am.orig 2018-12-10 12:15:51.580494168 +0100
++++ cyrus-imapd-3.0.8/Makefile.am      2018-12-10 12:14:59.394460523 +0100
+@@ -879,6 +879,7 @@
+ imap_cyr_sphinxmgr_LDADD = $(LD_UTILITY_ADD)
+ 
+ imap_cyr_virusscan_SOURCES = imap/cli_fatal.c imap/cyr_virusscan.c 
imap/mutex_fake.c
++imap_cyr_virusscan_CFLAGS = $(AM_CFLAGS) $(CLAMAV_CFLAGS) $(CFLAG_VISIBILITY)
+ imap_cyr_virusscan_LDADD = $(LD_UTILITY_ADD) $(CLAMAV_LIBS)
+ 
+ imap_ctl_zoneinfo_SOURCES = imap/cli_fatal.c imap/ctl_zoneinfo.c 
imap/mutex_fake.c imap/zoneinfo_db.c
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/cyrus-imapd.git/commitdiff/9120b2255bc5d65e48881e66faaec4b17d17aea2

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

Reply via email to