]> granicus.if.org Git - php/commitdiff
- Fixed bug #35735 ($EGREP and $SED are not defined in configure)
authorfoobar <sniper@php.net>
Mon, 19 Dec 2005 22:29:12 +0000 (22:29 +0000)
committerfoobar <sniper@php.net>
Mon, 19 Dec 2005 22:29:12 +0000 (22:29 +0000)
NEWS
acinclude.m4
build/libtool.m4

diff --git a/NEWS b/NEWS
index 36da8f351c3df86b24fb3a59efa4c03d2390cdcf..3dcf567ff166ae5d7de9be677b8d729df8e3535e 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,7 @@ PHP 4                                                                      NEWS
 ?? ??? 2005, Version 4.4.2
 - Prevent header injection by limiting each header to a single line. (Ilia)
 - Fixed possible XSS inside error reporting functionality. (Ilia)
+- Fixed bug #35735 ($EGREP not defined in configure). (Jani)
 - Fixed bug #35655 (whitespace following end of heredoc is lost). (Ilia)
 - Fixed bug #35646 (%{mod_php_memory_usage}n is not reset after exit). 
   (vovik at getart dot ru, Tony)
index 3ef9c706f4ea46d202c243e672cee47dfe172cf8..5354a1bf446931187d708612b1217aaa94f02ca9 100644 (file)
@@ -548,6 +548,10 @@ AC_DEFUN([PHP_MODULE_PTR],[
 ])
  
 AC_DEFUN([PHP_CONFIG_NICE],[
+  AC_REQUIRE([AC_PROG_EGREP])
+  AC_REQUIRE([LT_AC_PROG_SED])
+  PHP_SUBST(EGREP)
+  PHP_SUBST(SED)
   test -f $1 && mv $1 $1.old
   rm -f $1.old
   cat >$1<<EOF
index 41adb2b9e7407c74ac2a67fc674c8e50b326f9fd..ced39b46dbde0489ced36a08342c52d2604579ba 100644 (file)
@@ -3138,6 +3138,21 @@ AC_DEFUN([AC_LIBTOOL_PICMODE],
 pic_mode=ifelse($#,1,$1,default)])
 
 
+# AC_PROG_EGREP
+# -------------
+# This is predefined starting with Autoconf 2.54, so this conditional
+# definition can be removed once we require Autoconf 2.54 or later.
+ifdef([AC_PROG_EGREP], [], [AC_DEFUN([AC_PROG_EGREP],
+[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
+   [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
+    then ac_cv_prog_egrep='grep -E'
+    else ac_cv_prog_egrep='egrep'
+    fi])
+ EGREP=$ac_cv_prog_egrep
+ AC_SUBST([EGREP])
+])])
+
+
 # AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library
 AC_DEFUN([AC_PATH_TOOL_PREFIX],
 [AC_MSG_CHECKING([for $1])