hwaccel -> ncore

git-svn: trunk@2381
remotes/push_mirror/metadata
Tomasz Kojm 19 years ago
parent 525f4b8414
commit b5456d6455
  1. 5
      clamav-devel/ChangeLog
  2. 2
      clamav-devel/clamd/clamd.c
  3. 12
      clamav-devel/clamdscan/client.c
  4. 8
      clamav-devel/clamscan/clamscan.c
  5. 4
      clamav-devel/clamscan/clamscan_opt.h
  6. 4
      clamav-devel/clamscan/manager.c
  7. 145
      clamav-devel/configure
  8. 10
      clamav-devel/configure.in
  9. 2
      clamav-devel/docs/man/clamd.conf.5.in
  10. 2
      clamav-devel/etc/clamd.conf
  11. 4
      clamav-devel/libclamav/clamav.h
  12. 4
      clamav-devel/libclamav/filetypes.c
  13. 18
      clamav-devel/libclamav/matcher.c
  14. 30
      clamav-devel/libclamav/readdb.c
  15. 2
      clamav-devel/shared/cfgparser.c

@ -1,3 +1,8 @@
Sun Oct 15 02:20:25 CEST 2006 (tk)
----------------------------------
* clamd: s/HardwareAcceleration/NodalCoreAcceleration
* clamscan: s/--hwaccel/--ncore
Sun Oct 15 01:56:34 CEST 2006 (tk)
----------------------------------
* clamd: s/PhishingScanAllDomains/PhishingStrictURLCheck

