[PHP-CVS] cvs: php4 /ext/imap config.m4

2001-04-10 Thread Jon Parise

jon Tue Apr 10 10:31:35 2001 EDT

  Modified files:  
/php4/ext/imap  config.m4 
  Log:
  Statements end with a period.
  
  
Index: php4/ext/imap/config.m4
diff -u php4/ext/imap/config.m4:1.26 php4/ext/imap/config.m4:1.27
--- php4/ext/imap/config.m4:1.26Tue Mar 27 12:34:28 2001
+++ php4/ext/imap/config.m4 Tue Apr 10 10:31:35 2001
@@ -1,4 +1,4 @@
-dnl $Id: config.m4,v 1.26 2001/03/27 20:34:28 sniper Exp $
+dnl $Id: config.m4,v 1.27 2001/04/10 17:31:35 jon Exp $
 
 AC_DEFUN(IMAP_INC_CHK,[if test -r "$i$1/c-client.h"; then
AC_DEFINE(HAVE_IMAP2000, 1, [ ])
@@ -60,7 +60,7 @@
 PHP_EXPAND_PATH($IMAP_DIR, IMAP_DIR)
 
 if test -z "$IMAP_DIR"; then
-  AC_MSG_ERROR(Cannot find rfc822.h. Please check your IMAP installation)
+  AC_MSG_ERROR(Cannot find rfc822.h. Please check your IMAP installation.)
 fi
 
 if test -r "$IMAP_DIR/c-client/c-client.a"; then
@@ -76,7 +76,7 @@
 done
 
 if test -z "$IMAP_LIBDIR"; then
-  AC_MSG_ERROR(Cannot find imap library. Please check your IMAP installation)
+  AC_MSG_ERROR(Cannot find imap library. Please check your IMAP installation.)
 fi
 
 PHP_ADD_INCLUDE($IMAP_INC_DIR)



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/imap config.m4 php_imap.c

2001-02-28 Thread Chuck Hagenbuch

chagenbuWed Feb 28 23:06:54 2001 EDT

  Modified files:  
/php4/ext/imap  config.m4 php_imap.c 
  Log:
  If php is compiled --with-imap-ssl, link in the SSL authenticator from
  c-client so that we can use php to make ssl imap connections.
  
  
Index: php4/ext/imap/config.m4
diff -u php4/ext/imap/config.m4:1.24 php4/ext/imap/config.m4:1.25
--- php4/ext/imap/config.m4:1.24Mon Feb 26 07:17:12 2001
+++ php4/ext/imap/config.m4 Wed Feb 28 23:06:54 2001
@@ -1,4 +1,4 @@
-dnl $Id: config.m4,v 1.24 2001/02/26 15:17:12 kalowsky Exp $
+dnl $Id: config.m4,v 1.25 2001/03/01 07:06:54 chagenbu Exp $
 
 AC_DEFUN(IMAP_INC_CHK,[if test -r "$i$1/c-client.h"; then
AC_DEFINE(HAVE_IMAP2000, 1, [ ])
@@ -97,6 +97,7 @@
 fi
 
 if test "$PHP_IMAP_SSL" != "no"; then
+  AC_DEFINE(HAVE_IMAP_SSL,1,[ ])
   AC_ADD_LIBPATH($PHP_SSL_LIBDIR, IMAP_SHARED_LIBADD)
   AC_ADD_LIBRARY(ssl,, IMAP_SHARED_LIBADD)
   AC_ADD_LIBRARY(crypto,, IMAP_SHARED_LIBADD)
Index: php4/ext/imap/php_imap.c
diff -u php4/ext/imap/php_imap.c:1.61 php4/ext/imap/php_imap.c:1.62
--- php4/ext/imap/php_imap.c:1.61   Mon Feb 26 08:36:08 2001
+++ php4/ext/imap/php_imap.cWed Feb 28 23:06:54 2001
@@ -25,7 +25,7 @@
| PHP 4.0 updates:  Zeev Suraski [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: php_imap.c,v 1.61 2001/02/26 16:36:08 kalowsky Exp $ */
+/* $Id: php_imap.c,v 1.62 2001/03/01 07:06:54 chagenbu Exp $ */
 
 #define IMAP41
 
@@ -443,6 +443,10 @@
mail_link(newsdriver);  /* link in the news driver */
mail_link(philedriver); /* link in the phile driver */
auth_link(auth_log);/* link in the log authenticator */
+#ifdef  HAVE_IMAP_SSL
+   ssl_onceonlyinit ();
+   auth_link (auth_ssl);   /* link in the ssl authenticator */
+#endif
 #endif
mail_link(dummydriver); /* link in the dummy driver */
 #else



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-CVS] cvs: php4 /ext/imap config.m4 php_imap.c php_imap.h

2001-02-26 Thread Dan Kalowsky

kalowskyMon Feb 26 07:17:12 2001 EDT

  Modified files:  
/php4/ext/imap  config.m4 php_imap.c php_imap.h 
  Log:
  Correctly checks for the proper header files, and excludes the QUOTA functions
  from non-imap2000 systems (unavailable for testing at this time).  
  # anyone willing to test this out on non-imap2000?
  PR:
  Submitted by:
  Reviewed by: Sascha Schumann
  Obtained from:
  
  
Index: php4/ext/imap/config.m4
diff -u php4/ext/imap/config.m4:1.23 php4/ext/imap/config.m4:1.24
--- php4/ext/imap/config.m4:1.23Sat Feb 24 20:41:18 2001
+++ php4/ext/imap/config.m4 Mon Feb 26 07:17:12 2001
@@ -1,6 +1,14 @@
-dnl $Id: config.m4,v 1.23 2001/02/25 04:41:18 kalowsky Exp $
+dnl $Id: config.m4,v 1.24 2001/02/26 15:17:12 kalowsky Exp $
 
-AC_DEFUN(IMAP_INC_CHK,[if test -r $i$1/rfc822.h; then IMAP_DIR=$i; IMAP_INC_DIR=$i$1])
+AC_DEFUN(IMAP_INC_CHK,[if test -r "$i$1/c-client.h"; then
+   AC_DEFINE(HAVE_IMAP2000, 1, [ ])
+   IMAP_DIR=$i
+   IMAP_INC_DIR=$i$1
+   elif test -r "$i$1/rfc822.h"; then 
+   IMAP_DIR=$i; 
+   IMAP_INC_DIR=$i$1
+   
+])
 
 AC_DEFUN(IMAP_LIB_CHK,[
str="$IMAP_DIR/$1/lib$lib.*"
Index: php4/ext/imap/php_imap.c
diff -u php4/ext/imap/php_imap.c:1.59 php4/ext/imap/php_imap.c:1.60
--- php4/ext/imap/php_imap.c:1.59   Sun Feb 25 22:06:58 2001
+++ php4/ext/imap/php_imap.cMon Feb 26 07:17:12 2001
@@ -25,7 +25,7 @@
| PHP 4.0 updates:  Zeev Suraski [EMAIL PROTECTED]   |
+--+
  */
-/* $Id: php_imap.c,v 1.59 2001/02/26 06:06:58 andi Exp $ */
+/* $Id: php_imap.c,v 1.60 2001/02/26 15:17:12 kalowsky Exp $ */
 
 #define IMAP41
 
@@ -101,8 +101,10 @@
PHP_FE(imap_createmailbox,  NULL)
PHP_FE(imap_renamemailbox,  NULL)
PHP_FE(imap_deletemailbox,  NULL)
+#ifdef HAVE_IMAP2000
PHP_FE(imap_get_quota,  NULL)
PHP_FE(imap_set_quota,  NULL)
+#endif
PHP_FALIAS(imap_listmailbox, imap_list, NULL)
PHP_FALIAS(imap_getmailboxes, imap_list_full,   NULL)
PHP_FALIAS(imap_scanmailbox, imap_listscan, NULL)
@@ -357,6 +359,7 @@
  sizeof(MESSAGELIST));
 }
 
+#ifdef HAVE_IMAP2000
 /* Mail GET_QUOTA callback
  * Called via the mail_parameter function in c-client:src/c-client/mail.c
  * Author DRK
@@ -370,6 +373,7 @@
IMAPG(quota_limit) = qlist-limit;
}
 }
+#endif
 
 /* Mail garbage collect MESSAGELIST
  * Accepts: pointer to MESSAGELIST pointer
@@ -547,12 +551,13 @@
/* next UID to be assigned */
REGISTER_MAIN_LONG_CONSTANT("SA_UIDVALIDITY",SA_UIDVALIDITY , CONST_PERSISTENT 
| CONST_CS);
/* UID validity value */
-
+#ifdef HAVE_IMAP2000
sa_all |= GET_QUOTA;
 REGISTER_MAIN_LONG_CONSTANT("GET_QUOTA",GET_QUOTA , CONST_PERSISTENT | 
CONST_CS);
  /* Disk space taken up by mailbox. */
sa_all |= GET_QUOTAROOT;
 REGISTER_MAIN_LONG_CONSTANT("GET_QUOTAROOT",GET_QUOTAROOT , CONST_PERSISTENT 
| CONST_CS);
+#endif
  /* Disk space taken up by all mailboxes owned by user. */
REGISTER_MAIN_LONG_CONSTANT("SA_ALL", sa_all, CONST_PERSISTENT | CONST_CS);
  /* get all status information */
@@ -1011,7 +1016,7 @@
 }
 /* }}} */
 
-
+#ifdef HAVE_IMAP2000
 /* {{{ proto array imap_get_quota(int stream_id, string qroot)
Returns the quota set to the mailbox account qroot */
 PHP_FUNCTION(imap_get_quota)
@@ -1053,7 +1058,6 @@
 }
 /* }}} */
 
-
 /* {{{ proto int imap_set_quota(int stream_id, string qroot, int mailbox_size)
Will set the quota for qroot mailbox */
 PHP_FUNCTION(imap_set_quota)
@@ -1084,6 +1088,7 @@
RETURN_LONG(imap_setquota(imap_le_struct-imap_stream, Z_STRVAL_PP(qroot), 
limits));
 }
 /* }}} */
+#endif
 
 
 /* {{{ proto int imap_expunge(int stream_id)
Index: php4/ext/imap/php_imap.h
diff -u php4/ext/imap/php_imap.h:1.6 php4/ext/imap/php_imap.h:1.7
--- php4/ext/imap/php_imap.h:1.6Sat Feb 24 20:41:18 2001
+++ php4/ext/imap/php_imap.hMon Feb 26 07:17:12 2001
@@ -6,12 +6,15 @@
 #include "build-defs.h"
 #endif
 
-/*
+#ifdef HAVE_IMAP2000
+ /* these are used for quota support */
+ #include "c-client.h" /* includes mail.h and rfc822.h */
+ #include "imap4r1.h"  /* location of c-client quota functions */
+#else
  #include "mail.h"
  #include "rfc822.h" 
-*/
-#include "c-client.h"
-#include "imap4r1.h"   /* used for the imap_setquota function */
+#endif
+
 #include "modules.h"
 
 extern zend_module_entry imap_module_entry;
@@ -104,8 +107,10 @@
 PHP_FUNCTION(imap_deletemailbox);
 PHP_FUNCTION(imap_listmailbox);
 PHP_FUNCTION(imap_scanmailbox);
+#ifdef HAVE_IMAP2000
 PHP_FUNCTION(imap_get_quota);
 PHP_FUNCTION(imap_set_quota);
+#endif
 PHP_FUNCTION(imap_subscribe);
 PHP_FUNCTION(imap_unsubscribe);
 PHP_FUNCTION(imap_append);
@@ -162,8 +167,10 

Re: [PHP-CVS] cvs: php4 /ext/imap config.m4 php_imap.c php_imap.h

2001-02-25 Thread Sascha Schumann

On Sun, 25 Feb 2001, Dan Kalowsky wrote:

 kalowsky  Sat Feb 24 20:41:19 2001 EDT

[..]
   Changes the config.m4 to support the client.h include
   # This should include all the approriate headers for c-client (as defined by
   # c-client maintainers) such as mail.h, and rfc822.h.

Well, the problem with this commit is that it breaks
compatibility with older imap releases as they don't have any
c-client.h.  Dan, can you please add a check for c-client.h
and if it does not exist, fall back to the old set of header
files?

- Sascha


-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]