diff --git a/mail/cyrus-imapd30/Makefile b/mail/cyrus-imapd30/Makefile index 08284f1fe86c..e1ebc9db72a6 100644 --- a/mail/cyrus-imapd30/Makefile +++ b/mail/cyrus-imapd30/Makefile @@ -58,7 +58,6 @@ BACKUP_CONFIGURE_ENABLE=backup CLAMAV_DESC= Use ClamAV CLAMAV_CONFIGURE_WITH= clamav CLAMAV_LIB_DEPENDS= libclamav.so:security/clamav -CLAMAV_BROKEN= Not buildable with latest clamav HTTP_DESC= Enable HTTP support HTTP_CONFIGURE_ENABLE= http HTTP_LIB_DEPENDS= libical.so:devel/libical \ diff --git a/mail/cyrus-imapd30/files/patch-imap__cyr_virusscan.c b/mail/cyrus-imapd30/files/patch-imap__cyr_virusscan.c new file mode 100644 index 000000000000..bda4a373ddf1 --- /dev/null +++ b/mail/cyrus-imapd30/files/patch-imap__cyr_virusscan.c @@ -0,0 +1,20 @@ +--- imap/cyr_virusscan.c.orig 2018-08-10 02:59:00 UTC ++++ imap/cyr_virusscan.c +@@ -193,8 +193,17 @@ int clamav_scanfile(void *state, const c + int r; + + /* scan file */ ++#ifdef CL_SCAN_STDOPT + 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: