On Fri, Feb 20, 2009 at 12:12:11AM +0000, Stephen Gran said:
> Hopefully this will be a useful patch.

And if you add this one, it even compiles with the bundled tommath.
sorry about that - autotools after midnight is never a good idea.

 [PATCH] and fix up my various errors
 Signed-off-by: Stephen Gran <st...@lobefin.net>

---
 configure.in          |    4 ++--
 libclamav/Makefile.am |    9 +++------
 2 files changed, 5 insertions(+), 8 deletions(-)

diff --git a/configure.in b/configure.in
index e400644..3a22ff9 100644
--- a/configure.in
+++ b/configure.in
@@ -511,12 +511,12 @@ if test "x$enable_system_tommath" = "xauto"; then
     AC_CHECK_HEADER([tommath.h],[have_tommath_h=yes],)
 fi
 
-if test "x$have_tommath_h" = "xyes" || "x$enable_system_tommath" = "xyes"; then
+if test "x$have_tommath_h" = "xyes" || test "x$enable_system_tommath" = 
"xyes"; then
     AC_DEFINE([USE_SYSTEM_TOMMATH], 1, [use system lintommath])
     TOMMATH_LIBS="-ltommath"
     AC_SUBST([TOMMATH_LIBS])
 fi
-AM_CONDITIONAL([SYSTEM_TOMMATH], test "x$ac_cv_use_system_tommath" = "xyes")
+AM_CONDITIONAL([SYSTEM_TOMMATH], [test "x$ac_cv_use_system_tommath" = "xyes"])
 
 AC_ARG_ENABLE([zlib-vcheck],
 [  --disable-zlib-vcheck         do not check for buggy zlib version ],
diff --git a/libclamav/Makefile.am b/libclamav/Makefile.am
index 931c852..73d836a 100644
--- a/libclamav/Makefile.am
+++ b/libclamav/Makefile.am
@@ -89,23 +89,20 @@ libclamav_internal_utils_la_SOURCES=str.c \
                                    regex/regex2.h \
                                    regex/utils.h
 
-if SYSTEM_TOMMATH
-else
+lib_LTLIBRARIES += libclamavtommath.la
 libclamavtommath_la_SOURCES = \
                          bignum.c \
                          bignum.h \
                          bignum_class.h
 
-lib_LTLIBRARIES += libclamavtommath.la
 libclamavtommath_la_LDFLAGS =-static
 libclamavtommath_la_CFLAGS=  -fPIC -DPIC
-endif
 
 libclamav_internal_utils_la_LDFLAGS=-static
 libclamav_internal_utils_la_CFLAGS=  -fPIC -DPIC
 
-libclamav_la_LIBADD = @LIBLTDL@ $(IFACELIBADD) lzma/liblzma.la 
libclamav_internal_utils.la @LIBCLAMAV_LIBS@ @THREAD_LIBS@ @TOMMATH_LIBS@
-libclamav_la_DEPENDENCIES =  @LIBLTDL@ $(IFACEDEP) libclamav_internal_utils.la
+libclamav_la_LIBADD = @LIBLTDL@ $(IFACELIBADD) lzma/liblzma.la 
libclamavtommath.la libclamav_internal_utils.la @LIBCLAMAV_LIBS@ @THREAD_LIBS@ 
@TOMMATH_LIBS@
+libclamav_la_DEPENDENCIES =  @LIBLTDL@ $(IFACEDEP) libclamav_internal_utils.la 
libclamavtommath.la
 libclamav_la_LDFLAGS = @TH_SAFE@ -version-info @LIBCLAMAV_VERSION@ 
-no-undefined
 
 if VERSIONSCRIPT
-- 
1.6.0.6

-- 
 --------------------------------------------------------------------------
|  Stephen Gran                  | Beer -- it's not just for breakfast     |
|  st...@lobefin.net             | anymore.                                |
|  http://www.lobefin.net/~steve |                                         |
 --------------------------------------------------------------------------

Attachment: signature.asc
Description: Digital signature

_______________________________________________
http://lurker.clamav.net/list/clamav-devel.html
Please submit your patches to our Bugzilla: http://bugs.clamav.net

Reply via email to