MFH: - Fixed bug #31858 (--disable-cli does not force --without-pear)
authorfoobar <sniper@php.net>
Mon, 7 Feb 2005 12:51:52 +0000 (12:51 +0000)
committerfoobar <sniper@php.net>
Mon, 7 Feb 2005 12:51:52 +0000 (12:51 +0000)
NEWS
configure.in

diff --git a/NEWS b/NEWS
index b0181505a7e1dbaf93e7175c33f25762d179c573..a7a43ee30d5a2da4747ce8987caf1f7aa9354697 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -6,6 +6,7 @@ PHP 4                                                                      NEWS
 - Fixed several egregious leaks in ext/browscap and sapi/embed. (Andrei)
 - Fixed build system to always use bundled libtool files. (Jani)  
 - Fixed MacOSX shared extensions crashing on Apache startup. (Rasmus)
+- Fixed bug #31858 (--disable-cli does not force --without-pear). (Jani)
 - Fixed bug #31842 (*date('r') does not return RFC2822 conforming date string).
   (Jani)
 - Fixed bug #31797 (exif_read_data() uses too low nesting limit). (Ilia)
index d3ddcc33c3bface4c2d531e3c2557825360d7889..df1f5d22204e9fbf3949bab570a1f78630891129 100644 (file)
@@ -872,6 +872,11 @@ if test -z "$with_pear" && test "$enable_pear" = "no"; then
   with_pear=no
 fi
 
+# If CLI is disabled -> disable PEAR
+if test "$PHP_SAPI_CLI" = "no"; then
+  with_pear=no
+fi
+
 PHP_ARG_WITH(pear, [whether to install PEAR],
 [  --with-pear=DIR         Install PEAR in DIR (default PREFIX/lib/php)
   --without-pear          Do not install PEAR], DEFAULT, yes)
@@ -881,17 +886,13 @@ if test "$PHP_PEAR" != "no"; then
   dnl
   dnl PEAR dependancies
   dnl
-  if test "$PHP_SAPI_CLI" = "no"; then
-    pear_error_msg="$pear_error_msg 
-                    PEAR requires CLI to be enabled.     Add --enable-cli to the configure line. (or --disable-pear)"
-  fi
   if test "$PHP_PCRE_REGEX" = "no"; then
     pear_error_msg="$pear_error_msg 
-                    PEAR requires PCRE to be enabled.    Add --with-pcre-regex to the configure line. (or --disable-pear)"
+                    PEAR requires PCRE to be enabled.    Add --with-pcre-regex to the configure line. (or --without-pear)"
   fi
   if test "$PHP_XML" = "no"; then
     pear_error_msg="$pear_error_msg 
-                    PEAR requires XML to be enabled.     Add --enable-xml to the configure line. (or --disable-pear)"
+                    PEAR requires XML to be enabled.     Add --enable-xml to the configure line. (or --without-pear)"
   fi
 
 dnl
@@ -899,7 +900,7 @@ dnl ext/xmlrpc is not really there yet to be a requirement..
 dnl
 dnl  if test "$PHP_XMLRPC" = "no"; then
 dnl    pear_error_msg="$pear_error_msg 
-dnl                    PEAR requires XML-RPC to be enabled. Add --with-xmlrpc to the configure line. (or --disable-pear)"
+dnl                    PEAR requires XML-RPC to be enabled. Add --with-xmlrpc to the configure line. (or --without-pear)"
 dnl fi
 dnl
 
@@ -916,6 +917,8 @@ dnl
       *)   PEAR_INSTALLDIR=$libdir/php;;
     esac
   fi
+
+  PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/pear/Makefile.frag,$abs_srcdir/pear,pear)
 fi
 
 
@@ -1259,7 +1262,6 @@ PHP_ADD_BUILD_DIR(TSRM)
 PHP_ADD_BUILD_DIR(Zend)
 
 PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/scripts/Makefile.frag,$abs_srcdir/scripts,scripts)
-PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/pear/Makefile.frag,$abs_srcdir/pear,pear)
 PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/Makefile.frag,$abs_srcdir/Zend,Zend)
 
 PHP_GEN_BUILD_DIRS