@ -313,7 +313,7 @@ int main(int argc, char **argv)
logg("Not loading phishing signatures.\n");
}
if(cfgopt(copt, "HardwareAcceleration")->enabled) {
if(cfgopt(copt, "NodalCoreAcceleration")->enabled) {
#ifdef HAVE_HWACCEL
dboptions |= CL_DB_HWACCEL;
logg("Enabling support for hardware acceleration.\n");

@ -58,7 +58,7 @@
void move_infected(const char *filename, const struct optstruct *opt);
int notremoved = 0, notmoved = 0;
static int hwaccel = 0;
static int ncore = 0;
static int dsresult(int sockd, const struct optstruct *opt)
{
@ -391,9 +391,9 @@ static int dconnect(const struct optstruct *opt)
return -1;
}
#ifdef HAVE_HWACCEL
if(cfgopt(copt, "HardwareAcceleration")->enabled)
hwaccel = 1;
#ifdef HAVE_NCORE
if(cfgopt(copt, "NodalCoreAcceleration")->enabled)
ncore = 1;
#endif
freecfg(copt);
@ -425,7 +425,7 @@ int client(const struct optstruct *opt, int *infected)
/* TODO: add a cmdline option to allow using MULTISCAN on systems
* without hardware accelerators (but with multiple CPUs)
*/
if(hwaccel)
if(ncore)
scantype = "MULTISCAN";
if((ret = dsfile(sockd, scantype, cwd, opt)) >= 0)
@ -486,7 +486,7 @@ int client(const struct optstruct *opt, int *infected)
if((sockd = dconnect(opt)) < 0)
return 2;
if(hwaccel)
if(ncore)
scantype = "MULTISCAN";
if((ret = dsfile(sockd, scantype, fullpath, opt)) >= 0)

@ -185,8 +185,8 @@ int main(int argc, char **argv)
dms += (dms < 0) ? (1000000):(0);
logg("\n----------- SCAN SUMMARY -----------\n");
logg("Known viruses: %d\n", claminfo.signs);
if(opt_check(opt, "hwaccel"))
logg("Engine version: %s [hwaccel]\n", cl_retver());
if(opt_check(opt, "ncore"))
logg("Engine version: %s [ncore]\n", cl_retver());
else
logg("Engine version: %s\n", cl_retver());
logg("Scanned directories: %d\n", claminfo.dirs);
@ -246,8 +246,8 @@ void help(void)
mprintf(" --include=PATT Only scan file names containing PATT\n");
mprintf(" --include-dir=PATT Only scan directories containing PATT\n");
#endif
#ifdef HAVE_HWACCEL
mprintf("\n --hwaccel Use hardware acceleration\n");
#ifdef HAVE_NCORE
mprintf("\n --ncore Use hardware acceleration\n");
#endif
mprintf("\n");
mprintf(" --no-mail Disable mail file support\n");

@ -61,8 +61,8 @@ static struct option clamscan_longopt[] = {
{"max-ratio", 1, 0, 0},
{"max-recursion", 1, 0, 0},
{"max-dir-recursion", 1, 0, 0},
#ifdef HAVE_HWACCEL
{"hwaccel", 0, 0, 0},
#ifdef HAVE_NCORE
{"ncore", 0, 0, 0},
#endif
{"disable-archive", 0, 0, 0},
{"no-archive", 0, 0, 0},

@ -86,8 +86,8 @@ int scanmanager(const struct optstruct *opt)
compression = 1;
if(opt_check(opt, "hwaccel"))
dboptions |= CL_DB_HWACCEL;
if(opt_check(opt, "ncore"))
dboptions |= CL_DB_NCORE;
if(opt_check(opt, "no-phishing"))
dboptions |= CL_DB_NOPHISHING;

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.60.
# Generated by GNU Autoconf 2.60a.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
@ -724,36 +724,36 @@ ac_unique_file="clamscan/clamscan.c"
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
#if HAVE_SYS_TYPES_H
#ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
#if HAVE_SYS_STAT_H
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
#if STDC_HEADERS
#ifdef STDC_HEADERS
# include <stdlib.h>
# include <stddef.h>
#else
# if HAVE_STDLIB_H
# ifdef HAVE_STDLIB_H
# include <stdlib.h>
# endif
#endif
#if HAVE_STRING_H
# if !STDC_HEADERS && HAVE_MEMORY_H
#ifdef HAVE_STRING_H
# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
# include <memory.h>
# endif
# include <string.h>
#endif
#if HAVE_STRINGS_H
#ifdef HAVE_STRINGS_H
# include <strings.h>
#endif
#if HAVE_INTTYPES_H
#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
#endif
#if HAVE_STDINT_H
#ifdef HAVE_STDINT_H
# include <stdint.h>
#endif
#if HAVE_UNISTD_H
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif"
@ -1469,7 +1469,7 @@ Optional Features:
(and sometimes confusing) to the casual installer
--disable-zlib-vcheck do not check for buggy zlib version
--disable-bzip2 disable bzip2 support
--disable-hwaccel disable support for hardware acceleration
--disable-ncore disable support for NodalCore acceleration (default=auto)
--disable-dns disable support for database verification through
DNS
--disable-clamuko disable clamuko support (Linux, DragonFly and FreeBSD only)
@ -1577,7 +1577,7 @@ test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
configure
generated by GNU Autoconf 2.60
generated by GNU Autoconf 2.60a
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
@ -1591,7 +1591,7 @@ This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by $as_me, which was
generated by GNU Autoconf 2.60. Invocation command line was
generated by GNU Autoconf 2.60a. Invocation command line was
$ $0 $@
@ -3165,7 +3165,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
# in a Makefile. We should not override ac_cv_exeext if it was cached,
# so that the user can short-circuit this test for compilers unknown to
# Autoconf.
for ac_file in $ac_files
for ac_file in $ac_files ''
do
test -f "$ac_file" || continue
case $ac_file in
@ -3193,6 +3193,12 @@ done
test "$ac_cv_exeext" = no && ac_cv_exeext=
else
ac_file=''
fi
{ echo "$as_me:$LINENO: result: $ac_file" >&5
echo "${ECHO_T}$ac_file" >&6; }
if test -z "$ac_file"; then
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@ -3204,8 +3210,6 @@ See \`config.log' for more details." >&2;}
fi
ac_exeext=$ac_cv_exeext
{ echo "$as_me:$LINENO: result: $ac_file" >&5
echo "${ECHO_T}$ac_file" >&6; }
# Check that the compiler produces executables we can run. If not, either
# the compiler is broken, or we cross compile.
@ -5883,7 +5887,7 @@ test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
case $host in
*-*-irix6*)
# Find out which ABI we are using.
echo '#line 5886 "configure"' > conftest.$ac_ext
echo '#line 5890 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@ -5995,7 +5999,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
lt_cv_cc_needs_belf=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
@ -6471,7 +6475,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LDFLAGS="$save_LDFLAGS"
@ -6516,7 +6520,7 @@ chmod -w .
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
compiler_c_o=no
if { (eval echo configure:6519: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
if { (eval echo configure:6523: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings
if test -s out/conftest.err; then
@ -8077,7 +8081,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_func_shl_load=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
{ echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
@ -8156,7 +8160,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_dld_shl_load=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -8257,7 +8261,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_func_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
{ echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
@ -8336,7 +8340,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_dl_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -8416,7 +8420,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_svld_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -8496,7 +8500,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_dld_dld_link=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -8552,7 +8556,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
#line 8555 "configure"
#line 8559 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@ -8650,7 +8654,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
#line 8653 "configure"
#line 8657 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@ -10424,7 +10428,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_socket_bind=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -10505,7 +10509,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_nsl_gethostent=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -10623,7 +10627,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval echo '${'$as_ac_var'}'`
@ -10898,7 +10902,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval echo '${'$as_ac_var'}'`
@ -10955,21 +10959,21 @@ $ac_includes_default
#include <fcntl.h>
#include <sys/mman.h>
#if !STDC_HEADERS && !HAVE_STDLIB_H
#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
char *malloc ();
#endif
/* This mess was copied from the GNU getpagesize.h. */
#if !HAVE_GETPAGESIZE
#ifndef HAVE_GETPAGESIZE
/* Assume that all systems that can run configure have sys/param.h. */
# if !HAVE_SYS_PARAM_H
# ifndef HAVE_SYS_PARAM_H
# define HAVE_SYS_PARAM_H 1
# endif
# ifdef _SC_PAGESIZE
# define getpagesize() sysconf(_SC_PAGESIZE)
# else /* no _SC_PAGESIZE */
# if HAVE_SYS_PARAM_H
# ifdef HAVE_SYS_PARAM_H
# include <sys/param.h>
# ifdef EXEC_PAGESIZE
# define getpagesize() EXEC_PAGESIZE
@ -11301,7 +11305,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_func_fseeko=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
{ echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
@ -11697,7 +11701,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_z_inflateEnd=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -11787,7 +11791,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_z_inflateEnd=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -11889,7 +11893,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_bz2_bzReadOpen=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -12066,15 +12070,15 @@ fi
fi
# Check whether --enable-hwaccel was given.
if test "${enable_hwaccel+set}" = set; then
enableval=$enable_hwaccel; want_hwaccel=$enableval
# Check whether --enable-ncore was given.
if test "${enable_ncore+set}" = set; then
enableval=$enable_ncore; want_ncore=$enableval
else
want_hwaccel="yes"
want_ncore="yes"
fi
if test "$want_hwaccel" = "yes"
if test "$want_ncore" = "yes"
then
{ echo "$as_me:$LINENO: checking for sn_sigscan_initdb in -lsn_sigscan" >&5
echo $ECHO_N "checking for sn_sigscan_initdb in -lsn_sigscan... $ECHO_C" >&6; }
@ -12147,7 +12151,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_sn_sigscan_sn_sigscan_initdb=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -12311,7 +12315,7 @@ fi
if test $ac_cv_header_sn_sigscan_sn_sigscan_h = yes; then
LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lsn_sigscan";
cat >>confdefs.h <<\_ACEOF
#define HAVE_HWACCEL 1
#define HAVE_NCORE 1
_ACEOF
else
@ -12403,7 +12407,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_resolv___dn_expand=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -12485,7 +12489,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_resolv_dn_expand=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -12916,7 +12920,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_gmp___gmpz_init=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -13000,7 +13004,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_gmp_mpz_init=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -13923,7 +13927,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_milter_mi_stop=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -14010,7 +14014,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext
if test "${ac_cv_search_strlcpy+set}" = set; then
break
@ -14105,7 +14109,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_milter_mi_stop=no
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
@ -14424,7 +14428,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval echo '${'$as_ac_var'}'`
@ -14915,11 +14919,11 @@ echo "${ECHO_T}no" >&6; }
LIBS=$save_LIBS
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
rm -f core conftest.err conftest.$ac_objext \
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
else
have_wrappers=no
@ -15734,10 +15738,10 @@ main ()
#ifndef __cplusplus
/* Ultrix mips cc rejects this. */
typedef int charset[2];
const charset x;
const charset cs;
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
char **p;
char const *const *pcpcc;
char **ppc;
/* NEC SVR4.0.2 mips cc rejects this. */
struct point {int x, y;};
static struct point const zero = {0,0};
@ -15746,11 +15750,11 @@ main ()
an arm of an if-expression whose if-part is not a constant
expression */
const char *g = "string";
ccp = &g + (g ? g-g : 0);
pcpcc = &g + (g ? g-g : 0);
/* HPUX 7.0 cc rejects these. */
++ccp;
p = (char**) ccp;
ccp = (char const *const *) p;
++pcpcc;
ppc = (char**) pcpcc;
pcpcc = (char const *const *) ppc;
{ /* SCO 3.2v4 cc rejects this. */
char *t;
char const *s = 0 ? (char *) 0 : (char const *) 0;
@ -15777,7 +15781,7 @@ main ()
const int foo = 10;
if (!foo) return 0;
}
return !x[0] && !zero.x;
return !cs[0] && !zero.x;
#endif
;
@ -15942,7 +15946,8 @@ cat >>conftest.$ac_ext <<_ACEOF
int
main ()
{
#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
#if ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
&& BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
bogus endian macros
#endif
@ -17040,7 +17045,7 @@ exec 6>&1
# values after options handling.
ac_log="
This file was extended by $as_me, which was
generated by GNU Autoconf 2.60. Invocation command line was
generated by GNU Autoconf 2.60a. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@ -17069,7 +17074,7 @@ current configuration.
Usage: $0 [OPTIONS] [FILE]...
-h, --help print this help, then exit
-V, --version print version number, then exit
-V, --version print version number and configuration settings, then exit
-q, --quiet do not print progress messages
-d, --debug don't remove temporary files
--recheck update $as_me by reconfiguring in the same conditions
@ -17093,7 +17098,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF
ac_cs_version="\\
config.status
configured by $0, generated by GNU Autoconf 2.60,
configured by $0, generated by GNU Autoconf 2.60a,
with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
Copyright (C) 2006 Free Software Foundation, Inc.

@ -139,16 +139,16 @@ then
AC_CHECK_HEADER(bzlib.h,[LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lbz2"; AC_DEFINE(HAVE_BZLIB_H,1,have bzip2)], AC_MSG_WARN([****** bzip2 support disabled]))
fi
AC_ARG_ENABLE(hwaccel,
[ --disable-hwaccel disable support for hardware acceleration],
want_hwaccel=$enableval, want_hwaccel="yes")
AC_ARG_ENABLE(ncore,
[ --disable-ncore disable support for NodalCore acceleration (default=auto)],
want_ncore=$enableval, want_ncore="yes")
if test "$want_hwaccel" = "yes"
if test "$want_ncore" = "yes"
then
AC_CHECK_LIB(sn_sigscan, sn_sigscan_initdb, have_sigscan=yes,)
if test "$have_sigscan" = "yes"
then
AC_CHECK_HEADER(sn_sigscan/sn_sigscan.h,[LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lsn_sigscan"; AC_DEFINE(HAVE_HWACCEL,1,hardware acceleration)], AC_MSG_WARN([****** hardware acceleration support disabled -- please install libsigscan-devel ]))
AC_CHECK_HEADER(sn_sigscan/sn_sigscan.h,[LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lsn_sigscan"; AC_DEFINE(HAVE_NCORE,1,hardware acceleration)], AC_MSG_WARN([****** hardware acceleration support disabled -- please install libsigscan-devel ]))
fi
fi

@ -287,7 +287,7 @@ Mark archives as viruses (e.g RAR.ExceededFileSize, Zip.ExceededFilesLimit) if A
.br
Default: disabled
.TP
\fBHardwareAcceleration\fR
\fBNodalCoreAcceleration\fR
Enable support for Sensory Networks' NodalCore hardware accelerator.
.br
Default: disabled

@ -283,7 +283,7 @@ LocalSocket /tmp/clamd
# Enable support for Sensory Networks' NodalCore hardware accelerator.
# Default: no
#HardwareAcceleration yes
#NodalCoreAcceleration yes
##

@ -71,7 +71,7 @@ extern "C"
/* db options */
#define CL_DB_HWACCEL 1
#define CL_DB_NCORE 1
#define CL_DB_NOPHISHING 2
#define CL_DB_ACONLY 4 /* for developers only */
@ -160,7 +160,7 @@ struct cli_matcher {
struct cl_engine {
unsigned int refcount; /* reference counter */
unsigned short hwaccel;
unsigned short ncore;
unsigned short sdb;
/* Roots table */

@ -294,9 +294,9 @@ int cli_addtypesigs(struct cl_engine *engine)
return CL_EMEM;
}
if(engine->hwaccel) {
if(engine->ncore) {
/*
cli_dbgmsg("cli_addtypesigs: AC depth 10 (hwaccel mode)\n");
cli_dbgmsg("cli_addtypesigs: AC depth 10 (ncore mode)\n");
cli_ac_setdepth(10);
*/
}

@ -46,7 +46,7 @@ static int targettab[CL_TARGET_TABLE_SIZE] = { 0, CL_TYPE_MSEXE, CL_TYPE_MSOLE2,
extern short cli_debug_flag;
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
#include <sn_sigscan/sn_sigscan.h>
#define HWBUFFSIZE 32768
#endif
@ -57,7 +57,7 @@ int cli_scanbuff(const char *buffer, unsigned int length, const char **virname,
int ret = CL_CLEAN, i, tid = 0, *partcnt;
unsigned long int *partoff;
struct cli_matcher *groot, *troot = NULL;
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
void *streamhandle;
void *resulthandle;
uint32_t datamask[2] = { 0xffffffff, 0xffffffff };
@ -72,8 +72,8 @@ int cli_scanbuff(const char *buffer, unsigned int length, const char **virname,
return CL_ENULLARG;
}
#ifdef HAVE_HWACCEL
if(engine->hwaccel) {
#ifdef HAVE_NCORE
if(engine->ncore) {
/* TODO: Setup proper data bitmask (need specs) */
if((hret = sn_sigscan_createstream(engine->hwdb, datamask, 2, &streamhandle)) < 0) {
cli_errmsg("cli_scanbuff: can't create new hardware stream: %d\n", hret);
@ -191,7 +191,7 @@ int cli_scanbuff(const char *buffer, unsigned int length, const char **virname,
return ret;
}
#endif /* HAVE_HWACCEL */
#endif /* HAVE_NCORE */
groot = engine->root[0]; /* generic signatures */
@ -416,7 +416,7 @@ int cli_scandesc(int desc, cli_ctx *ctx, unsigned short otfrec, unsigned short f
unsigned char digest[16];
struct cli_md5_node *md5_node;
struct cli_matcher *groot, *troot = NULL;
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
void *streamhandle;
void *resulthandle;
unsigned long long hoffset;
@ -431,8 +431,8 @@ int cli_scandesc(int desc, cli_ctx *ctx, unsigned short otfrec, unsigned short f
return CL_ENULLARG;
}
#ifdef HAVE_HWACCEL
if(ctx->engine->hwaccel) {
#ifdef HAVE_NCORE
if(ctx->engine->ncore) {
/* TODO: Setup proper data bitmask (need specs) */
if((hret = sn_sigscan_createstream(ctx->engine->hwdb, datamask, 2, &streamhandle)) < 0) {
cli_errmsg("cli_scandesc: can't create new hardware stream: %d\n", hret);
@ -621,7 +621,7 @@ int cli_scandesc(int desc, cli_ctx *ctx, unsigned short otfrec, unsigned short f
return CL_EIO;
}
}
#endif /* HAVE_HWACCEL */
#endif /* HAVE_NCORE */
groot = ctx->engine->root[0]; /* generic signatures */

@ -78,7 +78,7 @@
static pthread_mutex_t cli_ref_mutex = PTHREAD_MUTEX_INITIALIZER;
#endif
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
#include <sn_sigscan/sn_sigscan.h>
#endif
@ -1090,7 +1090,7 @@ static int cli_loadmd(FILE *fd, struct cl_engine **engine, unsigned int *signo,
return CL_SUCCESS;
}
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
static int cli_loadhw(const char *filename, struct cl_engine **engine, unsigned int *signo, unsigned int options)
{
int ret = 0;
@ -1102,22 +1102,22 @@ static int cli_loadhw(const char *filename, struct cl_engine **engine, unsigned
}
if((ret = sn_sigscan_initdb(&(*engine)->hwdb)) < 0) {
cli_errmsg("hwaccel: error initializing the matcher: %d\n", ret);
cli_errmsg("ncore: error initializing the matcher: %d\n", ret);
cl_free(*engine);
return CL_EHWINIT;
}
(*engine)->hwaccel = 1;
(*engine)->ncore = 1;
if((ret = sn_sigscan_loaddb((*engine)->hwdb, filename, 0, signo)) < 0) {
cli_errmsg("hwaccel: can't load hardware database: %d\n", ret);
cli_errmsg("ncore: can't load hardware database: %d\n", ret);
cl_free(*engine);
return CL_EHWLOAD;
}
return CL_SUCCESS;
}
#endif /* HAVE_HWACCEL */
#endif /* HAVE_NCORE */
static int cli_loaddbdir(const char *dirname, struct cl_engine **engine, unsigned int *signo, unsigned int options);
@ -1137,7 +1137,7 @@ static int cli_load(const char *filename, struct cl_engine **engine, unsigned in
}
if(cli_strbcasestr(filename, ".db")) {
if(options & CL_DB_HWACCEL)
if(options & CL_DB_NCORE)
skipped = 1;
else
ret = cli_loaddb(fd, engine, signo, options);
@ -1160,14 +1160,14 @@ static int cli_load(const char *filename, struct cl_engine **engine, unsigned in
ret = cli_loadhdb(fd, engine, signo, 2, options);
} else if(cli_strbcasestr(filename, ".ndb")) {
if(options & CL_DB_HWACCEL)
if(options & CL_DB_NCORE)
skipped = 1;
else
ret = cli_loadndb(fd, engine, signo, 0, options);
} else if(cli_strbcasestr(filename, ".sdb")) {
/* FIXME: Add support in hwaccel mode */
if(options & CL_DB_HWACCEL)
/* FIXME: Add support in ncore mode */
if(options & CL_DB_NCORE)
skipped = 1;
else
ret = cli_loadndb(fd, engine, signo, 1, options);
@ -1179,8 +1179,8 @@ static int cli_load(const char *filename, struct cl_engine **engine, unsigned in
ret = cli_loadmd(fd, engine, signo, 2, options);
} else if(cli_strbcasestr(filename, ".hw")) {
#ifdef HAVE_HWACCEL
if(options & CL_DB_HWACCEL)
#ifdef HAVE_NCORE
if(options & CL_DB_NCORE)
ret = cli_loadhw(filename, engine, signo, options);
else
#endif
@ -1538,7 +1538,7 @@ void cl_free(struct cl_engine *engine)
struct cli_md5_node *md5pt, *md5h;
struct cli_meta_node *metapt, *metah;
struct cli_matcher *root;
#ifdef HAVE_HWACCEL
#ifdef HAVE_NCORE
int ret;
#endif
@ -1564,8 +1564,8 @@ void cl_free(struct cl_engine *engine)
pthread_mutex_unlock(&cli_ref_mutex);
#endif
#ifdef HAVE_HWACCEL
if(engine->hwaccel) {
#ifdef HAVE_NCORE
if(engine->ncore) {
if((ret = sn_sigscan_closedb(engine->hwdb)) < 0) {
cli_errmsg("cl_free: can't close hardware database: %d\n", ret);
}

@ -86,7 +86,7 @@ struct cfgoption cfg_options[] = {
{"AllowSupplementaryGroups", OPT_BOOL, 0, NULL, 0, OPT_CLAMD | OPT_FRESHCLAM},
{"SelfCheck", OPT_NUM, 1800, NULL, 0, OPT_CLAMD},
{"VirusEvent", OPT_FULLSTR, -1, NULL, 0, OPT_CLAMD},
{"HardwareAcceleration", OPT_BOOL, 0, NULL, 0, OPT_CLAMD},
{"NodalCoreAcceleration", OPT_BOOL, 0, NULL, 0, OPT_CLAMD},
{"ClamukoScanOnAccess", OPT_BOOL, 0, NULL, 0, OPT_CLAMD},
{"ClamukoScanOnOpen", OPT_BOOL, 0, NULL, 0, OPT_CLAMD},
{"ClamukoScanOnClose", OPT_BOOL, 0, NULL, 0, OPT_CLAMD},

Loading…
Cancel
Save