]> git.pld-linux.org Git - packages/clamav.git/commitdiff
Up to 0.105.0 (rust is now needed)
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Mon, 30 May 2022 07:17:22 +0000 (09:17 +0200)
committerArkadiusz Miśkiewicz <arekm@maven.pl>
Mon, 30 May 2022 07:17:22 +0000 (09:17 +0200)
clamav-add-support-for-system-tomsfastmath.patch [deleted file]
clamav.spec
x32.patch

diff --git a/clamav-add-support-for-system-tomsfastmath.patch b/clamav-add-support-for-system-tomsfastmath.patch
deleted file mode 100644 (file)
index 4435deb..0000000
+++ /dev/null
@@ -1,195 +0,0 @@
-From 06669d85088f588ceb781f93367bb5428874ed27 Mon Sep 17 00:00:00 2001
-From: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
-Date: Wed, 11 Mar 2015 20:03:15 +0100
-Subject: add support for system tomsfastmath
-
-Patch-Name: add-support-for-system-tomsfastmath.patch
----
- configure.ac                           |  2 ++
- libclamav/Makefile.am                  | 10 ++++++++--
- libclamav/bignum.h                     |  6 +++++-
- libclamav/xdp.c                        |  2 +-
- m4/reorganization/libs/tomsfastmath.m4 | 12 ++++++++++++
- 5 files changed, 28 insertions(+), 4 deletions(-)
- create mode 100644 m4/reorganization/libs/tomsfastmath.m4
-
-diff -urNp -x '*.orig' clamav-0.103.0.org/libclamav/bignum.h clamav-0.103.0/libclamav/bignum.h
---- clamav-0.103.0.org/libclamav/bignum.h      2020-09-13 02:27:09.000000000 +0200
-+++ clamav-0.103.0/libclamav/bignum.h  2021-04-06 16:40:12.578841141 +0200
-@@ -1,9 +1,13 @@
- #ifndef BIGNUM_H_
- #define BIGNUM_H_
-+#if HAVE_SYSTEM_TOMSFASTMATH
-+#include <tfm.h>
-+#else
- #define TFM_CHECK
--
- #include "bignum_fast.h"
-+#endif
-+
- typedef fp_int mp_int;
- #define mp_cmp fp_cmp
- #define mp_toradix_n(a, b, c, d) fp_toradix_n(a, b, c, d)
-diff -urNp -x '*.orig' clamav-0.103.0.org/libclamav/xdp.c clamav-0.103.0/libclamav/xdp.c
---- clamav-0.103.0.org/libclamav/xdp.c 2020-09-13 02:27:10.000000000 +0200
-+++ clamav-0.103.0/libclamav/xdp.c     2021-04-06 16:40:12.578841141 +0200
-@@ -52,7 +52,7 @@
- #include "scanners.h"
- #include "conv.h"
- #include "xdp.h"
--#include "bignum_fast.h"
-+#include "bignum.h"
- #include "filetypes.h"
- static char *dump_xdp(cli_ctx *ctx, const char *start, size_t sz);
-
---- clamav-0.104.0/libclamav/CMakeLists.txt~   2021-08-27 22:41:31.000000000 +0000
-+++ clamav-0.104.0/libclamav/CMakeLists.txt    2021-10-08 14:11:34.629965363 +0000
-@@ -157,99 +157,6 @@ target_link_libraries( yara
-         PCRE2::pcre2
-         JSONC::jsonc )
--add_library( tomsfastmath OBJECT )
--target_sources( tomsfastmath
--    PRIVATE
--        tomsfastmath/addsub/fp_add.c
--        tomsfastmath/addsub/fp_add_d.c
--        tomsfastmath/addsub/fp_addmod.c
--        tomsfastmath/addsub/fp_cmp.c
--        tomsfastmath/addsub/fp_cmp_d.c
--        tomsfastmath/addsub/fp_cmp_mag.c
--        tomsfastmath/addsub/fp_sub.c
--        tomsfastmath/addsub/fp_sub_d.c
--        tomsfastmath/addsub/fp_submod.c
--        tomsfastmath/addsub/s_fp_add.c
--        tomsfastmath/addsub/s_fp_sub.c
--        tomsfastmath/bin/fp_radix_size.c
--        tomsfastmath/bin/fp_read_radix.c
--        tomsfastmath/bin/fp_read_signed_bin.c
--        tomsfastmath/bin/fp_read_unsigned_bin.c
--        tomsfastmath/bin/fp_reverse.c
--        tomsfastmath/bin/fp_s_rmap.c
--        tomsfastmath/bin/fp_signed_bin_size.c
--        tomsfastmath/bin/fp_to_signed_bin.c
--        tomsfastmath/bin/fp_to_unsigned_bin.c
--        tomsfastmath/bin/fp_toradix.c
--        tomsfastmath/bin/fp_toradix_n.c
--        tomsfastmath/bin/fp_unsigned_bin_size.c
--        tomsfastmath/bit/fp_cnt_lsb.c
--        tomsfastmath/bit/fp_count_bits.c
--        tomsfastmath/bit/fp_div_2.c
--        tomsfastmath/bit/fp_div_2d.c
--        tomsfastmath/bit/fp_lshd.c
--        tomsfastmath/bit/fp_mod_2d.c
--        tomsfastmath/bit/fp_rshd.c
--        tomsfastmath/divide/fp_div.c
--        tomsfastmath/divide/fp_div_d.c
--        tomsfastmath/divide/fp_mod.c
--        tomsfastmath/divide/fp_mod_d.c
--        tomsfastmath/exptmod/fp_2expt.c
--        tomsfastmath/exptmod/fp_exptmod.c
--        tomsfastmath/misc/fp_ident.c
--        tomsfastmath/misc/fp_set.c
--        tomsfastmath/mont/fp_montgomery_calc_normalization.c
--        tomsfastmath/mont/fp_montgomery_reduce.c
--        tomsfastmath/mont/fp_montgomery_setup.c
--        tomsfastmath/mul/fp_mul.c
--        tomsfastmath/mul/fp_mul_comba.c
--        tomsfastmath/mul/fp_mul_2.c
--        tomsfastmath/mul/fp_mul_2d.c
--        tomsfastmath/mul/fp_mul_comba_12.c
--        tomsfastmath/mul/fp_mul_comba_17.c
--        tomsfastmath/mul/fp_mul_comba_20.c
--        tomsfastmath/mul/fp_mul_comba_24.c
--        tomsfastmath/mul/fp_mul_comba_28.c
--        tomsfastmath/mul/fp_mul_comba_3.c
--        tomsfastmath/mul/fp_mul_comba_32.c
--        tomsfastmath/mul/fp_mul_comba_4.c
--        tomsfastmath/mul/fp_mul_comba_48.c
--        tomsfastmath/mul/fp_mul_comba_6.c
--        tomsfastmath/mul/fp_mul_comba_64.c
--        tomsfastmath/mul/fp_mul_comba_7.c
--        tomsfastmath/mul/fp_mul_comba_8.c
--        tomsfastmath/mul/fp_mul_comba_9.c
--        tomsfastmath/mul/fp_mul_comba_small_set.c
--        tomsfastmath/mul/fp_mul_d.c
--        tomsfastmath/mul/fp_mulmod.c
--        tomsfastmath/numtheory/fp_invmod.c
--        tomsfastmath/sqr/fp_sqr.c
--        tomsfastmath/sqr/fp_sqr_comba_12.c
--        tomsfastmath/sqr/fp_sqr_comba_17.c
--        tomsfastmath/sqr/fp_sqr_comba_20.c
--        tomsfastmath/sqr/fp_sqr_comba_24.c
--        tomsfastmath/sqr/fp_sqr_comba_28.c
--        tomsfastmath/sqr/fp_sqr_comba_3.c
--        tomsfastmath/sqr/fp_sqr_comba_32.c
--        tomsfastmath/sqr/fp_sqr_comba_4.c
--        tomsfastmath/sqr/fp_sqr_comba_48.c
--        tomsfastmath/sqr/fp_sqr_comba_6.c
--        tomsfastmath/sqr/fp_sqr_comba_64.c
--        tomsfastmath/sqr/fp_sqr_comba_7.c
--        tomsfastmath/sqr/fp_sqr_comba_8.c
--        tomsfastmath/sqr/fp_sqr_comba_9.c
--        tomsfastmath/sqr/fp_sqr_comba_generic.c
--        tomsfastmath/sqr/fp_sqr_comba_small_set.c
--        tomsfastmath/sqr/fp_sqrmod.c
--    PUBLIC
--        bignum.h
--        bignum_fast.h )
--target_include_directories( tomsfastmath
--    PRIVATE ${CMAKE_BINARY_DIR}
--    PUBLIC  ${CMAKE_CURRENT_SOURCE_DIR} )
--set_target_properties( tomsfastmath PROPERTIES
--    COMPILE_FLAGS "${WARNCFLAGS}" )
--
- # Bytecode Runtime
- add_library( bytecode_runtime OBJECT )
- if(LLVM_FOUND)
-@@ -424,7 +424,7 @@ if(ENABLE_SHARED_LIB)
-             regex
-             lzma_sdk
-             yara
--            tomsfastmath
-+            tfm
-             bytecode_runtime
-             ${LIBMSPACK}
-             ClamAV::libunrar_iface_iface
-@@ -525,7 +525,7 @@ if(ENABLE_STATIC_LIB)
-             regex
-             lzma_sdk
-             yara
--            tomsfastmath
-+            tfm
-             bytecode_runtime
-             ${LIBMSPACK}
-             OpenSSL::SSL
---- clamav-0.104.0/unit_tests/CMakeLists.txt~  2021-08-27 22:41:31.000000000 +0000
-+++ clamav-0.104.0/unit_tests/CMakeLists.txt   2021-10-08 14:20:36.239965193 +0000
-@@ -52,7 +52,7 @@ if(ENABLE_APP)
-             regex
-             lzma_sdk
-             yara
--            tomsfastmath
-+            tfm
-             bytecode_runtime
-             JSONC::jsonc
-             ${LIBMSPACK}
-@@ -92,7 +92,7 @@ if(ENABLE_APP)
-             regex
-             lzma_sdk
-             yara
--            tomsfastmath
-+            tfm
-             bytecode_runtime
-             JSONC::jsonc
-             ${LIBMSPACK}
-@@ -144,7 +144,7 @@ target_link_libraries(check_clamav
-         regex
-         lzma_sdk
-         yara
--        tomsfastmath
-+        tfm
-         bytecode_runtime
-         JSONC::jsonc
-         ${LIBMSPACK}
index 5898f3738a7a4b046c6c92ac97c57314331597a0..dfd56d9d58278c3a04c33cd6a9c4b62ba53b4422 100644 (file)
 Summary:       An anti-virus utility for Unix
 Summary(pl.UTF-8):     Narzędzie antywirusowe dla Uniksów
 Name:          clamav
-Version:       0.104.2
-Release:       2
+Version:       0.105.0
+Release:       1
 License:       GPL v2+
 Group:         Daemons
 #Source0Download: http://www.clamav.net/download
 Source0:       http://www.clamav.net/downloads/production/%{name}-%{version}.tar.gz
-# Source0-md5: ad099675f2c09c07850e36496b06c552
+# Source0-md5: f9994b5036da80f61d18d5941d49545d
 Source1:       %{name}.init
 Source2:       %{name}.sysconfig
 Source3:       %{name}-milter.init
@@ -41,9 +41,9 @@ Source13:     cronjob-clamav.service.in
 Patch0:                %{name}-pld_config.patch
 
 Patch4:                x32.patch
-Patch5:                %{name}-add-support-for-system-tomsfastmath.patch
 URL:           http://www.clamav.net/
 BuildRequires: bzip2-devel >= 1.0.5
+BuildRequires: cargo
 BuildRequires: cmake >= 3.14
 BuildRequires: check-devel
 BuildRequires: curl-devel >= 7.40
@@ -221,7 +221,6 @@ Dokumentacja do ClamAVa.
 %patch0 -p1
 
 %patch4 -p1
-#%patch5 -p1
 
 %build
 install -d build
@@ -233,6 +232,7 @@ cd build
        -DENABLE_APP=ON \
        -DENABLE_CLAMONACC=ON \
        -DENABLE_FRESHCLAM_NO_CACHE=ON \
+       -DENABLE_EXTERNAL_TOMSFASTMATH=ON \
        -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir}/%{name} \
        -DAPP_CONFIG_DIRECTORY=%{_sysconfdir} \
        -DDATABASE_DIRECTORY="/var/lib/%{name}" \
