]> TLD Linux GIT Repositories - packages/clamav.git/commitdiff
- merged 0.98.3 from PLD, fixed ac patch
authorMarcin Krol <hawk@tld-linux.org>
Fri, 16 May 2014 09:51:57 +0000 (09:51 +0000)
committerMarcin Krol <hawk@tld-linux.org>
Fri, 16 May 2014 09:51:57 +0000 (09:51 +0000)
ac2.68.patch
am-nosilentrules.patch [deleted file]
clamav-major.patch [new file with mode: 0644]
clamav-nolibs.patch
clamav-openssl.patch [new file with mode: 0644]
clamav.spec

index ba4ae541acc08fa737405d663651bc1a21d23c00..68fe4d2766324d8d98b3d79d952bd2b062df2774 100644 (file)
@@ -1,25 +1,33 @@
-diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
---- clamav-0.98.orig/configure.ac      2013-09-21 10:56:27.087891623 +0000
-+++ clamav-0.98/configure.ac   2013-09-21 11:01:02.996891571 +0000
-@@ -54,6 +54,8 @@
- AC_PROG_INSTALL
- AC_PROG_LN_S
- AC_PROG_MAKE_SET
-+AM_PROG_AR
-+AM_PROG_CC_C_O
+diff -uNr clamav-0.98.3/configure.ac clamav-0.98.3-ac2.68/configure.ac
+--- clamav-0.98.3/configure.ac 2014-05-06 20:42:41.000000000 +0200
++++ clamav-0.98.3-ac2.68/configure.ac  2014-05-09 10:51:30.508280355 +0200
+@@ -42,12 +42,12 @@
+ AC_DEFINE([PACKAGE], PACKAGE_NAME, [Name of package])
+ m4_include([m4/reorganization/version.m4])
++m4_include([m4/reorganization/build_tools.m4])
  
  LT_CONFIG_LTDL_DIR([libltdl])
  LT_INIT([dlopen disable-static])
-@@ -469,7 +471,7 @@
+ LTDL_INIT([recursive])
  
