mirror of
https://github.com/php/php-src.git
synced 2024-09-21 09:57:23 +00:00
Enable selective regex library compilation.
This commit is contained in:
parent
6f57224890
commit
ceae3847b8
16
acinclude.m4
16
acinclude.m4
@ -144,6 +144,22 @@ AC_DEFUN(AC_CHECK_CC_OPTION,[
|
||||
fi
|
||||
])
|
||||
|
||||
AC_DEFUN(PHP_HSREGEX,[
|
||||
AC_MSG_CHECKING(whether to use bundled regex library)
|
||||
AC_MSG_RESULT($HSREGEX)
|
||||
|
||||
if test "$HSREGEX" = "yes"; then
|
||||
REGEX_LIB=regex/libregex.la
|
||||
AC_DEFINE(HSREGEX)
|
||||
AC_DEFINE(REGEX,1)
|
||||
else
|
||||
REGEX_LIB=
|
||||
AC_DEFINE(REGEX,0)
|
||||
fi
|
||||
|
||||
AC_SUBST(REGEX_LIB)
|
||||
AC_SUBST(HSREGEX)
|
||||
])
|
||||
|
||||
dnl
|
||||
dnl See if we have broken header files like SunOS has.
|
||||
|
45
configure.in
45
configure.in
@ -386,49 +386,6 @@ AC_ARG_ENABLE(versioning,
|
||||
])
|
||||
AC_MSG_RESULT($RESULT)
|
||||
|
||||
AC_MSG_CHECKING(whether to use bundled regex library)
|
||||
AC_ARG_WITH(system-regex,
|
||||
[ --with-system-regex Do not use the bundled regex library],
|
||||
[
|
||||
if test -n "$APXS"; then
|
||||
if test -n "`$APXS -q CFLAGS | grep USE_HSREGEX`"; then
|
||||
HSREGEX=yes
|
||||
else
|
||||
HSREGEX=no
|
||||
fi
|
||||
else
|
||||
if test "$withval" = "no"; then
|
||||
HSREGEX=yes
|
||||
else
|
||||
HSREGEX=no
|
||||
fi
|
||||
fi
|
||||
],[
|
||||
if test -n "$APXS"; then
|
||||
if test -n "`$APXS -q CFLAGS | grep USE_HSREGEX`"; then
|
||||
HSREGEX=yes
|
||||
else
|
||||
HSREGEX=no
|
||||
fi
|
||||
else
|
||||
HSREGEX=yes
|
||||
fi
|
||||
])
|
||||
AC_MSG_RESULT($HSREGEX)
|
||||
|
||||
if test "$HSREGEX" = "yes"; then
|
||||
REGEX_LIB=regex/libregex.la
|
||||
AC_DEFINE(HSREGEX)
|
||||
AC_DEFINE(REGEX,1)
|
||||
else
|
||||
REGEX_LIB=
|
||||
AC_DEFINE(REGEX,0)
|
||||
fi
|
||||
|
||||
AC_SUBST(REGEX_LIB)
|
||||
AC_SUBST(HSREGEX)
|
||||
|
||||
|
||||
AC_MSG_CHECKING(whether to use a configuration file)
|
||||
AC_ARG_WITH(config-file-path,
|
||||
[ --with-config-file-path=PATH
|
||||
@ -672,6 +629,8 @@ if test "$enable_debug" != "yes"; then
|
||||
AM_SET_LIBTOOL_VARIABLE([--silent])
|
||||
fi
|
||||
|
||||
PHP_HSREGEX
|
||||
|
||||
dnl If we are using gcc and the user has not specified CFLAGS, add -O2.
|
||||
test -n "$auto_cflags" && test -n "$GCC" && CFLAGS="$CFLAGS -O2"
|
||||
|
||||
|
@ -123,6 +123,18 @@ AC_CHECK_FUNCS(getwd)
|
||||
|
||||
divert(3)
|
||||
|
||||
AC_ARG_WITH(system-regex,
|
||||
[ --with-system-regex Do not use the bundled regex library],
|
||||
[
|
||||
if test "$withval" = "no"; then
|
||||
HSREGEX=yes
|
||||
else
|
||||
HSREGEX=no
|
||||
fi
|
||||
],[
|
||||
HSREGEX=yes
|
||||
])
|
||||
|
||||
AC_CRYPT_CAP
|
||||
|
||||
PHP_EXTENSION(standard)
|
||||
|
@ -16,6 +16,11 @@ AC_ARG_WITH(apxs,
|
||||
XML_INCLUDE="$APXS_INCLUDEDIR/xml"
|
||||
fi
|
||||
AC_ADD_INCLUDE($APXS_INCLUDEDIR)
|
||||
if test -n "`$APXS -q CFLAGS | grep USE_HSREGEX`"; then
|
||||
HSREGEX=yes
|
||||
else
|
||||
HSREGEX=no
|
||||
fi
|
||||
PHP_EXTENSION(apache)
|
||||
PHP_SAPI=apache
|
||||
APACHE_INSTALL="$APXS -i -a -n php4 $SAPI_SHARED"
|
||||
@ -173,6 +178,7 @@ AC_ARG_WITH(mod_charset,
|
||||
])
|
||||
|
||||
if test -n "$APACHE_MODULE"; then
|
||||
HSREGEX=no
|
||||
PHP_EXTENSION(apache)
|
||||
PHP_OUTPUT(sapi/apache/libphp4.module)
|
||||
PHP_BUILD_STATIC
|
||||
|
Loading…
Reference in New Issue
Block a user