[Asterisk-code-review] BuildSystem: Enable IMAP storage on FreeBSD and DragonFly BSD. (asterisk[13])
Joshua Colp
asteriskteam at digium.com
Thu Apr 26 19:06:31 CDT 2018
Joshua Colp has submitted this change and it was merged. ( https://gerrit.asterisk.org/8846 )
Change subject: BuildSystem: Enable IMAP storage on FreeBSD and DragonFly BSD.
......................................................................
BuildSystem: Enable IMAP storage on FreeBSD and DragonFly BSD.
ASTERISK-27639
Change-Id: I1347f3f2f3737010d0a80a5c30b5aaf71cf3ccb0
---
M configure
M configure.ac
2 files changed, 132 insertions(+), 0 deletions(-)
Approvals:
Joshua Colp: Looks good to me, but someone else must approve; Approved for Submit
Kevin Harwell: Looks good to me, approved
diff --git a/configure b/configure
index d8aebc7..7c52cf1 100755
--- a/configure
+++ b/configure
@@ -21769,6 +21769,78 @@
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
+ if test "${ac_cv_imap_tk}" = "no"; then
+ imap_libs="-lcrypto -lssl -lc-client4"
+ LIBS="${saved_libs} ${imap_libs} "`echo ${imap_ldflags}`
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <stdio.h>
+ #include <c-client/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)
+ {
+ }
+int
+main ()
+{
+
+ MAILSTREAM *foo = mail_open(NULL, "", 0);
+
+
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_imap_tk="yes"
+else
+ ac_cv_imap_tk="no"
+
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+ fi
if test "${ac_cv_imap_tk}" = "yes"; then
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
diff --git a/configure.ac b/configure.ac
index 61db0e2..1bd8205 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2041,6 +2041,66 @@
[ac_cv_imap_tk="yes"],
[ac_cv_imap_tk="no"]
)
+ if test "${ac_cv_imap_tk}" = "no"; then
+ imap_libs="-lcrypto -lssl -lc-client4"
+ LIBS="${saved_libs} ${imap_libs} "`echo ${imap_ldflags}`
+ AC_LINK_IFELSE(
+ [AC_LANG_PROGRAM(
+ [#include <stdio.h>
+ #include <c-client/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"]
+ )
+ fi
if test "${ac_cv_imap_tk}" = "yes"; then
AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
--
To view, visit https://gerrit.asterisk.org/8846
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: merged
Gerrit-Change-Id: I1347f3f2f3737010d0a80a5c30b5aaf71cf3ccb0
Gerrit-Change-Number: 8846
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Traud <pabstraud at compuserve.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180426/6b9b8c68/attachment.html>
More information about the asterisk-code-review
mailing list