- if test "$enable_check_ut" != "no" ; then
-       AC_LIB_FIND([check],[check.h],
--                      AC_LANG_PROGRAM([#include <check.h>],[srunner_create(0)]),
-+                      [AC_LANG_PROGRAM([#include <check.h>],[srunner_create(0)])],
-                       [CHECK_CPPFLAGS="$INCCHECK"; CHECK_LIBS="$LTLIBCHECK"],
-                       [])
- fi
-@@ -1548,8 +1550,8 @@
+-m4_include([m4/reorganization/build_tools.m4])
+ m4_include([m4/reorganization/headers.m4])
+ AC_CONFIG_FILES([libltdl/Makefile])
+diff -uNr clamav-0.98.3/m4/reorganization/build_tools.m4 clamav-0.98.3-ac2.68/m4/reorganization/build_tools.m4
+--- clamav-0.98.3/m4/reorganization/build_tools.m4     2014-05-06 20:39:56.000000000 +0200
++++ clamav-0.98.3-ac2.68/m4/reorganization/build_tools.m4      2014-05-09 10:53:30.800262620 +0200
+@@ -1,3 +1,5 @@
++AM_PROG_AR
+ AC_PROG_CC
++AM_PROG_CC_C_O
+ AC_PROG_INSTALL
+ AC_PROG_LN_S
+diff -uNr clamav-0.98.3/m4/reorganization/clamdtop.m4 clamav-0.98.3-ac2.68/m4/reorganization/clamdtop.m4
+--- clamav-0.98.3/m4/reorganization/clamdtop.m4        2014-05-06 20:39:56.000000000 +0200
++++ clamav-0.98.3-ac2.68/m4/reorganization/clamdtop.m4 2014-05-09 10:51:06.963907781 +0200
+@@ -6,8 +6,8 @@
  if test "$enable_clamdtop" != "no"; then
  
  AC_LIB_FIND([ncurses], [ncurses/ncurses.h],
@@ -30,7 +38,7 @@ diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
            [CURSES_CPPFLAGS="$INCNCURSES"; CURSES_LIBS="$LTLIBNCURSES";
             CURSES_INCLUDE="<ncurses/ncurses.h>"],
            [])
-@@ -1557,8 +1559,8 @@
+@@ -15,8 +15,8 @@
  if test "X$HAVE_LIBNCURSES" != "Xyes"; then
      HAVE_LIBNCURSES=
      AC_LIB_FIND([ncurses], [ncurses.h],
@@ -41,7 +49,7 @@ diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
            [CURSES_CPPFLAGS="$INCNCURSES"; CURSES_LIBS="$LTLIBNCURSES";
             CURSES_INCLUDE="<ncurses.h>"],
            [])
-@@ -1566,8 +1568,8 @@
+@@ -24,8 +24,8 @@
  
  if test "X$HAVE_LIBNCURSES" != "Xyes"; then
      AC_LIB_FIND([pdcurses],[curses.h],
@@ -52,3 +60,15 @@ diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
                            [CURSES_CPPFLAGS="$INCPDCURSES";
                             CURSES_LIBS="$LTLIBPDCURSES";
                             CURSES_INCLUDE="<curses.h>"],
+diff -uNr clamav-0.98.3/m4/reorganization/code_checks/unit_tests.m4 clamav-0.98.3-ac2.68/m4/reorganization/code_checks/unit_tests.m4
+--- clamav-0.98.3/m4/reorganization/code_checks/unit_tests.m4  2014-05-06 20:39:56.000000000 +0200
++++ clamav-0.98.3-ac2.68/m4/reorganization/code_checks/unit_tests.m4   2014-05-09 10:51:06.963907781 +0200
+@@ -12,7 +12,7 @@
+ esac
+       AC_LIB_FIND([check],[check.h],
+-                      AC_LANG_PROGRAM([#include <check.h>],[srunner_create(0)]),
++                      [AC_LANG_PROGRAM([#include <check.h>],[srunner_create(0)])],
+                       [CHECK_CPPFLAGS="$INCCHECK"; CHECK_LIBS="$LTLIBCHECK $LDFLAGS"],
+                       [])
diff --git a/am-nosilentrules.patch b/am-nosilentrules.patch
deleted file mode 100644 (file)
index 6fb6762..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
---- clamav-0.98.orig/configure.ac      2013-09-21 10:55:23.897891162 +0000
-+++ clamav-0.98/configure.ac   2013-09-21 10:55:51.287891575 +0000
-@@ -34,8 +34,7 @@
- dnl -Wall and -Werror here are NOT CFLAGS, they refer to automake warnings
- dnl enable stealth builds and psychedelic tests
--AM_INIT_AUTOMAKE([1.11 -Wall -Wportability -Wno-override -Werror std-options foreign dist-bzip2 no-define color-tests parallel-tests tar-ustar])
--AM_SILENT_RULES([yes])
-+AM_INIT_AUTOMAKE([1.10 -Wall -Wportability -Wno-override -Werror std-options foreign dist-bzip2 no-define tar-ustar])
- dnl we told automake to not define these, since we want to include
- dnl the date in the version
-diff -ur clamav-0.98.orig/m4/acinclude.m4 clamav-0.98/m4/acinclude.m4
---- clamav-0.98.orig/m4/acinclude.m4   2013-09-16 19:28:14.000000000 +0000
-+++ clamav-0.98/m4/acinclude.m4        2013-09-21 10:55:51.287891575 +0000
-@@ -880,9 +880,9 @@
- AC_DEFUN([CL_MSG_STATUS],
- [
-    m4_if($#,3,,[m4_fatal([$0: invalid number of arguments: $#])])
--   AS_ECHO_N(["              $1: "])
--   AS_IF([test "x$3" = "xno"], [AS_ECHO(["$2 (disabled)"])],
--       [test "x$3" = "xyes"], [AS_ECHO(["$2"])],
--       [test "x$3" = "x"], [AS_ECHO(["$2"])],
--       [AS_ECHO(["$2 ($3)"])])
-+   echo ["              $1: "]
-+   AS_IF([test "x$3" = "xno"], [echo ["$2 (disabled)"]],
-+       [test "x$3" = "xyes"], [echo ["$2"]],
-+       [test "x$3" = "x"], [echo ["$2"]],
-+       [echo ["$2 ($3)"]])
- ])
diff --git a/clamav-major.patch b/clamav-major.patch
new file mode 100644 (file)
index 0000000..e5fab9c
--- /dev/null
@@ -0,0 +1,16 @@
+--- clamav-0.98.3/m4/reorganization/version.m4~        2014-05-06 20:59:19.000000000 +0200
++++ clamav-0.98.3/m4/reorganization/version.m4 2014-05-14 20:33:00.181291208 +0200
+@@ -8,10 +8,11 @@
+ LIBCLAMAV_VERSION="$LC_CURRENT":"$LC_REVISION":"$LC_AGE"
+ AC_SUBST([LIBCLAMAV_VERSION])
+-AC_DEFINE_UNQUOTED([LIBCLAMAV_FULLVER], "$major.$LC_AGE.$LC_REVISION",
++MAJOR_VER=$(( $LC_CURRENT - $LC_AGE ))
++AC_DEFINE_UNQUOTED([LIBCLAMAV_FULLVER], "$MAJOR_VER.$LC_AGE.$LC_REVISION",
+         ["Full library version number"])
+-AC_DEFINE_UNQUOTED([LIBCLAMAV_MAJORVER], $major, ["Major library version number"])
++AC_DEFINE_UNQUOTED([LIBCLAMAV_MAJORVER], $MAJOR_VER, ["Major library version number"])
+ AC_DEFINE_UNQUOTED([VERSION],"$VERSION",[Version number of package])
+ AC_DEFINE_UNQUOTED([VERSION_SUFFIX],"$VERSION_SUFFIX",[Version suffix for package])
index 8b915c0f6514a484735e2e0edf86e6339f5a07ae..6196a05ee3d51c3a788af659eed0c10f33096be1 100644 (file)
@@ -1,9 +1,7 @@
-diff -ur clamav-0.98.orig/configure.ac clamav-0.98/configure.ac
---- clamav-0.98.orig/configure.ac      2013-09-16 19:28:14.000000000 +0000
-+++ clamav-0.98/configure.ac   2013-09-21 10:54:26.398891553 +0000
-@@ -430,8 +430,12 @@
- AC_SUBST([BUILD_CONFIGURE_FLAGS], [$build_configure_args])
+diff -uNr clamav-0.98.3/m4/reorganization/code_checks/functions.m4 clamav-0.98.3.nolibs/m4/reorganization/code_checks/functions.m4
+--- clamav-0.98.3/m4/reorganization/code_checks/functions.m4   2014-05-06 20:39:56.000000000 +0200
++++ clamav-0.98.3.nolibs/m4/reorganization/code_checks/functions.m4    2014-05-09 10:38:20.376934561 +0200
+@@ -1,6 +1,10 @@
  AX_CHECK_UNAME_SYSCALL
 +AC_CHECK_FUNC(socket,, [
  AC_CHECK_LIB([socket], [bind], [LIBS="$LIBS -lsocket"; CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket"; FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lsocket"; CLAMD_LIBS="$CLAMD_LIBS -lsocket"])
diff --git a/clamav-openssl.patch b/clamav-openssl.patch
new file mode 100644 (file)
index 0000000..dd8de6e
--- /dev/null
@@ -0,0 +1,18 @@
+diff -uNr clamav-0.98.3/m4/reorganization/libs/openssl.m4 clamav-0.98.3-openssl/m4/reorganization/libs/openssl.m4
+--- clamav-0.98.3/m4/reorganization/libs/openssl.m4    2014-05-06 20:39:56.000000000 +0200
++++ clamav-0.98.3-openssl/m4/reorganization/libs/openssl.m4    2014-05-09 13:51:47.581181238 +0200
+@@ -22,12 +22,12 @@
+     AC_MSG_ERROR([OpenSSL not found.])
+ fi
+-SSL_LDFLAGS="-L$LIBSSL_HOME/lib"
++SSL_LDFLAGS=""
+ SSL_LIBS="-lssl -lcrypto"
+ SSL_CPPFLAGS="-I$LIBSSL_HOME/include"
+ save_LDFLAGS="$LDFLAGS"
+-LDFLAGS="-L$LIBSSL_HOME/lib $SSL_LIBS"
++LDFLAGS="$SSL_LDFLAGS $SSL_LIBS"
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$SSL_CPPFLAGS"
index d9a2787cb67b2225982dcf84632aadce50528e3c..677539004e7ac22b1f75ad034c4620ce1ba07fae 100644 (file)
@@ -3,18 +3,18 @@
 # - restart amavis in triggers if group membership was modified?
 #
 # Conditional build:
-%bcond_without milter          # build without milter subpackage
-%bcond_without llvm            # build without llvm support
+%bcond_without milter          # milter interface subpackage
+%bcond_without llvm            # LLVM support
 
 Summary:       An anti-virus utility for Unix
 Summary(pl.UTF-8):     Narzędzie antywirusowe dla Uniksów
 Name:          clamav
-Version:       0.98.1
+Version:       0.98.3
 Release:       1
 License:       GPL v2+
 Group:         Daemons
 Source0:       http://downloads.sourceforge.net/clamav/%{name}-%{version}.tar.gz
-# Source0-md5: b1ec7b19dea8385954515ef1d63576d8
+# Source0-md5: b649d35ee85d4d6075a98173dd255c17
 Source1:       %{name}.init
 Source2:       %{name}.sysconfig
 Source3:       %{name}-milter.init
@@ -26,12 +26,14 @@ Source10:   %{name}.tmpfiles
 Source11:      clamd.service
 Patch0:                %{name}-config.patch
 Patch1:                %{name}-nolibs.patch
-Patch2:                am-nosilentrules.patch
-Patch3:                ac2.68.patch
+Patch2:                ac2.68.patch
+Patch3:                %{name}-openssl.patch
+Patch4:                %{name}-major.patch
 URL:           http://www.clamav.net/
 BuildRequires: autoconf
 BuildRequires: automake
 BuildRequires: bzip2-devel
+BuildRequires: curl-devel
 BuildRequires: gmp-devel
 BuildRequires: libltdl-devel
 %{?with_milter:BuildRequires:  libmilter-devel}
@@ -40,6 +42,7 @@ BuildRequires:        libtool
 %{?with_milter:BuildRequires:  libwrap-devel}
 %{?with_llvm:BuildRequires:    llvm-devel}
 BuildRequires: ncurses-devel
+BuildRequires: openssl-devel
 BuildRequires: rpm >= 4.4.9-56
 BuildRequires: rpmbuild(macros) >= 1.647
 BuildRequires: zlib-devel
@@ -58,6 +61,7 @@ Requires:     %{name}-libs = %{epoch}:%{version}-%{release}
 Requires:      /usr/sbin/usermod
 Requires:      rc-scripts >= 0.4.1.23
 Suggests:      clamav-database
+Suggests:      crondaemon
 Provides:      group(clamav)
 Provides:      user(clamav)
 Conflicts:     logrotate < 3.7-4
@@ -129,7 +133,9 @@ Summary(pl.UTF-8):  clamav - Pliki nagłówkowe i biblioteki dla programistów
 Group:         Development/Libraries
 Requires:      %{name}-libs = %{epoch}:%{version}-%{release}
 Requires:      bzip2-devel
+Requires:      curl-devel
 Requires:      gmp-devel
+Requires:      openssl-devel
 Requires:      zlib-devel
 
 %description devel
@@ -158,16 +164,18 @@ Biblioteki statyczne clamav.
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
 
 %build
-# automake 1.12+ needs configure.ac not .in
 %{__libtoolize}
 %{__aclocal} -I m4
 %{__autoconf}
 %{__autoheader}
 %{__automake}
 %configure \
+       --disable-silent-rules \
        --disable-clamav \
+       --enable-clamdtop \
        %{?with_milter:--enable-milter} \
        --with-dbdir=/var/lib/%{name} \
        --with-no-cache \
@@ -200,16 +208,16 @@ cp -p %{SOURCE9} $RPM_BUILD_ROOT/etc/sysconfig/clamav-milter
 %endif
 cp -p %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/clamd
 install -p %{SOURCE4} $RPM_BUILD_ROOT%{_sbindir}/clamav-cron-updatedb
-cp -p etc/clamav-milter.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/clamav-milter.conf
-cp -p etc/clamd.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/clamd.conf
-cp -p etc/freshclam.conf.sample $RPM_BUILD_ROOT%{_sysconfdir}/freshclam.conf
+for i in $RPM_BUILD_ROOT%{_sysconfdir}/*.conf.sample; do
+       mv $i ${i%%.sample}
+done
 cp -p %{SOURCE5} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
 
 install -p %{SOURCE8} $RPM_BUILD_ROOT%{_sbindir}
 
-install %{SOURCE10} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf
+cp -p %{SOURCE10} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf
 
-install %{SOURCE11} $RPM_BUILD_ROOT%{systemdunitdir}
+cp -p %{SOURCE11} $RPM_BUILD_ROOT%{systemdunitdir}
 
 # NOTE: clamd uses sane rights to it's clamd.pid file
 # So better keep it dir
@@ -310,6 +318,7 @@ fi
 %attr(755,root,root) %{_bindir}/clamdscan
 %attr(755,root,root) %{_bindir}/clamdtop
 %attr(755,root,root) %{_bindir}/clamscan
+%attr(755,root,root) %{_bindir}/clamsubmit
 %attr(755,root,root) %{_bindir}/freshclam
 %attr(755,root,root) %{_bindir}/sigtool
 %attr(755,root,root) %{_bindir}/clamconf
@@ -348,19 +357,27 @@ fi
 
 %files libs
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so.*.*
+%attr(755,root,root) %{_libdir}/libclamav.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libclamav.so.6
+%attr(755,root,root) %{_libdir}/libclamunrar.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libclamunrar.so.6
+%attr(755,root,root) %{_libdir}/libclamunrar_iface.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libclamunrar_iface.so.6
 
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/clamav-config
-%attr(755,root,root) %{_libdir}/lib*.so
-%{_libdir}/lib*.la
-%{_includedir}/*.h
-%{_pkgconfigdir}/*.pc
+%attr(755,root,root) %{_libdir}/libclamav.so
+%attr(755,root,root) %{_libdir}/libclamunrar.so
+%attr(755,root,root) %{_libdir}/libclamunrar_iface.so
+%{_libdir}/libclamav.la
+%{_libdir}/libclamunrar.la
+%{_libdir}/libclamunrar_iface.la
+%{_includedir}/clamav.h
+%{_pkgconfigdir}/libclamav.pc
 
 %files static
 %defattr(644,root,root,755)
-%{_libdir}/*.a
+%{_libdir}/libclamav.a
+%{_libdir}/libclamunrar.a
+%{_libdir}/libclamunrar_iface.a