forked from Mirrors/freeswitch
Improve configure handling of ODBC
This commit changes behavior such that if --disable-core-odbc-support is provided we'll build without ODBC even if the libraries are there. Previously we would always quietly build with ODBC support if it was on the system. Contrary to what was said in commit72a804983
, my 2012 commitffc8e81b7
did not affect the behavior of --disable-core-odbc-support. We never recognized the flag as being different from not providing the option at all. What the commit did do was to cause us to fail loudly if --enable-core-odbc-support was provided but the system libraries were not there. This behavior is preserved. (That commit also caused us to potentially run certain checks twice, which this commit resolves.) You can also now provide --enable-core-odbc-support=optional which has the same effect as the default behavior. FS-6173 --resolve Thanks-to: James Le Cuirot <chewi@aura-online.co.uk>
This commit is contained in:
parent
3cad316804
commit
ab2bc7c689
19
configure.in
19
configure.in
|
@ -402,14 +402,17 @@ AM_CONDITIONAL([ENABLE_ZRTP],[test "x$enable_zrtp" != "xno"])
|
||||||
|
|
||||||
AM_CONDITIONAL([WANT_DEBUG],[test "${enable_debug}" = "yes"])
|
AM_CONDITIONAL([WANT_DEBUG],[test "${enable_debug}" = "yes"])
|
||||||
|
|
||||||
AC_ARG_ENABLE(core-odbc-support,
|
AC_ARG_ENABLE(core-odbc-support,
|
||||||
[AS_HELP_STRING([--enable-core-odbc-support], [Compile with ODBC Support])],,[enable_core_odbc_support="no"])
|
[AS_HELP_STRING([--enable-core-odbc-support], [Compile with ODBC Support (default is optional)])],,[enable_core_odbc_support="optional"])
|
||||||
AX_LIB_ODBC
|
if ! test "$enable_core_odbc_support" = "no"; then
|
||||||
if test "$ac_cv_found_odbc" = "yes" ; then
|
AX_LIB_ODBC
|
||||||
enable_core_odbc_support="yes"
|
if test "$ac_cv_found_odbc" = "yes" ; then
|
||||||
fi
|
enable_core_odbc_support="yes"
|
||||||
if test "x$enable_core_odbc_support" != "xno"; then
|
elif test "$enable_core_odbc_support" = "yes"; then
|
||||||
AC_CHECK_LIB([odbc], [SQLDisconnect],, AC_MSG_ERROR([no usable libodbc; please install unixodbc devel package or equivalent]))
|
AC_MSG_ERROR([no usable libodbc; please install unixodbc devel package or equivalent])
|
||||||
|
else
|
||||||
|
enable_core_odbc_support="no"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CHECK_LIBUUID
|
CHECK_LIBUUID
|
||||||
|
|
Loading…
Reference in New Issue