From: Russell Bryant Date: Thu, 27 Apr 2006 00:10:56 +0000 (+0000) Subject: only define HAVE_SOMELIB if somelib's header file was found as well X-Git-Tag: 1.4.0-beta1~1783 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=74aecc640bfec0d02e7246dfebf775d6fedc5999;p=thirdparty%2Fasterisk.git only define HAVE_SOMELIB if somelib's header file was found as well git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@22703 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/acinclude.m4 b/acinclude.m4 index b038d9fbfe..1741d8d4f3 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -20,8 +20,7 @@ esac PBX_LIB$1=0 if test "${USE_$1}" != "no"; then - AC_CHECK_LIB([$1], [$2], AC_DEFINE_UNQUOTED([HAVE_$4], 1, - [Define to indicate the $5 library]), [], -L${$1_DIR}/lib $6) + AC_CHECK_LIB([$1], [$2], [], [], -L${$1_DIR}/lib $6) if test "${ac_cv_lib_$1_$2}" = "yes"; then $1_LIB="-l$1 $6" @@ -51,6 +50,7 @@ if test "${USE_$1}" != "no"; then PBX_LIB$1=0 else PBX_LIB$1=1 + AC_DEFINE_UNQUOTED([HAVE_$4], 1, [Define to indicate the $5 library]) fi elif test ! -z "${$1_MANDATORY}"; then