[asterisk-commits] mmichelson: trunk r103725 - in /trunk: ./ doc/tex/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Feb 15 11:32:43 CST 2008


Author: mmichelson
Date: Fri Feb 15 11:32:43 2008
New Revision: 103725

URL: http://svn.digium.com/view/asterisk?view=rev&rev=103725
Log:
Merged revisions 103722 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r103722 | mmichelson | 2008-02-15 11:26:37 -0600 (Fri, 15 Feb 2008) | 8 lines

Final round of changes for configure script logic for IMAP

Now if a directory is specified, then we will search that directory for
a source installation of the IMAP toolkit. If none is found, then we will
use that directory as the basis for detecting a package installation of
the IMAP c-client. If that check fails, then configure will fail.


........

Modified:
    trunk/   (props changed)
    trunk/configure
    trunk/configure.ac
    trunk/doc/tex/imapstorage.tex

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/configure.ac
URL: http://svn.digium.com/view/asterisk/trunk/configure.ac?view=diff&rev=103725&r1=103724&r2=103725
==============================================================================
--- trunk/configure.ac (original)
+++ trunk/configure.ac Fri Feb 15 11:32:43 2008
@@ -782,12 +782,135 @@
 			AC_MSG_RESULT(no)
 			if test "${switch_to_system_on_failure}" = "yes"; then
 				IMAP_TK_DIR="system"
+			else #This means they specified a directory. Search for a package installation there too
+				AC_MSG_CHECKING([for system c-client library...])
+				CPPFLAGS="${saved_cppflags}"
+				LIBS="${saved_libs}"
+				imap_include="-I${IMAP_TK_DIR}/include"
+				imap_ldflags="-I${IMAP_TK_DIR}/lib"
+				imap_libs="-lc-client"
+				CPPFLAGS="${CPPFLAGS} ${imap_include}"
+				LIBS="${LIBS} ${imap_libs} ${imap_ldflags}"
+				AC_LINK_IFELSE(
+	    			AC_LANG_PROGRAM(
+						[#include "c-client.h"
+						void mm_searched (MAILSTREAM *stream,unsigned long number)
+						{
+						}
+						void mm_exists (MAILSTREAM *stream,unsigned long number)
+						{
+						}
+						void mm_expunged (MAILSTREAM *stream,unsigned long number)
+						{
+						}
+						void mm_flags (MAILSTREAM *stream,unsigned long number)
+						{
+						}
+						void mm_notify (MAILSTREAM *stream,char *string,long errflg)
+						{
+						}
+						void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
+						{
+						}
+						void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
+						{
+						}
+						void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
+						{
+						}
+						void mm_log (char *string,long errflg)
+						{
+						}
+						void mm_dlog (char *string)
+						{
+						}
+						void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
+						{
+						}
+						void mm_critical (MAILSTREAM *stream)
+						{
+						}
+						void mm_nocritical (MAILSTREAM *stream)
+						{
+						}
+						long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
+						{
+						}
+						void mm_fatal (char *string)
+						{
+						}],
+						[
+						MAILSTREAM *foo = mail_open(NULL, "", 0);
+						]
+					),
+					[ac_cv_imap_tk="yes"],
+					[ac_cv_imap_tk="no"]
+	   			)
+				if test "${ac_cv_imap_tk}" = "yes"; then
+					AC_LINK_IFELSE(
+						AC_LANG_PROGRAM(
+							[#include "c-client.h"
+							void mm_searched (MAILSTREAM *stream,unsigned long number)
+							{
+							}
+							void mm_exists (MAILSTREAM *stream,unsigned long number)
+							{
+							}
+							void mm_expunged (MAILSTREAM *stream,unsigned long number)
+							{
+							}
+							void mm_flags (MAILSTREAM *stream,unsigned long number)
+							{
+							}
+							void mm_notify (MAILSTREAM *stream,char *string,long errflg)
+							{
+							}
+							void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
+							{
+							}
+							void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
+							{
+							}
+							void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
+							{
+							}
+							void mm_log (char *string,long errflg)
+							{
+							}
+							void mm_dlog (char *string)
+							{
+							}
+							void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
+							{
+							}
+							void mm_critical (MAILSTREAM *stream)
+							{
+							}
+							void mm_nocritical (MAILSTREAM *stream)
+							{
+							}
+							long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
+							{
+							}
+							void mm_fatal (char *string)
+							{
+							}],
+							[
+							long check = mail_expunge_full(NULL, "", 0);
+							]
+						),
+						[ac_cv_imap_tk2006="yes"],
+						[ac_cv_imap_tk2006="no"]
+					)
+				fi
 			fi
 		fi
 	fi 
 	if test "${IMAP_TK_DIR}" = "system"; then
 		#We will enter here if user specified "system" or if any of above checks failed
 		AC_MSG_CHECKING([for system c-client library...])
+		CPPFLAGS="${saved_cppflags}"
+		LIBS="${saved_libs}"
 		imap_ldflags=""
 		imap_libs="-lc-client"
 		imap_include="-DUSE_SYSTEM_IMAP" #Try the imap directory first

Modified: trunk/doc/tex/imapstorage.tex
URL: http://svn.digium.com/view/asterisk/trunk/doc/tex/imapstorage.tex?view=diff&rev=103725&r1=103724&r2=103725
==============================================================================
--- trunk/doc/tex/imapstorage.tex (original)
+++ trunk/doc/tex/imapstorage.tex Fri Feb 15 11:32:43 2008
@@ -55,7 +55,10 @@
 \subsubsection{Compiling Asterisk}
 
 Configure with ./configure --with-imap=/usr/src/imap
-or where ever you built thfe UWashington IMAP Toolkit. 
+or where ever you built thfe UWashington IMAP Toolkit. This directory
+will be searched for a source installation. If no source installation is
+found there, then a package installation of the IMAP c-client will be 
+searched for in this directory. If one is not found, then configure will fail.
 
 A second configure option is to not specify a directory (i.e.
 ./configure --with-imap). This will assume that you have the




More information about the asterisk-commits mailing list