[PHP-CVS] changes

2001-04-11 Thread Boian Bonev

> What are we doing with the current release right now?
> who is having problems and which problems are outstanding??

hi,

a single compiler warning issue - in ext/standard/exec.h there must be a
declaration of php_Exec:

int php_Exec(int type, char *cmd, pval *array, pval *return_value);

it is used by the vpopmail module which works ok even without it but more
strict compilers may complain bad on this.

i think this will not break anything and will be ok if added to 4.0.5

b.


-- 
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/vpopmail php_vpopmail.c

2001-02-08 Thread Boian Bonev

bbonev  Thu Feb  8 15:31:00 2001 EDT

  Modified files:  
/php4/ext/vpopmail  php_vpopmail.c 
  Log:
  fixed SIGSEGV in vpopmail_auth_user when optional arg apop is not set
  
  
Index: php4/ext/vpopmail/php_vpopmail.c
diff -u php4/ext/vpopmail/php_vpopmail.c:1.7 php4/ext/vpopmail/php_vpopmail.c:1.8
--- php4/ext/vpopmail/php_vpopmail.c:1.7Wed Feb  7 09:47:59 2001
+++ php4/ext/vpopmail/php_vpopmail.cThu Feb  8 15:31:00 2001
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_vpopmail.c,v 1.7 2001/02/07 17:47:59 bbonev Exp $ */
+/* $Id: php_vpopmail.c,v 1.8 2001/02/08 23:31:00 bbonev Exp $ */
 
 /* TODO: move to config.m4 when support for old versions is ready or just
  * don't support rather old vpopmail. current version must bail out if
@@ -694,12 +694,13 @@
zval **password;
zval **apop;
struct passwd *retval;
+   int argc=ZEND_NUM_ARGS();
 
-   if (ZEND_NUM_ARGS() < 3 || ZEND_NUM_ARGS() > 4
+   if (argc < 3 || argc > 4
|| zend_get_parameters_ex(ZEND_NUM_ARGS(), &user, &domain, 
&password, &apop) == FAILURE)
WRONG_PARAM_COUNT;
 
-   if (ZEND_NUM_ARGS() > 3)
+   if (argc > 3)
convert_to_string_ex(apop);
 
convert_to_string_ex(user);
@@ -713,7 +714,7 @@
retval = vauth_user(Z_STRVAL_PP(user),
Z_STRVAL_PP(domain),
Z_STRVAL_PP(password),
-   Z_STRVAL_PP(apop));
+   (argc>3)?Z_STRVAL_PP(apop):"");
 
/* 
 * we do not set vpopmail_errno here - it is considered auth_user cannot fail; 
insted it does not auth



-- 
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/vpopmail php_vpopmail.c

2001-02-07 Thread Boian Bonev

bbonev  Wed Feb  7 09:47:59 2001 EDT

  Modified files:  
/php4/ext/vpopmail  php_vpopmail.c 
  Log:
  # fixed several warnings - variables not used, functions not declared
  # added vclose() declaration - vpopmail does not declare it
  
  
Index: php4/ext/vpopmail/php_vpopmail.c
diff -u php4/ext/vpopmail/php_vpopmail.c:1.6 php4/ext/vpopmail/php_vpopmail.c:1.7
--- php4/ext/vpopmail/php_vpopmail.c:1.6Fri Jan 26 16:25:08 2001
+++ php4/ext/vpopmail/php_vpopmail.cWed Feb  7 09:47:59 2001
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_vpopmail.c,v 1.6 2001/01/27 00:25:08 bbonev Exp $ */
+/* $Id: php_vpopmail.c,v 1.7 2001/02/07 17:47:59 bbonev Exp $ */
 
 /* TODO: move to config.m4 when support for old versions is ready or just
  * don't support rather old vpopmail. current version must bail out if
@@ -37,6 +37,7 @@
 #include "vpopmail.h"
 
 #include "ext/standard/exec.h"
+#include "ext/standard/info.h"
 #include "ext/standard/php_string.h"
 
 ZEND_DECLARE_MODULE_GLOBALS(vpopmail)
@@ -117,6 +118,10 @@
return SUCCESS;
 }
 
+/* nasty but... */
+void vclose();
+/* ...we need this */
+
 PHP_RSHUTDOWN_FUNCTION(vpopmail)
 {
VPOPMAILLS_FETCH();
@@ -234,7 +239,6 @@
char TmpBuf1[300];
char TmpBuf2[300];
int uid, gid;
-   int retval;
 
if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &domain, &aliasdomain) 
== FAILURE)
WRONG_PARAM_COUNT;
@@ -289,9 +293,9 @@
Add a new virtual domain */
 PHP_FUNCTION(vpopmail_add_domain_ex) {
zval **domain, **passwd, **quota, **bounce, **apop;
-   int 
retval,len=0,argc=ZEND_NUM_ARGS(),Uid=VPOPMAILUID,Gid=VPOPMAILGID,is_bounce_email;
+   int retval,len=0,argc=ZEND_NUM_ARGS(),is_bounce_email;
int fr_bounce=0,fr_quota=0;
-   char 
*q,*bo,*cmd,*escdomain="",*escpasswd="",*escquota="",*escbounce="",*escapop="";
+   char *cmd,*escdomain="",*escpasswd="",*escquota="",*escbounce="",*escapop="";
 
if (argc < 2 || argc > 5 || zend_get_parameters_ex(argc, &domain, &passwd, 
"a, &bounce, &apop) == FAILURE){
WRONG_PARAM_COUNT;



-- 
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]




Re: [PHP-CVS] cvs: php4 /ext/sockets sockets.c

2001-02-03 Thread Boian Bonev

hi,


> > What do you mean, switch() is expensive?
> Well, isn't it slower?

perhapse in php switch is slower. in c it sometimes is much faster than
bunch of if statements. i mean the compiler makes jump tables for
consequitive values and there are less comparisons etc. just a range check
and jump.

b.


-- 
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/vpopmail php_vpopmail.c

2001-01-26 Thread Boian Bonev

bbonev  Fri Jan 26 16:25:09 2001 EDT

  Modified files:  
/php4/ext/vpopmail  php_vpopmail.c 
  Log:
  # fixed protos in comments for *_ex functions
  
Index: php4/ext/vpopmail/php_vpopmail.c
diff -u php4/ext/vpopmail/php_vpopmail.c:1.5 php4/ext/vpopmail/php_vpopmail.c:1.6
--- php4/ext/vpopmail/php_vpopmail.c:1.5Tue Jan 23 13:46:03 2001
+++ php4/ext/vpopmail/php_vpopmail.cFri Jan 26 16:25:08 2001
@@ -17,7 +17,7 @@
+--+
 */
 
-/* $Id: php_vpopmail.c,v 1.5 2001/01/23 21:46:03 bbonev Exp $ */
+/* $Id: php_vpopmail.c,v 1.6 2001/01/27 00:25:08 bbonev Exp $ */
 
 /* TODO: move to config.m4 when support for old versions is ready or just
  * don't support rather old vpopmail. current version must bail out if
@@ -285,7 +285,7 @@
  * Domain management functions - exec
  */
 
-/* {{{ proto int vpopmail_add_domain_ex(string domain, string passwd [, string quota 
[, string bounce [, bool apop]]])
+/* {{{ proto bool vpopmail_add_domain_ex(string domain, string passwd [, string quota 
+[, string bounce [, bool apop]]])
Add a new virtual domain */
 PHP_FUNCTION(vpopmail_add_domain_ex) {
zval **domain, **passwd, **quota, **bounce, **apop;
@@ -411,7 +411,7 @@
 }
 /* }}} */
 
-/* {{{ proto int vpopmail_del_domain_ex(string domain)
+/* {{{ proto bool vpopmail_del_domain_ex(string domain)
Delete a virtual domain */
 PHP_FUNCTION(vpopmail_del_domain_ex) {
zval **domain;
@@ -455,7 +455,7 @@
 }
 /* }}} */
 
-/* {{{ proto int vpopmail_add_alias_domain_ex(string olddomain, string newdomain)
+/* {{{ proto bool vpopmail_add_alias_domain_ex(string olddomain, string newdomain)
Add alias to an existing virtual domain */
 PHP_FUNCTION(vpopmail_add_alias_domain_ex) {
zval **olddomain, **newdomain;



-- 
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/vpopmail CREDITS README config.m4 php_vpopmail.c php_vpopmail.h

2001-01-23 Thread Boian Bonev

bbonev  Tue Jan 23 13:46:08 2001 EDT

  Modified files:  
/php4/ext/vpopmail  CREDITS README config.m4 php_vpopmail.c 
php_vpopmail.h 
  Log:
  changed function names to be like vpopmail_add_user instead vpopmail_adduser
  added vpopmail_error to report error string (vpopmail_errno global var)
  put exec functions back in with _ex (vpopmail_add_domain_ex)
  rewritten README to help users keep secure
  fixed protos to state bool instead void return type
  
  

Index: php4/ext/vpopmail/CREDITS
diff -u php4/ext/vpopmail/CREDITS:1.2 php4/ext/vpopmail/CREDITS:1.3
--- php4/ext/vpopmail/CREDITS:1.2   Sun Jan 14 08:47:55 2001
+++ php4/ext/vpopmail/CREDITS   Tue Jan 23 13:46:03 2001
@@ -1,3 +1,2 @@
 Vpopmail
-David Croft
-Boian Bonev
+David Croft, Boian Bonev
Index: php4/ext/vpopmail/README
diff -u php4/ext/vpopmail/README:1.1 php4/ext/vpopmail/README:1.2
--- php4/ext/vpopmail/README:1.1Sun Jan 14 09:38:29 2001
+++ php4/ext/vpopmail/READMETue Jan 23 13:46:03 2001
@@ -1,63 +1,173 @@
 Minimum Survial Readme
 
-1) select a uid and gid apache to run under
-   or if this is already fixed take it into account
+VPOPMAIL SPECIFIC ISSUES
+---
 
-2) install vpopmail with EXACTLY the same uid gid
-   in case you already have installed vpopmail
-   you have two choices - to change apache's 
-   uid/gid but be careful - this may break some 
-   existing scripts or worse your server's security
+assume
+   qmail is installed in /var/qmail
+   vpopmail in ~vpopmail
+   qmail-send runs as qmails
 
-   changing existing vpopmail uid/gid is possible
-   but not easy - take these into account:
 
-   #1 - backup your setup!
+different parts of vpopmail require certain user id (uid) and
+group id (gid) in order to operate normally.
 
-   stop qmail-send before doing any changes
-   else your mail in process may get bounced or 
-   deleted or delivered to a default destination or...
+brief list with requirements:
 
-   stop pop3/imap remote users - while changing uids
-   users cannot check their mail
+adddomain
+deldomain
+addaliasdomain
+   read/write permissions on
+   /var/qmail/users/ assing, assign.lock, cdb
 
-   you may leave smtp - qmail-inject will take care
-   no matter vpopmail setup is broken (if and only
-   if you have stopped qmail-send)
+   read/write permissions on
+   /var/qmail/control/*
 
-   rc.d scrips tcpserver uid/gid may need to be changed
+   singnal qmail-send with SIGHUP (uid==qmails or root)
 
-   remember to
-   ./configure opts
-   make clean all install
-   in vpopmail src tree
+   read/write permissions on
+   ~vpopmail/domains
 
-   after these steps change the uid/gid in
-   /var/qmail/users/assign
-   compile the assign file. the dummies way is to
-   vadddomain mydummy.domain 
-   vdeldomain mydummy.domain
+   optionally read/write to cdb vpopmail databases
 
-   suid root vadddomain, vdeldomain and vaddaliasdomain
-   cd ~vpopmail/bin
-   chown 0.0 vadddomain vdeldomain vaddaliasdomain
-   chmod +s vadddomain vdeldomain vaddaliasdomain
-   beware these programs may be exploitable and if
-   neccessary chmod 700 ~vpopmail/bin
+adduser
+deluser
+   read/write permissions on
+   ~vpopmail/domains/ (or the default domain)
 
-   run qmail-send (/bin/csh -cf '/var/qmail/rc &')
-   run pop3 tcpserver or what you are using
+   optionally read/write to cdb vpopmail databases
 
-   verify your setup
+passwd
+   optionally read/write on
+   ~vpopmail/domains//
+   (only when sqwebmail is configured)
 
-3) check that vpopmail support is compiled into apache
-   throug a simple phpinfo. there some more info helpful
-   for debugging will appear
+setuserquota
+   optionally read/write to cdb vpopmail databases
 
-4) happy vpopmail-ing :-)
+auth_user
+   optionally read from cdb vpopmail databases
 
+POSSIBLE SCENARIOS
+---
+
+php is in cgi mode
+
+   command line invocation
+
+   web server cgi invocation
+
+php is web server module
+
+
+in command line mode the php interpreter may be run from vpopmail uid to
+administer users, etc. or as root to add/del domains - this is the easiest case
+
+in cgi mode proper uid may be provided eighter by suid php interpreter or
+using cgi exec wrapper. the same restrictions as in command line mode apply
+
+the web server module mode is the most powerful and works much faster that cgi.
+in this mode more restrictions apply because web server's uid at least must
+be able to read/write the directories of the manages domains.
+
+first scenario only allows web scripts to manage certain domains.  security 
+may be compromised if there are user webs under the same web server
+with allowed script execution.
+
+second scenar

[PHP-CVS] cvs: php4 /ext/vpopmail README

2001-01-14 Thread Boian Bonev

bbonev  Sun Jan 14 09:38:29 2001 EDT

  Added files: 
/php4/ext/vpopmail  README 
  Log:
  #added simple minimum survival readme
  



-- 
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/vpopmail php_vpopmail.c php_vpopmail.h

2001-01-14 Thread Boian Bonev

bbonev  Sun Jan 14 09:04:22 2001 EDT

  Modified files:  
/php4/ext/vpopmail  php_vpopmail.c php_vpopmail.h 
  Log:
  merged my version with David Croft's
  removed unneccessary php.ini calls and defines
  removed module_init, shutdown, request_init declarations and references
  added request_shutdown to close mysql/other db connection
(a must in apache module)
  added defines for external binaries from vpopmail
  changed functions to present more consistent api from user's point of view
so that in one call more stuff is done
  added more comprehensive MINFO function helping users debug their case
  added static int vpopmail_exec(char *cmd) [will change to php_Exec soon]
  @ vpopmail extension updated to working alfa. give it a try but keep in 
  @ mind that it is not ready for production environments (Boian Bonev)
  
  

Index: php4/ext/vpopmail/php_vpopmail.c
diff -u php4/ext/vpopmail/php_vpopmail.c:1.2 php4/ext/vpopmail/php_vpopmail.c:1.3
--- php4/ext/vpopmail/php_vpopmail.c:1.2Sun Jan 14 01:01:25 2001
+++ php4/ext/vpopmail/php_vpopmail.cSun Jan 14 09:04:21 2001
@@ -12,48 +12,71 @@
| obtain it through the world-wide-web, please send a note to  |
| [EMAIL PROTECTED] so we can mail you a copy immediately.   |
+--+
-   | Author: David Croft <[EMAIL PROTECTED]>   |
+   | Authors: David Croft <[EMAIL PROTECTED]>  |
+   |  Boian Bonev <[EMAIL PROTECTED]>   |
+--+
 */
 
-/* $Id: php_vpopmail.c,v 1.2 2001/01/14 09:01:25 david Exp $ */
+/* $Id: php_vpopmail.c,v 1.3 2001/01/14 17:04:21 bbonev Exp $ */
 
-#undef VPOPMAIL_IS_REALLY_OLD
+// TODO: move to config.m4 when support for old versions is ready or just don't 
+support rather old vpopmail
+// current version must bail out if incompat option is specified and work for minimal 
+params
+//#undef VPOPMAIL_IS_REALLY_OLD
 
 #include "php.h"
 #include "php_ini.h"
 #include "php_vpopmail.h"
 
+#if HAVE_SYS_WAIT_H
+#include 
+#endif
+
+#if HAVE_VPOPMAIL
+
 #include "vpopmail.h"
 
+#include "ext/standard/exec.h"
 #include "ext/standard/php_string.h"
 
-#ifdef ZTS
-int vpopmail_globals_id;
-#else
-php_vpopmail_globals vpopmail_globals;
-#endif
+// keep this as the last include in order to destroy VERSION/PACKAGE only for the 
+rest of the code
+#undef VERSION
+#undef PACKAGE
+#include "vpopmail_config.h"
+#undef PACKAGE
+#include "vpopmail.h"
 
+// vpopmail does not export this, argh!
+#define MAX_BUFF 500
+
+#define VPOPSTR(x) #x
+
+/* removed by intent - will add when need to
+ZEND_DECLARE_MODULE_GLOBALS(vpop)
+*/
+
 /* Function table */
 
 function_entry vpopmail_functions[] = {
-   PHP_FE(vpopmail_auth_user, NULL)
+   // domain management
PHP_FE(vpopmail_adddomain, NULL)
PHP_FE(vpopmail_deldomain, NULL)
+   PHP_FE(vpopmail_addaliasdomain, NULL)
+   // user management
PHP_FE(vpopmail_adduser, NULL)
PHP_FE(vpopmail_deluser, NULL)
PHP_FE(vpopmail_passwd, NULL)
PHP_FE(vpopmail_setuserquota, NULL)
+   PHP_FE(vpopmail_auth_user, NULL)
{NULL, NULL, NULL}
 };
 
 zend_module_entry vpopmail_module_entry = {
"vpopmail",
vpopmail_functions,
-   PHP_MINIT(vpopmail),
-   PHP_MSHUTDOWN(vpopmail),
-   NULL,
-   NULL,
+   NULL, //PHP_MINIT(vpopmail),// do nothing upon
+   NULL, //PHP_MSHUTDOWN(vpopmail),//  these
+   NULL, //PHP_RINIT(vpopmail),//  events
+   PHP_RSHUTDOWN(vpopmail),// close vpopmail lib upon request 
+shutdown
PHP_MINFO(vpopmail),
STANDARD_MODULE_PROPERTIES
 };
@@ -62,276 +85,429 @@
 ZEND_GET_MODULE(vpopmail)
 #endif
 
+// removed by intent - will add when needed
+//PHP_INI_BEGIN()
+/* STD_PHP_INI_ENTRY("pfpro.proxypassword","",
+ PHP_INI_ALL, OnUpdateString,proxypassword,  
+php_pfpro_globals,  pfpro_globals) */
+//PHP_INI_END()
 
-PHP_INI_BEGIN()
-   /*  STD_PHP_INI_ENTRY("pfpro.proxypassword","",
 PHP_INI_ALL, OnUpdateString,proxypassword,  
php_pfpro_globals,  pfpro_globals) */
-PHP_INI_END()
 
-
-PHP_MINIT_FUNCTION(vpopmail)
-{
+// removed by intent - will add when needed
+/*PHP_MINIT_FUNCTION(vpopmail) {
REGISTER_INI_ENTRIES();
return SUCCESS;
-}
+}*/
 
-PHP_MSHUTDOWN_FUNCTION(vpopmail)
+// removed by intent - will add when needed
+/*PHP_MSHUTDOWN_FUNCTION(vpopmail)
 {
UNREGISTER_INI_ENTRIES();
return SUCCESS;

[PHP-CVS] cvs: php4 /ext/vpopmail CREDITS

2001-01-14 Thread Boian Bonev

bbonev  Sun Jan 14 08:47:56 2001 EDT

  Modified files:  
/php4/ext/vpopmail  CREDITS 
  Log:
  updated
  
Index: php4/ext/vpopmail/CREDITS
diff -u php4/ext/vpopmail/CREDITS:1.1 php4/ext/vpopmail/CREDITS:1.2
--- php4/ext/vpopmail/CREDITS:1.1   Sun Jan 14 00:54:00 2001
+++ php4/ext/vpopmail/CREDITS   Sun Jan 14 08:47:55 2001
@@ -1,2 +1,3 @@
 Vpopmail
 David Croft
+Boian Bonev



-- 
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/vpopmail config.m4

2001-01-14 Thread Boian Bonev

bbonev  Sun Jan 14 08:40:26 2001 EDT

  Modified files:  
/php4/ext/vpopmail  config.m4 
  Log:
  rewritten the whole logic of the script
  added VPOPMAIL_BIN_DIR to point to ~vpopmail/bin directory
  added checks for ALL files needed by the extension
  style fixes to the output
  
  
Index: php4/ext/vpopmail/config.m4
diff -u php4/ext/vpopmail/config.m4:1.1 php4/ext/vpopmail/config.m4:1.2
--- php4/ext/vpopmail/config.m4:1.1 Sun Jan 14 00:54:00 2001
+++ php4/ext/vpopmail/config.m4 Sun Jan 14 08:40:25 2001
@@ -1,45 +1,50 @@
-dnl $Id: config.m4,v 1.1 2001/01/14 08:54:00 david Exp $
+dnl $Id: config.m4,v 1.2 2001/01/14 16:40:25 bbonev Exp $
 dnl config.m4 for extension vpopmail
 
-PHP_ARG_WITH(vpopmail, whether to include vpopmail support,
-[  --with-vpopmail[=DIR]  Include vpopmail support])
+PHP_ARG_WITH(vpopmail, for vpopmail support,
+[  --with-vpopmail[=DIR]   Include vpopmail support.])
 
 if test "$PHP_VPOPMAIL" != "no"; then
+   AC_MSG_CHECKING(for vpopmail install directory)
+   for i in ~vpopmail /home/vpopmail /home/popmail /var/qmail/vpopmail 
+/var/qmail/popmail $PHP_VPOPMAIL; do
+   if test -r $i/vpopmail.h; then
+   VPOPMAIL_INC_DIR=$i
+   VPOPMAIL_DIR=$i
+   elif test -r $i/include/vpopmail.h; then
+   VPOPMAIL_INC_DIR=$i/include
+   VPOPMAIL_DIR=$i
+   fi
+
+   if test -r $i/libvpopmail.a; then
+   VPOPMAIL_LIB_DIR=$i
+   elif test -r $i/lib/libvpopmail.a; then
+   VPOPMAIL_LIB_DIR=$i/lib
+   fi
+
+   if test -r $i/vadddomain; then
+   VPOPMAIL_BIN_DIR=$i
+   elif test -r $i/bin/vadddomain; then
+   VPOPMAIL_BIN_DIR=$i/bin
+   fi
+   done
+
+   for i in "$VPOPMAIL_INC_DIR/vpopmail.h" "$VPOPMAIL_INC_DIR/vpopmail_config.h" 
+"$VPOPMAIL_LIB_DIR/libvpopmail.a" "$VPOPMAIL_BIN_DIR/vadddomain" 
+"$VPOPMAIL_BIN_DIR/vaddaliasdomain" "$VPOPMAIL_BIN_DIR/vdeldomain" ; do
+   if test ! -r "$i"; then
+   AC_MSG_ERROR(Could not find '$i'. Please make sure you have
+   vpopmail installed. Use
+   ./configure --with-vpopmail= if 
+necessary)
+   fi
+   done
+
+   AC_MSG_RESULT($VPOPMAIL_DIR)
+
+   AC_ADD_INCLUDE($VPOPMAIL_INC_DIR)
 
-  for i in /home/vpopmail /home/popmail /var/qmail/vpopmail /var/qmail/popmail 
$PHP_VPOPMAIL; do
-if test -r $i/vpopmail.h; then
-  VPOPMAIL_INC_DIR=$i
-elif test -r $i/include/vpopmail.h; then
-  VPOPMAIL_INC_DIR=$i/include
-fi
-
-if test -r $i/libvpopmail.a; then
-  VPOPMAIL_LIB_DIR=$i
-elif test -r $i/lib/libvpopmail.a; then
-  VPOPMAIL_LIB_DIR=$i/lib
-fi
-  done
-
-  if test -z "$VPOPMAIL_INC_DIR"; then
-AC_MSG_ERROR(Could not find vpopmail.h. Please make sure you have
- vpopmail installed. Use
- ./configure --with-vpopmail= if necessary)
-  fi
-
-  if test -z "$VPOPMAIL_LIB_DIR"; then
-AC_MSG_ERROR(Could not find libvpopmail.a. Please make sure you have
- vpopmail installed. Use
- ./configure --with-vpopmail= if necessary)
-  fi
-
-  AC_MSG_RESULT(found in $VPOPMAIL_LIB_DIR)
+   PHP_SUBST(VPOPMAIL_SHARED_LIBADD)
+   AC_ADD_LIBRARY_WITH_PATH(vpopmail, $VPOPMAIL_LIB_DIR, VPOPMAIL_SHARED_LIBADD)
 
-  AC_ADD_INCLUDE($VPOPMAIL_INC_DIR)
+   AC_DEFINE(HAVE_VPOPMAIL,1,[Whether you have vpopmail])
+   AC_DEFINE_UNQUOTED(VPOPMAIL_BIN_DIR,"$VPOPMAIL_BIN_DIR",[vpopmail bin path])
 
-  PHP_SUBST(VPOPMAIL_SHARED_LIBADD)
-  AC_ADD_LIBRARY_WITH_PATH(vpopmail, $VPOPMAIL_LIB_DIR, VPOPMAIL_SHARED_LIBADD)
-
-  AC_DEFINE(HAVE_VPOPMAIL, 1, [ ])
-
-  PHP_EXTENSION(vpopmail, $ext_shared)
+   PHP_EXTENSION(vpopmail, $ext_shared)
 fi



-- 
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]