diff options
author | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-06-18 16:35:02 +0000 |
---|---|---|
committer | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2007-06-18 16:35:02 +0000 |
commit | 121a06bcef920eaacdff522fb7065206ed236618 (patch) | |
tree | d7314bf848c8382af9bceb52b4d25b36c880d70c | |
parent | 28bc8008154a6262b5814b90f2814ef90e743164 (diff) |
To prevent 92138749238754 more reports of "I have unixodbc installed, but
still can't build *_odbc.so!", check for ltdl directly, instead of just listing
it as another library to include in the unixodbc check in the configure script.
This also makes ltdl show up as a dependency in menuselect so people know what
to go install. (related to issue #9989, patch by me)
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@69702 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | apps/app_voicemail.c | 1 | ||||
-rw-r--r-- | build_tools/menuselect-deps.in | 1 | ||||
-rw-r--r-- | cdr/cdr_odbc.c | 1 | ||||
-rwxr-xr-x | configure | 453 | ||||
-rw-r--r-- | configure.ac | 6 | ||||
-rw-r--r-- | funcs/func_odbc.c | 1 | ||||
-rw-r--r-- | include/asterisk/autoconfig.h.in | 3 | ||||
-rw-r--r-- | res/res_config_odbc.c | 1 | ||||
-rw-r--r-- | res/res_odbc.c | 1 |
9 files changed, 459 insertions, 9 deletions
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c index c585c2e5a..4f57eef32 100644 --- a/apps/app_voicemail.c +++ b/apps/app_voicemail.c @@ -37,6 +37,7 @@ <category name="MENUSELECT_OPTS_app_voicemail" displayname="Voicemail Build Options" positive_output="yes" remove_on_change="apps/app_voicemail.o"> <member name="ODBC_STORAGE" displayname="Storage of Voicemail using ODBC"> <depend>unixodbc</depend> + <depend>ltdl</depend> <conflict>IMAP_STORAGE</conflict> <defaultenabled>no</defaultenabled> </member> diff --git a/build_tools/menuselect-deps.in b/build_tools/menuselect-deps.in index 19b656c7a..8aaa0b598 100644 --- a/build_tools/menuselect-deps.in +++ b/build_tools/menuselect-deps.in @@ -10,6 +10,7 @@ IKSEMEL=@PBX_IKSEMEL@ IMAP_TK=@PBX_IMAP_TK@ IXJUSER=@PBX_IXJUSER@ KDE=@PBX_KDE@ +LTDL=@PBX_LTDL@ NBS=@PBX_NBS@ NETSNMP=@PBX_NETSNMP@ NEWT=@PBX_NEWT@ diff --git a/cdr/cdr_odbc.c b/cdr/cdr_odbc.c index 4afda0e8e..2cd559af8 100644 --- a/cdr/cdr_odbc.c +++ b/cdr/cdr_odbc.c @@ -30,6 +30,7 @@ /*** MODULEINFO <depend>unixodbc</depend> + <depend>ltdl</depend> ***/ #include "asterisk.h" @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.ac Revision: 66160 . +# From configure.ac Revision: 67026 . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61. # @@ -752,6 +752,10 @@ KDE_LIB KDE_INCLUDE KDE_DIR PBX_KDE +LTDL_LIB +LTDL_INCLUDE +LTDL_DIR +PBX_LTDL MISDN_LIB MISDN_INCLUDE MISDN_DIR @@ -1503,6 +1507,7 @@ Optional Packages: --with-imap=PATH use UW IMAP Toolkit files in PATH --with-isdnnet=PATH use ISDN4Linux Library files in PATH --with-kde=PATH use KDE files in PATH + --with-ltdl=PATH use libtool files in PATH --with-misdn=PATH use mISDN User Library files in PATH --with-nbs=PATH use Network Broadcast Sound files in PATH --with-ncurses=PATH use ncurses files in PATH @@ -7820,6 +7825,34 @@ PBX_KDE=0 +LTDL_DESCRIP="libtool" +LTDL_OPTION="ltdl" + +# Check whether --with-ltdl was given. +if test "${with_ltdl+set}" = set; then + withval=$with_ltdl; +case ${withval} in + n|no) + USE_LTDL=no + ;; + y|ye|yes) + LTDL_MANDATORY="yes" + ;; + *) + LTDL_DIR="${withval}" + LTDL_MANDATORY="yes" + ;; +esac + +fi + +PBX_LTDL=0 + + + + + + MISDN_DESCRIP="mISDN User Library" MISDN_OPTION="misdn" @@ -18365,6 +18398,406 @@ echo "${ECHO_T}no" >&6; } fi fi +# Needed by unixodbc + +if test "${USE_LTDL}" != "no"; then + pbxlibdir="" + if test "x${LTDL_DIR}" != "x"; then + if test -d ${LTDL_DIR}/lib; then + pbxlibdir="-L${LTDL_DIR}/lib" + else + pbxlibdir="-L${LTDL_DIR}" + fi + fi + { echo "$as_me:$LINENO: checking for lt_dlinit in -lltdl" >&5 +echo $ECHO_N "checking for lt_dlinit in -lltdl... $ECHO_C" >&6; } +if test "${ac_cv_lib_ltdl_lt_dlinit+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lltdl ${pbxlibdir} $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 GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char lt_dlinit (); +int +main () +{ +return lt_dlinit (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&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); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && + $as_test_x conftest$ac_exeext; then + ac_cv_lib_ltdl_lt_dlinit=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_ltdl_lt_dlinit=no +fi + +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 +{ echo "$as_me:$LINENO: result: $ac_cv_lib_ltdl_lt_dlinit" >&5 +echo "${ECHO_T}$ac_cv_lib_ltdl_lt_dlinit" >&6; } +if test $ac_cv_lib_ltdl_lt_dlinit = yes; then + AST_LTDL_FOUND=yes +else + AST_LTDL_FOUND=no +fi + + + if test "${AST_LTDL_FOUND}" = "yes"; then + LTDL_LIB="-lltdl " + LTDL_HEADER_FOUND="1" + if test "x${LTDL_DIR}" != "x"; then + LTDL_LIB="${pbxlibdir} ${LTDL_LIB}" + LTDL_INCLUDE="-I${LTDL_DIR}/include" + saved_cppflags="${CPPFLAGS}" + CPPFLAGS="${CPPFLAGS} -I${LTDL_DIR}/include" + if test "xltdl.h" != "x" ; then + as_ac_Header=`echo "ac_cv_header_${LTDL_DIR}/include/ltdl.h" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { echo "$as_me:$LINENO: checking for ${LTDL_DIR}/include/ltdl.h" >&5 +echo $ECHO_N "checking for ${LTDL_DIR}/include/ltdl.h... $ECHO_C" >&6; } +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +fi +ac_res=`eval echo '${'$as_ac_Header'}'` + { echo "$as_me:$LINENO: result: $ac_res" >&5 +echo "${ECHO_T}$ac_res" >&6; } +else + # Is the header compilable? +{ echo "$as_me:$LINENO: checking ${LTDL_DIR}/include/ltdl.h usability" >&5 +echo $ECHO_N "checking ${LTDL_DIR}/include/ltdl.h usability... $ECHO_C" >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +#include <${LTDL_DIR}/include/ltdl.h> +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 + (eval "$ac_compile") 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); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_header_compiler=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +echo "${ECHO_T}$ac_header_compiler" >&6; } + +# Is the header present? +{ echo "$as_me:$LINENO: checking ${LTDL_DIR}/include/ltdl.h presence" >&5 +echo $ECHO_N "checking ${LTDL_DIR}/include/ltdl.h presence... $ECHO_C" >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <${LTDL_DIR}/include/ltdl.h> +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 + (eval "$ac_cpp conftest.$ac_ext") 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); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + ac_header_preproc=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +echo "${ECHO_T}$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: proceeding with the compiler's result" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: present but cannot be compiled" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: check for missing prerequisite headers?" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: check for missing prerequisite headers?" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: see the Autoconf documentation" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: see the Autoconf documentation" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: section \"Present But Cannot Be Compiled\"" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: section \"Present But Cannot Be Compiled\"" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: proceeding with the preprocessor's result" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: proceeding with the preprocessor's result" >&2;} + { echo "$as_me:$LINENO: WARNING: ${LTDL_DIR}/include/ltdl.h: in the future, the compiler will take precedence" >&5 +echo "$as_me: WARNING: ${LTDL_DIR}/include/ltdl.h: in the future, the compiler will take precedence" >&2;} + + ;; +esac +{ echo "$as_me:$LINENO: checking for ${LTDL_DIR}/include/ltdl.h" >&5 +echo $ECHO_N "checking for ${LTDL_DIR}/include/ltdl.h... $ECHO_C" >&6; } +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + eval "$as_ac_Header=\$ac_header_preproc" +fi +ac_res=`eval echo '${'$as_ac_Header'}'` + { echo "$as_me:$LINENO: result: $ac_res" >&5 +echo "${ECHO_T}$ac_res" >&6; } + +fi +if test `eval echo '${'$as_ac_Header'}'` = yes; then + LTDL_HEADER_FOUND=1 +else + LTDL_HEADER_FOUND=0 +fi + + + fi + CPPFLAGS="${saved_cppflags}" + else + if test "xltdl.h" != "x" ; then + if test "${ac_cv_header_ltdl_h+set}" = set; then + { echo "$as_me:$LINENO: checking for ltdl.h" >&5 +echo $ECHO_N "checking for ltdl.h... $ECHO_C" >&6; } +if test "${ac_cv_header_ltdl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +fi +{ echo "$as_me:$LINENO: result: $ac_cv_header_ltdl_h" >&5 +echo "${ECHO_T}$ac_cv_header_ltdl_h" >&6; } +else + # Is the header compilable? +{ echo "$as_me:$LINENO: checking ltdl.h usability" >&5 +echo $ECHO_N "checking ltdl.h usability... $ECHO_C" >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +#include <ltdl.h> +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 + (eval "$ac_compile") 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); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_header_compiler=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +echo "${ECHO_T}$ac_header_compiler" >&6; } + +# Is the header present? +{ echo "$as_me:$LINENO: checking ltdl.h presence" >&5 +echo $ECHO_N "checking ltdl.h presence... $ECHO_C" >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <ltdl.h> +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 + (eval "$ac_cpp conftest.$ac_ext") 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); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + ac_header_preproc=yes +else + echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +echo "${ECHO_T}$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { echo "$as_me:$LINENO: WARNING: ltdl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +echo "$as_me: WARNING: ltdl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: proceeding with the compiler's result" >&5 +echo "$as_me: WARNING: ltdl.h: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { echo "$as_me:$LINENO: WARNING: ltdl.h: present but cannot be compiled" >&5 +echo "$as_me: WARNING: ltdl.h: present but cannot be compiled" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: check for missing prerequisite headers?" >&5 +echo "$as_me: WARNING: ltdl.h: check for missing prerequisite headers?" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: see the Autoconf documentation" >&5 +echo "$as_me: WARNING: ltdl.h: see the Autoconf documentation" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: section \"Present But Cannot Be Compiled\"" >&5 +echo "$as_me: WARNING: ltdl.h: section \"Present But Cannot Be Compiled\"" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: proceeding with the preprocessor's result" >&5 +echo "$as_me: WARNING: ltdl.h: proceeding with the preprocessor's result" >&2;} + { echo "$as_me:$LINENO: WARNING: ltdl.h: in the future, the compiler will take precedence" >&5 +echo "$as_me: WARNING: ltdl.h: in the future, the compiler will take precedence" >&2;} + + ;; +esac +{ echo "$as_me:$LINENO: checking for ltdl.h" >&5 +echo $ECHO_N "checking for ltdl.h... $ECHO_C" >&6; } +if test "${ac_cv_header_ltdl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + ac_cv_header_ltdl_h=$ac_header_preproc +fi +{ echo "$as_me:$LINENO: result: $ac_cv_header_ltdl_h" >&5 +echo "${ECHO_T}$ac_cv_header_ltdl_h" >&6; } + +fi +if test $ac_cv_header_ltdl_h = yes; then + LTDL_HEADER_FOUND=1 +else + LTDL_HEADER_FOUND=0 +fi + + + fi + fi + if test "x${LTDL_HEADER_FOUND}" = "x0" ; then + if test -n "${LTDL_MANDATORY}" ; + then + { echo "$as_me:$LINENO: ***" >&5 +echo "$as_me: ***" >&6;} + { echo "$as_me:$LINENO: *** It appears that you do not have the ltdl development package installed." >&5 +echo "$as_me: *** It appears that you do not have the ltdl development package installed." >&6;} + { echo "$as_me:$LINENO: *** Please install it to include ${LTDL_DESCRIP} support, or re-run configure" >&5 +echo "$as_me: *** Please install it to include ${LTDL_DESCRIP} support, or re-run configure" >&6;} + { echo "$as_me:$LINENO: *** without explicitly specifying --with-${LTDL_OPTION}" >&5 +echo "$as_me: *** without explicitly specifying --with-${LTDL_OPTION}" >&6;} + exit 1 + fi + LTDL_LIB="" + LTDL_INCLUDE="" + PBX_LTDL=0 + else + PBX_LTDL=1 + +cat >>confdefs.h <<_ACEOF +#define HAVE_LTDL 1 +_ACEOF + + fi + elif test -n "${LTDL_MANDATORY}"; + then + { echo "$as_me:$LINENO: ***" >&5 +echo "$as_me: ***" >&6;} + { echo "$as_me:$LINENO: *** The ${LTDL_DESCRIP} installation on this system appears to be broken." >&5 +echo "$as_me: *** The ${LTDL_DESCRIP} installation on this system appears to be broken." >&6;} + { echo "$as_me:$LINENO: *** Either correct the installation, or run configure" >&5 +echo "$as_me: *** Either correct the installation, or run configure" >&6;} + { echo "$as_me:$LINENO: *** without explicitly specifying --with-${LTDL_OPTION}" >&5 +echo "$as_me: *** without explicitly specifying --with-${LTDL_OPTION}" >&6;} + exit 1 + fi +fi + + ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -21451,7 +21884,7 @@ if test "${ac_cv_lib_odbc_SQLConnect+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lodbc ${pbxlibdir} -lltdl $LIBS" +LIBS="-lodbc ${pbxlibdir} $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF @@ -21514,7 +21947,7 @@ fi if test "${AST_UNIXODBC_FOUND}" = "yes"; then - UNIXODBC_LIB="-lodbc -lltdl" + UNIXODBC_LIB="-lodbc " UNIXODBC_HEADER_FOUND="1" if test "x${UNIXODBC_DIR}" != "x"; then UNIXODBC_LIB="${pbxlibdir} ${UNIXODBC_LIB}" @@ -31391,6 +31824,10 @@ KDE_LIB!$KDE_LIB$ac_delim KDE_INCLUDE!$KDE_INCLUDE$ac_delim KDE_DIR!$KDE_DIR$ac_delim PBX_KDE!$PBX_KDE$ac_delim +LTDL_LIB!$LTDL_LIB$ac_delim +LTDL_INCLUDE!$LTDL_INCLUDE$ac_delim +LTDL_DIR!$LTDL_DIR$ac_delim +PBX_LTDL!$PBX_LTDL$ac_delim MISDN_LIB!$MISDN_LIB$ac_delim MISDN_INCLUDE!$MISDN_INCLUDE$ac_delim MISDN_DIR!$MISDN_DIR$ac_delim @@ -31448,10 +31885,6 @@ OPENH323_INCLUDE!$OPENH323_INCLUDE$ac_delim OPENH323_DIR!$OPENH323_DIR$ac_delim PBX_OPENH323!$PBX_OPENH323$ac_delim QT_LIB!$QT_LIB$ac_delim -QT_INCLUDE!$QT_INCLUDE$ac_delim -QT_DIR!$QT_DIR$ac_delim -PBX_QT!$PBX_QT$ac_delim -RADIUS_LIB!$RADIUS_LIB$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then @@ -31493,6 +31926,10 @@ _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF +QT_INCLUDE!$QT_INCLUDE$ac_delim +QT_DIR!$QT_DIR$ac_delim +PBX_QT!$PBX_QT$ac_delim +RADIUS_LIB!$RADIUS_LIB$ac_delim RADIUS_INCLUDE!$RADIUS_INCLUDE$ac_delim RADIUS_DIR!$RADIUS_DIR$ac_delim PBX_RADIUS!$PBX_RADIUS$ac_delim @@ -31582,7 +32019,7 @@ CURL_CONFIG!$CURL_CONFIG$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 87; then + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 91; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 diff --git a/configure.ac b/configure.ac index 5b565fbd7..fd546ceee 100644 --- a/configure.ac +++ b/configure.ac @@ -179,6 +179,7 @@ AST_EXT_LIB_SETUP([IKSEMEL], [Iksemel Jabber Library], [iksemel]) AST_EXT_LIB_SETUP([IMAP_TK], [UW IMAP Toolkit], [imap]) AST_EXT_LIB_SETUP([ISDNNET], [ISDN4Linux Library], [isdnnet]) AST_EXT_LIB_SETUP([KDE], [KDE], [kde]) +AST_EXT_LIB_SETUP([LTDL], [libtool], [ltdl]) AST_EXT_LIB_SETUP([MISDN], [mISDN User Library], [misdn]) AST_EXT_LIB_SETUP([NBS], [Network Broadcast Sound], [nbs]) AST_EXT_LIB_SETUP([NCURSES], [ncurses], [ncurses]) @@ -578,6 +579,9 @@ if test "${USE_IMAP_TK}" != "no"; then fi fi +# Needed by unixodbc +AST_EXT_LIB_CHECK([LTDL], [ltdl], [lt_dlinit], [ltdl.h], []) + AC_LANG_PUSH(C++) if test "${USE_KDE}" != "no"; then @@ -690,7 +694,7 @@ fi AST_EXT_LIB_CHECK([NEWT], [newt], [newtBell], [newt.h]) -AST_EXT_LIB_CHECK([UNIXODBC], [odbc], [SQLConnect], [sql.h], [-lltdl]) +AST_EXT_LIB_CHECK([UNIXODBC], [odbc], [SQLConnect], [sql.h], []) AST_EXT_LIB_CHECK([OGG], [ogg], [ogg_sync_init], []) diff --git a/funcs/func_odbc.c b/funcs/func_odbc.c index bf6ad0ec8..c5ea6fcda 100644 --- a/funcs/func_odbc.c +++ b/funcs/func_odbc.c @@ -26,6 +26,7 @@ /*** MODULEINFO <depend>unixodbc</depend> + <depend>ltdl</depend> <depend>res_odbc</depend> ***/ diff --git a/include/asterisk/autoconfig.h.in b/include/asterisk/autoconfig.h.in index b9a9f0c98..08b9996d9 100644 --- a/include/asterisk/autoconfig.h.in +++ b/include/asterisk/autoconfig.h.in @@ -178,6 +178,9 @@ /* Define to 1 if you have the `localtime_r' function. */ #undef HAVE_LOCALTIME_R +/* Define to indicate the ${LTDL_DESCRIP} library */ +#undef HAVE_LTDL + /* Define to 1 if you have the <malloc.h> header file. */ #undef HAVE_MALLOC_H diff --git a/res/res_config_odbc.c b/res/res_config_odbc.c index 496050263..ddf528406 100644 --- a/res/res_config_odbc.c +++ b/res/res_config_odbc.c @@ -30,6 +30,7 @@ /*** MODULEINFO <depend>unixodbc</depend> + <depend>ltdl</depend> <depend>res_odbc</depend> ***/ diff --git a/res/res_odbc.c b/res/res_odbc.c index 328a811dc..461e941e0 100644 --- a/res/res_odbc.c +++ b/res/res_odbc.c @@ -31,6 +31,7 @@ /*** MODULEINFO <depend>unixodbc</depend> + <depend>ltdl</depend> ***/ #include "asterisk.h" |