From 9dafc9e421f32bdf6c8e6c953a6be9d6059cd52e Mon Sep 17 00:00:00 2001 From: Renato Botelho Date: Tue, 15 Oct 2013 11:33:56 +0000 Subject: [PATCH] - Fix issue on sparc64 (maybe other architetures?) that prevent clamav to verify database integrity - Bump PORTREVISION PR: ports/182975 Submitted by: Henry Jalonen Obtained from: clamav git repo (a9d40672390a82e91a8d5c21ee2fe172fca4d2f8) --- security/clamav/Makefile | 2 +- .../files/patch-libclamav__bignum_fast.h | 32 +++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 security/clamav/files/patch-libclamav__bignum_fast.h diff --git a/security/clamav/Makefile b/security/clamav/Makefile index fe9e88336b16..6ffe252d9564 100644 --- a/security/clamav/Makefile +++ b/security/clamav/Makefile @@ -3,7 +3,7 @@ PORTNAME= clamav PORTVERSION= 0.98 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= security MASTER_SITES= SF diff --git a/security/clamav/files/patch-libclamav__bignum_fast.h b/security/clamav/files/patch-libclamav__bignum_fast.h new file mode 100644 index 000000000000..98c1ff4a1db7 --- /dev/null +++ b/security/clamav/files/patch-libclamav__bignum_fast.h @@ -0,0 +1,32 @@ +--- libclamav/bignum_fast.h ++++ libclamav/bignum_fast.h +@@ -7,6 +7,14 @@ + * + * Tom St Denis, tomstdenis@gmail.com + */ ++ ++/* Oct 1, 2013 ++ * Adding clamav-config.h include here for size-checking on fall-through case ++ */ ++#if HAVE_CONFIG_H ++#include "clamav-config.h" ++#endif ++ + #ifndef TFM_H_ + #define TFM_H_ + +@@ -249,7 +257,13 @@ + typedef signed long long long64; + #endif + #endif +- typedef unsigned long fp_digit; ++ /* The code requires that fp_word be twice the size of fp_digit. ++ * Add size-checking for special case (both long and long long are 64) */ ++ #if (SIZEOF_LONG == 8) && (SIZEOF_LONG_LONG == 8) ++ typedef unsigned int fp_digit; ++ #else ++ typedef unsigned long fp_digit; ++ #endif + typedef ulong64 fp_word; + #endif +