diff --git a/clamav-devel/ChangeLog b/clamav-devel/ChangeLog index d83e0070d..6e67bb353 100644 --- a/clamav-devel/ChangeLog +++ b/clamav-devel/ChangeLog @@ -1,3 +1,7 @@ +Fri Jul 23 00:40:18 CEST 2004 (tk) +---------------------------------- + * configure: yet another Solaris 9 fix + Thu Jul 22 21:23:57 CEST 2004 (tk) ---------------------------------- * docs: update diff --git a/clamav-devel/clamav-config b/clamav-devel/clamav-config index b5cb8ad27..d1def3cf5 100755 --- a/clamav-devel/clamav-config +++ b/clamav-devel/clamav-config @@ -46,7 +46,7 @@ while test $# -gt 0; do ;; --version) - echo devel-20040721 + echo devel-20040723 exit 0 ;; diff --git a/clamav-devel/configure b/clamav-devel/configure index ae1d29c00..a36df07a7 100755 --- a/clamav-devel/configure +++ b/clamav-devel/configure @@ -10877,6 +10877,141 @@ fi rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi +echo "$as_me:$LINENO: checking for bind in -lsocket" >&5 +echo $ECHO_N "checking for bind in -lsocket... $ECHO_C" >&6 +if test "${ac_cv_lib_socket_bind+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsocket $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char bind (); +int +main () +{ +bind (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_socket_bind=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_lib_socket_bind=no +fi +rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_socket_bind" >&5 +echo "${ECHO_T}$ac_cv_lib_socket_bind" >&6 +if test $ac_cv_lib_socket_bind = yes; then + LIBS="$LIBS -lsocket"; CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket"; LDFLAGS="$LDFLAGS -lsocket"; FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lsocket"; CLAMD_LIBS="$CLAMD_LIBS -lsocket" +fi + +echo "$as_me:$LINENO: checking for gethostent in -lnsl" >&5 +echo $ECHO_N "checking for gethostent in -lnsl... $ECHO_C" >&6 +if test "${ac_cv_lib_nsl_gethostent+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lnsl $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any gcc2 internal prototype to avoid an error. */ +#ifdef __cplusplus +extern "C" +#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gethostent (); +int +main () +{ +gethostent (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && + { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + ac_cv_lib_nsl_gethostent=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +ac_cv_lib_nsl_gethostent=no +fi +rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostent" >&5 +echo "${ECHO_T}$ac_cv_lib_nsl_gethostent" >&6 +if test $ac_cv_lib_nsl_gethostent = yes; then + LIBS="$LIBS -lnsl"; CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lnsl"; LDFLAGS="$LDFLAGS -lnsl"; FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lnsl"; CLAMD_LIBS="$CLAMD_LIBS -lnsl" +fi + + case "$target_os" in linux*) @@ -10897,7 +11032,7 @@ cat >>confdefs.h <<\_ACEOF #define _REENTRANT 1 _ACEOF - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" if test "$want_clamuko" = "yes"; then @@ -10906,7 +11041,7 @@ cat >>confdefs.h <<\_ACEOF _ACEOF fi - CLAMSCAN_LIBS="-lpthread" + CLAMSCAN_LIBS="$CLAMSCAN_LIBS -lpthread" fi ;; cygwin*) @@ -10936,11 +11071,11 @@ _ACEOF fi ;; solaris*) - FRESHCLAM_LIBS="-lsocket -lnsl -lresolv" + FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lresolv" if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread -lsocket -lnsl -lresolv" - CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread -lsocket -lnsl -lresolv" + CLAMD_LIBS="$CLAMD_LIBS -lpthread -lresolv" + CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread -lresolv" TH_SAFE="-thread-safe" cat >>confdefs.h <<\_ACEOF @@ -10962,7 +11097,7 @@ _ACEOF freebsd*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread -lc_r" - CLAMD_LIBS="-pthread -lc_r" + CLAMD_LIBS="$CLAMD_LIBS -pthread -lc_r" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread -lc_r" TH_SAFE="-thread-safe" @@ -10993,7 +11128,7 @@ openbsd3.3*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread" if test "$disable_cr" = "yes"; then - CLAMD_LIBS="-pthread" + CLAMD_LIBS="$CLAMD_LIBS -pthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread" fi TH_SAFE="-thread-safe" @@ -11018,10 +11153,10 @@ openbsd*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread" if test "$disable_cr" = "yes"; then - CLAMD_LIBS="-pthread" + CLAMD_LIBS="$CLAMD_LIBS -pthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread" else - CLAMD_LIBS="-pthread -lc_r" + CLAMD_LIBS="$CLAMD_LIBS -pthread -lc_r" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread -lc_r" fi TH_SAFE="-thread-safe" @@ -11099,14 +11234,11 @@ _ACEOF use_netinfo="yes" ;; sco*) - FRESHCLAM_LIBS="-lsocket" - CLAMD_LIBS="-lsocket" - CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket" - ;; + ;; hpux*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" @@ -11129,7 +11261,7 @@ _ACEOF aix*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" @@ -11152,7 +11284,7 @@ _ACEOF irix*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" diff --git a/clamav-devel/configure.in b/clamav-devel/configure.in index a453061eb..7405506f1 100644 --- a/clamav-devel/configure.in +++ b/clamav-devel/configure.in @@ -203,6 +203,9 @@ AC_TRY_RUN([ int main(int argc, char **argv) { in_port_t pt; pt = 0; return pt; } ], AC_DEFINE(HAVE_IN_PORT_T,1,[in_port_t is defined]), AC_MSG_RESULT(in_port_t is not defined)) +AC_CHECK_LIB(socket, bind, [LIBS="$LIBS -lsocket"; CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket"; LDFLAGS="$LDFLAGS -lsocket"; FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lsocket"; CLAMD_LIBS="$CLAMD_LIBS -lsocket"]) +AC_CHECK_LIB(nsl, gethostent, [LIBS="$LIBS -lnsl"; CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lnsl"; LDFLAGS="$LDFLAGS -lnsl"; FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lnsl"; CLAMD_LIBS="$CLAMD_LIBS -lnsl"]) + case "$target_os" in linux*) AC_DEFINE(C_LINUX,1,[target is linux]) @@ -211,12 +214,12 @@ linux*) TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe]) AC_DEFINE(_REENTRANT,1,[thread safe]) - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" if test "$want_clamuko" = "yes"; then AC_DEFINE(CLAMUKO,1,[enable clamuko]) fi - CLAMSCAN_LIBS="-lpthread" + CLAMSCAN_LIBS="$CLAMSCAN_LIBS -lpthread" fi ;; cygwin*) @@ -234,11 +237,11 @@ cygwin*) fi ;; solaris*) - FRESHCLAM_LIBS="-lsocket -lnsl -lresolv" + FRESHCLAM_LIBS="$FRESHCLAM_LIBS -lresolv" if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread -lsocket -lnsl -lresolv" - CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread -lsocket -lnsl -lresolv" + CLAMD_LIBS="$CLAMD_LIBS -lpthread -lresolv" + CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread -lresolv" TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe]) AC_DEFINE(_REENTRANT,1,[thread safe]) @@ -248,7 +251,7 @@ solaris*) freebsd*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread -lc_r" - CLAMD_LIBS="-pthread -lc_r" + CLAMD_LIBS="$CLAMD_LIBS -pthread -lc_r" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread -lc_r" TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe]) @@ -263,7 +266,7 @@ openbsd3.3*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread" if test "$disable_cr" = "yes"; then - CLAMD_LIBS="-pthread" + CLAMD_LIBS="$CLAMD_LIBS -pthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread" fi TH_SAFE="-thread-safe" @@ -276,10 +279,10 @@ openbsd*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -pthread" if test "$disable_cr" = "yes"; then - CLAMD_LIBS="-pthread" + CLAMD_LIBS="$CLAMD_LIBS -pthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread" else - CLAMD_LIBS="-pthread -lc_r" + CLAMD_LIBS="$CLAMD_LIBS -pthread -lc_r" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -pthread -lc_r" fi TH_SAFE="-thread-safe" @@ -316,14 +319,14 @@ darwin*) ;; sco*) dnl njh@bandsman.sco.uk: SCO Unix port - FRESHCLAM_LIBS="-lsocket" - CLAMD_LIBS="-lsocket" - CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket" + dnl FRESHCLAM_LIBS="-lsocket" + dnl CLAMD_LIBS="-lsocket" + dnl CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lsocket" ;; hpux*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe]) @@ -334,7 +337,7 @@ hpux*) aix*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe]) @@ -345,7 +348,7 @@ aix*) irix*) if test "$have_pthreads" = "yes"; then LIBCLAMAV_LIBS="$LIBCLAMAV_LIBS -lpthread" - CLAMD_LIBS="-lpthread" + CLAMD_LIBS="$CLAMD_LIBS -lpthread" CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" TH_SAFE="-thread-safe" AC_DEFINE(CL_THREAD_SAFE,1,[thread safe])