|
|
|
@ -2560,28 +2560,50 @@ EOF |
|
|
|
]) |
|
|
|
|
|
|
|
dnl |
|
|
|
dnl PHP_REGEX |
|
|
|
dnl |
|
|
|
AC_DEFUN([PHP_REGEX],[ |
|
|
|
if test "$REGEX_TYPE" = "php"; then |
|
|
|
AC_DEFINE(HAVE_REGEX_T_RE_MAGIC, 1, [ ]) |
|
|
|
AC_DEFINE(HSREGEX,1,[ ]) |
|
|
|
AC_DEFINE(REGEX,1,[ ]) |
|
|
|
PHP_ADD_SOURCES(regex, regcomp.c regexec.c regerror.c regfree.c) |
|
|
|
elif test "$REGEX_TYPE" = "system"; then |
|
|
|
AC_DEFINE(REGEX,0,[ ]) |
|
|
|
dnl Check if field re_magic exists in struct regex_t |
|
|
|
AC_CACHE_CHECK([whether field re_magic exists in struct regex_t], ac_cv_regex_t_re_magic, [ |
|
|
|
AC_TRY_COMPILE([#include <sys/types.h> |
|
|
|
#include <regex.h>], [regex_t rt; rt.re_magic;], |
|
|
|
[ac_cv_regex_t_re_magic=yes], [ac_cv_regex_t_re_magic=no]) |
|
|
|
]) |
|
|
|
if test "$ac_cv_regex_t_re_magic" = "yes"; then |
|
|
|
AC_DEFINE([HAVE_REGEX_T_RE_MAGIC], [ ], 1) |
|
|
|
fi |
|
|
|
fi |
|
|
|
AC_MSG_CHECKING([which regex library to use]) |
|
|
|
AC_MSG_RESULT([$REGEX_TYPE]) |
|
|
|
dnl PHP_CHECK_CONFIGURE_OPTIONS |
|
|
|
dnl |
|
|
|
AC_DEFUN([PHP_CHECK_CONFIGURE_OPTIONS],[ |
|
|
|
for arg in $ac_configure_args; do |
|
|
|
case $arg in |
|
|
|
--with-*[)] |
|
|
|
arg_name="`echo [$]arg | $SED -e 's/--with-//g' -e 's/=.*//g'`" |
|
|
|
;; |
|
|
|
--without-*[)] |
|
|
|
arg_name="`echo [$]arg | $SED -e 's/--without-//g' -e 's/=.*//g'`" |
|
|
|
;; |
|
|
|
--enable-*[)] |
|
|
|
arg_name="`echo [$]arg | $SED -e 's/--enable-//g' -e 's/=.*//g'`" |
|
|
|
;; |
|
|
|
--disable-*[)] |
|
|
|
arg_name="`echo [$]arg | $SED -e 's/--disable-//g' -e 's/=.*//g'`" |
|
|
|
;; |
|
|
|
*[)] |
|
|
|
continue |
|
|
|
;; |
|
|
|
esac |
|
|
|
case $arg_name in |
|
|
|
# Allow --disable-all / --enable-all |
|
|
|
all[)];; |
|
|
|
|
|
|
|
# Allow certain libtool options |
|
|
|
libtool-lock | pic | tags | shared | static | fast-install | gnu-ld[)];; |
|
|
|
|
|
|
|
# Allow certain TSRM options |
|
|
|
tsrm-pth | tsrm-st | tsrm-pthreads[)];; |
|
|
|
|
|
|
|
# Allow certain Zend options |
|
|
|
zend-vm | maintainer-zts | inline-optimization | zend-multibyte[)];; |
|
|
|
|
|
|
|
# All the rest must be set using the PHP_ARG_* macros |
|
|
|
*[)] |
|
|
|
is_arg_set=PHP_[]`echo [$]arg_name | tr 'abcdefghijklmnopqrstuvwxyz-' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` |
|
|
|
if eval test -z "\$$is_arg_set"; then |
|
|
|
PHP_UNKNOWN_CONFIGURE_OPTIONS="$PHP_UNKNOWN_CONFIGURE_OPTIONS |
|
|
|
[$]arg" |
|
|
|
fi |
|
|
|
;; |
|
|
|
esac |
|
|
|
done |
|
|
|
]) |
|
|
|
|
|
|
|
dnl |
|
|
|
|