I apparently misunderstood one of the requirements of this configure change.

Now, if a source directory is specified with the --with-imap option, and a valid
source installation is not detected there, then configure will fail and will not
check for a package installation.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@103709 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Mark Michelson
2008-02-15 00:50:49 +00:00
parent 2bd91c05b5
commit 2ee7626928
3 changed files with 59 additions and 80 deletions

View File

@@ -479,8 +479,10 @@ if test "${PBX_IKSEMEL}" = 1; then
fi
if test "${USE_IMAP_TK}" != "no"; then
switch_to_system_on_failure="no"
if test "${IMAP_TK_DIR}" = ""; then
IMAP_TK_DIR=`pwd`"/../imap-2004g"
switch_to_system_on_failure="yes"
fi
saved_cppflags="${CPPFLAGS}"
saved_libs="${LIBS}"
@@ -607,18 +609,11 @@ if test "${USE_IMAP_TK}" != "no"; then
fi
CPPFLAGS="${saved_cppflags}"
LIBS="${saved_libs}"
if test "${ac_cv_imap_tk}" = "yes"; then
AC_MSG_RESULT(yes)
IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
IMAP_TK_INCLUDE="${imap_include}"
PBX_IMAP_TK=1
AC_DEFINE([HAVE_IMAP_TK], 1, [Define if your system has the UW IMAP Toolkit c-client library.])
if test "${ac_cv_imap_tk2006}" = "yes"; then
AC_DEFINE([HAVE_IMAP_TK2006], 1, [Define if your system has the UW IMAP Toolkit c-client library version 2006 or greater.])
fi
else
if test "${ac_cv_imap_tk}" = "no"; then
AC_MSG_RESULT(no)
IMAP_TK_DIR="system"
if test "${switch_to_system_on_failure}" = "yes"; then
IMAP_TK_DIR="system"
fi
fi
fi
if test "${IMAP_TK_DIR}" = "system"; then
@@ -865,27 +860,27 @@ if test "${USE_IMAP_TK}" != "no"; then
)
fi
fi
if test "${ac_cv_imap_tk}" = "yes"; then
AC_MSG_RESULT(yes)
CPPFLAGS="${saved_cppflags}"
LIBS="${saved_libs}"
IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
IMAP_TK_INCLUDE="${imap_include}"
PBX_IMAP_TK=1
AC_DEFINE([HAVE_IMAP_TK], 1, [Define if your system has the UW IMAP Toolkit c-client library.])
if test "${ac_cv_imap_tk2006}" = "yes"; then
AC_DEFINE([HAVE_IMAP_TK2006], 1, [Define if your system has the UW IMAP Toolkit c-client library version 2006 or greater.])
fi
elif test -n "${IMAP_TK_MANDATORY}"; then
AC_MSG_RESULT(no)
AC_MSG_NOTICE([***])
AC_MSG_NOTICE([*** The UW IMAP Toolkit installation on this system appears to be broken.])
AC_MSG_NOTICE([*** Either correct the installation, or run configure])
AC_MSG_NOTICE([*** including --without-imap.])
exit 1
else
AC_MSG_RESULT(no)
fi
if test "${ac_cv_imap_tk}" = "yes"; then
AC_MSG_RESULT(yes)
CPPFLAGS="${saved_cppflags}"
LIBS="${saved_libs}"
IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
IMAP_TK_INCLUDE="${imap_include}"
PBX_IMAP_TK=1
AC_DEFINE([HAVE_IMAP_TK], 1, [Define if your system has the UW IMAP Toolkit c-client library.])
if test "${ac_cv_imap_tk2006}" = "yes"; then
AC_DEFINE([HAVE_IMAP_TK2006], 1, [Define if your system has the UW IMAP Toolkit c-client library version 2006 or greater.])
fi
elif test -n "${IMAP_TK_MANDATORY}"; then
AC_MSG_RESULT(no)
AC_MSG_NOTICE([***])
AC_MSG_NOTICE([*** The UW IMAP Toolkit installation on this system appears to be broken.])
AC_MSG_NOTICE([*** Either correct the installation, or run configure])
AC_MSG_NOTICE([*** including --without-imap.])
exit 1
else
AC_MSG_RESULT(no)
fi
fi