index 5864749be453098382870b71453bc05b4b6f4371..78df1ad07c8ef82cd6f4016645105fac33d90681 100644 (file)
--- a/x32.patch
+++ b/x32.patch
                     tv1.tv_sec * 1000000 + tv1.tv_usec, pc);
      }
      if (stop == CL_EBYTECODE) {
---- clamav-0.104.1/libclamav/bignum_fast.h.orig        2021-11-02 20:09:25.000000000 +0100
-+++ clamav-0.104.1/libclamav/bignum_fast.h     2021-12-11 10:43:55.832213985 +0100
-@@ -102,7 +102,7 @@
+--- clamav-0.104.1/libclamav/tomsfastmath/headers/tfm.h.orig   2021-11-02 20:09:25.000000000 +0100
++++ clamav-0.104.1/libclamav/tomsfastmath/headers/tfm.h        2021-12-11 10:43:55.832213985 +0100
+@@ -118,7 +118,7 @@
  #endif
  
  /* autodetect x86-64 and make sure we are using 64-bit digits with x86-64 asm */
 -#if defined(__x86_64__)
 +#if defined(__x86_64__) && !defined(__ILP32__)
- #if defined(TFM_X86) || defined(TFM_SSE2) || defined(TFM_ARM)
- #error x86-64 detected, x86-32/SSE2/ARM optimizations are not valid!
- #endif
-@@ -117,7 +117,7 @@
   #if defined(TFM_X86) || defined(TFM_SSE2) || defined(TFM_ARM)
       #error x86-64 detected, x86-32/SSE2/ARM optimizations are not valid!
   #endif
+@@ -133,7 +133,7 @@
  #endif
  
  /* try to detect x86-32 */
 -#if defined(__i386__) && !defined(TFM_SSE2)
 +#if (defined(__i386__) || defined(__ILP32__)) && !defined(TFM_SSE2)
- #if defined(TFM_X86_64) || defined(TFM_ARM)
- #error x86-32 detected, x86-64/ARM optimizations are not valid!
- #endif
   #if defined(TFM_X86_64) || defined(TFM_ARM)
       #error x86-32 detected, x86-64/ARM optimizations are not valid!
   #endif
 --- clamav-0.104.1/libclamav/tomsfastmath/mont/fp_montgomery_reduce.c.orig     2021-12-11 10:41:02.011008906 +0100
 +++ clamav-0.104.1/libclamav/tomsfastmath/mont/fp_montgomery_reduce.c  2021-12-11 10:41:23.713556450 +0100
-@@ -42,7 +42,7 @@
+@@ -42,7 +42,7 @@ asm(
  : "%eax", "cc")
  
  /******************************************************************/
@@ -42,4 +42,5 @@
 +#elif defined(TFM_X86_64) && !defined(__ILP32__)
  /* x86-64 code */
  
- #define MONT_START 
+ #define MONT_START
+
This page took 0.133262 seconds and 4 git commands to generate.