Merge branch 'PHP-7.4'

* PHP-7.4:
  Normalize comments in *nix build system m4 files
This commit is contained in:
Peter Kokot 2019-05-12 18:51:50 +02:00
commit 2cf90bb2f0
83 changed files with 557 additions and 693 deletions

View file

@ -28,7 +28,7 @@ dnl OF THE POSSIBILITY OF SUCH DAMAGE.
dnl dnl
dnl PTHREADS_FLAGS dnl PTHREADS_FLAGS
dnl dnl
dnl Set some magic defines to achieve POSIX threads conformance dnl Set some magic defines to achieve POSIX threads conformance.
dnl dnl
AC_DEFUN([PTHREADS_FLAGS],[ AC_DEFUN([PTHREADS_FLAGS],[
if test -z "$host_alias" && test -n "$host"; then if test -z "$host_alias" && test -n "$host"; then
@ -52,18 +52,17 @@ AC_DEFUN([PTHREADS_FLAGS],[
PTHREAD_FLAGS=-D_REENTRANT;; PTHREAD_FLAGS=-D_REENTRANT;;
*sco*) *sco*)
PTHREAD_FLAGS=-D_REENTRANT;; PTHREAD_FLAGS=-D_REENTRANT;;
dnl Solves sigwait() problem, creates problems with u_long etc.
dnl PTHREAD_FLAGS="-D_REENTRANT -D_XOPEN_SOURCE=500 -D_POSIX_C_SOURCE=199506 -D_XOPEN_SOURCE_EXTENDED=1";;
esac esac
if test -n "$PTHREAD_FLAGS"; then if test -n "$PTHREAD_FLAGS"; then
CPPFLAGS="$CPPFLAGS $PTHREAD_FLAGS" CPPFLAGS="$CPPFLAGS $PTHREAD_FLAGS"
fi fi
])dnl ])
dnl dnl
dnl PTHREADS_CHECK_COMPILE dnl PTHREADS_CHECK_COMPILE
dnl dnl
dnl Check whether the current setup can use POSIX threads calls dnl Check whether the current setup can use POSIX threads calls.
dnl dnl
AC_DEFUN([PTHREADS_CHECK_COMPILE], [ AC_DEFUN([PTHREADS_CHECK_COMPILE], [
AC_LINK_IFELSE([ AC_LANG_SOURCE([ AC_LINK_IFELSE([ AC_LANG_SOURCE([
@ -85,11 +84,12 @@ int main() {
], [ ], [
pthreads_checked=no pthreads_checked=no
] ]
) ] )dnl ) ] )
dnl dnl
dnl PTHREADS_CHECK() dnl PTHREADS_CHECK
dnl dnl
dnl Try to find a way to enable POSIX threads dnl Try to find a way to enable POSIX threads.
dnl dnl
dnl Magic flags dnl Magic flags
dnl -kthread gcc (FreeBSD) dnl -kthread gcc (FreeBSD)
@ -102,7 +102,6 @@ dnl -qthreaded AIX cc V5
dnl -threads gcc (HP-UX) dnl -threads gcc (HP-UX)
dnl dnl
AC_DEFUN([PTHREADS_CHECK],[ AC_DEFUN([PTHREADS_CHECK],[
save_CFLAGS=$CFLAGS save_CFLAGS=$CFLAGS
save_LIBS=$LIBS save_LIBS=$LIBS
PTHREADS_ASSIGN_VARS PTHREADS_ASSIGN_VARS
@ -151,8 +150,12 @@ if test "$pthreads_working" = "yes"; then
else else
threads_result="POSIX-Threads not found" threads_result="POSIX-Threads not found"
fi fi
])dnl ])
dnl dnl
dnl PTHREADS_ASSIGN_VARS
dnl
dnl Adds pthreads linker and compiler flags.
dnl dnl
AC_DEFUN([PTHREADS_ASSIGN_VARS],[ AC_DEFUN([PTHREADS_ASSIGN_VARS],[
if test -n "$ac_cv_pthreads_lib"; then if test -n "$ac_cv_pthreads_lib"; then
@ -162,4 +165,4 @@ fi
if test -n "$ac_cv_pthreads_cflags"; then if test -n "$ac_cv_pthreads_cflags"; then
CFLAGS="$CFLAGS $ac_cv_pthreads_cflags" CFLAGS="$CFLAGS $ac_cv_pthreads_cflags"
fi fi
])dnl ])

View file

@ -1,13 +1,19 @@
AC_DEFUN([TSRM_BASIC_CHECKS],[ dnl This file contains TSRM specific autoconf macros.
dnl
dnl TSRM_BASIC_CHECKS
dnl
AC_DEFUN([TSRM_BASIC_CHECKS],[
AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_PROG_RANLIB])dnl AC_REQUIRE([AC_PROG_RANLIB])dnl
AC_CHECK_FUNCS(sigprocmask) AC_CHECK_FUNCS(sigprocmask)
]) ])
dnl
dnl TSRM_CHECK_PTHREADS
dnl
AC_DEFUN([TSRM_CHECK_PTHREADS],[ AC_DEFUN([TSRM_CHECK_PTHREADS],[
PTHREADS_CHECK PTHREADS_CHECK
if test "$pthreads_working" != "yes"; then if test "$pthreads_working" != "yes"; then

View file

@ -1,9 +1,11 @@
dnl dnl This file contains Zend specific autoconf macros.
dnl This file contains Zend specific autoconf functions.
dnl
dnl
dnl ZEND_CHECK_FLOAT_PRECISION
dnl
dnl x87 floating point internal precision control checks dnl x87 floating point internal precision control checks
dnl See: http://wiki.php.net/rfc/rounding dnl See: http://wiki.php.net/rfc/rounding
dnl
AC_DEFUN([ZEND_CHECK_FLOAT_PRECISION],[ AC_DEFUN([ZEND_CHECK_FLOAT_PRECISION],[
AC_MSG_CHECKING([for usable _FPU_SETCW]) AC_MSG_CHECKING([for usable _FPU_SETCW])
AC_LINK_IFELSE([AC_LANG_PROGRAM([[ AC_LINK_IFELSE([AC_LANG_PROGRAM([[
@ -116,6 +118,11 @@ AC_DEFUN([ZEND_CHECK_FLOAT_PRECISION],[
fi fi
]) ])
dnl
dnl LIBZEND_BASIC_CHECKS
dnl
dnl Basic checks specific for the Zend engine library.
dnl
AC_DEFUN([LIBZEND_BASIC_CHECKS],[ AC_DEFUN([LIBZEND_BASIC_CHECKS],[
AC_REQUIRE([AC_PROG_CC]) AC_REQUIRE([AC_PROG_CC])
@ -130,10 +137,12 @@ unix.h \
cpuid.h \ cpuid.h \
dlfcn.h) dlfcn.h)
AC_DEFUN([LIBZEND_DLSYM_CHECK],[ dnl
dnl LIBZEND_DLSYM_CHECK
dnl dnl
dnl Ugly hack to check if dlsym() requires a leading underscore in symbol name. dnl Ugly hack to check if dlsym() requires a leading underscore in symbol name.
dnl dnl
AC_DEFUN([LIBZEND_DLSYM_CHECK],[
AC_MSG_CHECKING([whether dlsym() requires a leading underscore in symbol names]) AC_MSG_CHECKING([whether dlsym() requires a leading underscore in symbol names])
_LT_AC_TRY_DLOPEN_SELF([ _LT_AC_TRY_DLOPEN_SELF([
AC_MSG_RESULT(no) AC_MSG_RESULT(no)
@ -152,7 +161,7 @@ AC_CHECK_DECLS([isfinite, isnan, isinf], [], [], [[#include <math.h>]])
ZEND_CHECK_FLOAT_PRECISION ZEND_CHECK_FLOAT_PRECISION
dnl test whether double cast to long preserves least significant bits dnl Test whether double cast to long preserves least significant bits.
AC_MSG_CHECKING(whether double cast to long preserves least significant bits) AC_MSG_CHECKING(whether double cast to long preserves least significant bits)
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
@ -186,6 +195,9 @@ int main()
]) ])
dnl
dnl LIBZEND_OTHER_CHECKS
dnl
AC_DEFUN([LIBZEND_OTHER_CHECKS],[ AC_DEFUN([LIBZEND_OTHER_CHECKS],[
AC_ARG_ENABLE([zts], AC_ARG_ENABLE([zts],
@ -247,8 +259,8 @@ else
AC_MSG_RESULT(no) AC_MSG_RESULT(no)
fi fi
dnl test and set the alignment define for ZEND_MM dnl Test and set the alignment define for ZEND_MM. This also does the
dnl this also does the logarithmic test for ZEND_MM. dnl logarithmic test for ZEND_MM.
AC_MSG_CHECKING(for MM alignment and log values) AC_MSG_CHECKING(for MM alignment and log values)
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
@ -289,7 +301,7 @@ int main()
AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT, $LIBZEND_MM_ALIGN, [ ]) AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT, $LIBZEND_MM_ALIGN, [ ])
AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT_LOG2, $LIBZEND_MM_ALIGN_LOG2, [ ]) AC_DEFINE_UNQUOTED(ZEND_MM_ALIGNMENT_LOG2, $LIBZEND_MM_ALIGN_LOG2, [ ])
], [], [ ], [], [
dnl cross-compile needs something here dnl Cross compilation needs something here.
LIBZEND_MM_ALIGN=8 LIBZEND_MM_ALIGN=8
]) ])
@ -392,9 +404,7 @@ else
fi fi
AC_MSG_RESULT($ZEND_GCC_GLOBAL_REGS) AC_MSG_RESULT($ZEND_GCC_GLOBAL_REGS)
dnl dnl Check if atof() accepts NAN.
dnl Check if atof() accepts NAN
dnl
AC_CACHE_CHECK(whether atof() accepts NAN, ac_cv_atof_accept_nan,[ AC_CACHE_CHECK(whether atof() accepts NAN, ac_cv_atof_accept_nan,[
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include <math.h> #include <math.h>
@ -423,9 +433,7 @@ if test "$ac_cv_atof_accept_nan" = "yes"; then
AC_DEFINE([HAVE_ATOF_ACCEPTS_NAN], 1, [whether atof() accepts NAN]) AC_DEFINE([HAVE_ATOF_ACCEPTS_NAN], 1, [whether atof() accepts NAN])
fi fi
dnl dnl Check if atof() accepts INF.
dnl Check if atof() accepts INF
dnl
AC_CACHE_CHECK(whether atof() accepts INF, ac_cv_atof_accept_inf,[ AC_CACHE_CHECK(whether atof() accepts INF, ac_cv_atof_accept_inf,[
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include <math.h> #include <math.h>
@ -457,9 +465,7 @@ if test "$ac_cv_atof_accept_inf" = "yes"; then
AC_DEFINE([HAVE_ATOF_ACCEPTS_INF], 1, [whether atof() accepts INF]) AC_DEFINE([HAVE_ATOF_ACCEPTS_INF], 1, [whether atof() accepts INF])
fi fi
dnl dnl Check if HUGE_VAL == INF.
dnl Check if HUGE_VAL == INF
dnl
AC_CACHE_CHECK(whether HUGE_VAL == INF, ac_cv_huge_val_inf,[ AC_CACHE_CHECK(whether HUGE_VAL == INF, ac_cv_huge_val_inf,[
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include <math.h> #include <math.h>
@ -492,9 +498,7 @@ if test "$ac_cv_huge_val_inf" = "yes"; then
AC_DEFINE([HAVE_HUGE_VAL_INF], 1, [whether HUGE_VAL == INF]) AC_DEFINE([HAVE_HUGE_VAL_INF], 1, [whether HUGE_VAL == INF])
fi fi
dnl dnl Check if HUGE_VAL + -HUGEVAL == NAN.
dnl Check if HUGE_VAL + -HUGEVAL == NAN
dnl
AC_CACHE_CHECK(whether HUGE_VAL + -HUGEVAL == NAN, ac_cv_huge_val_nan,[ AC_CACHE_CHECK(whether HUGE_VAL + -HUGEVAL == NAN, ac_cv_huge_val_nan,[
AC_RUN_IFELSE([AC_LANG_SOURCE([[ AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include <math.h> #include <math.h>
@ -529,9 +533,7 @@ if test "$ac_cv_huge_val_nan" = "yes"; then
AC_DEFINE([HAVE_HUGE_VAL_NAN], 1, [whether HUGE_VAL + -HUGEVAL == NAN]) AC_DEFINE([HAVE_HUGE_VAL_NAN], 1, [whether HUGE_VAL + -HUGEVAL == NAN])
fi fi
dnl dnl Check whether __cpuid_count is available.
dnl Check whether __cpuid_count is available
dnl
AC_CACHE_CHECK(whether __cpuid_count is available, ac_cv_cpuid_count_available, [ AC_CACHE_CHECK(whether __cpuid_count is available, ac_cv_cpuid_count_available, [
AC_LINK_IFELSE([AC_LANG_PROGRAM([[ AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <cpuid.h> #include <cpuid.h>

File diff suppressed because it is too large Load diff

View file

@ -1,8 +1,8 @@
dnl ## Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
dnl Include external macro definitions before the AC_INIT to also remove dnl Include external macro definitions before the AC_INIT to also remove
dnl comments starting with # and empty newlines from the included files. dnl comments starting with # and empty newlines from the included files.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
m4_include([build/ax_check_compile_flag.m4]) m4_include([build/ax_check_compile_flag.m4])
m4_include([build/ax_func_which_gethostbyname_r.m4]) m4_include([build/ax_func_which_gethostbyname_r.m4])
m4_include([build/ax_gcc_func_attribute.m4]) m4_include([build/ax_gcc_func_attribute.m4])
@ -12,7 +12,7 @@ m4_include([build/php.m4])
m4_include([build/pkg.m4]) m4_include([build/pkg.m4])
dnl Basic autoconf initialization, generation of config.nice. dnl Basic autoconf initialization, generation of config.nice.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
AC_PREREQ([2.68]) AC_PREREQ([2.68])
AC_INIT([PHP],[8.0.0-dev],[https://bugs.php.net],[php],[https://www.php.net]) AC_INIT([PHP],[8.0.0-dev],[https://bugs.php.net],[php],[https://www.php.net])
@ -117,20 +117,20 @@ PHP_EXTRA_VERSION=[$]4
PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION" PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION` PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
dnl Allow version values to be used in Makefile dnl Allow version values to be used in Makefile.
PHP_SUBST(PHP_MAJOR_VERSION) PHP_SUBST(PHP_MAJOR_VERSION)
PHP_SUBST(PHP_MINOR_VERSION) PHP_SUBST(PHP_MINOR_VERSION)
PHP_SUBST(PHP_RELEASE_VERSION) PHP_SUBST(PHP_RELEASE_VERSION)
PHP_SUBST(PHP_EXTRA_VERSION) PHP_SUBST(PHP_EXTRA_VERSION)
dnl Define where extension directories are located in the configure context dnl Define where extension directories are located in the configure context.
AC_DEFUN([PHP_EXT_BUILDDIR],[$config_m4_dir])dnl AC_DEFUN([PHP_EXT_BUILDDIR],[$config_m4_dir])dnl
AC_DEFUN([PHP_EXT_DIR],[$config_m4_dir])dnl AC_DEFUN([PHP_EXT_DIR],[$config_m4_dir])dnl
AC_DEFUN([PHP_EXT_SRCDIR],[$abs_srcdir/$config_m4_dir])dnl AC_DEFUN([PHP_EXT_SRCDIR],[$abs_srcdir/$config_m4_dir])dnl
AC_DEFUN([PHP_ALWAYS_SHARED],[])dnl AC_DEFUN([PHP_ALWAYS_SHARED],[])dnl
dnl Setting up the PHP version based on the information above. dnl Setting up the PHP version based on the information above.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
echo "/* automatically generated by configure */" > php_version.h.new echo "/* automatically generated by configure */" > php_version.h.new
echo "/* edit configure.ac to change version number */" >> php_version.h.new echo "/* edit configure.ac to change version number */" >> php_version.h.new
@ -149,7 +149,7 @@ else
fi fi
dnl Settings we want to make before the checks. dnl Settings we want to make before the checks.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
php_shtool=$srcdir/build/shtool php_shtool=$srcdir/build/shtool
T_MD=`$php_shtool echo -n -e %B` T_MD=`$php_shtool echo -n -e %B`
@ -166,16 +166,15 @@ abs_builddir=`pwd`
php_abs_top_srcdir=$abs_srcdir php_abs_top_srcdir=$abs_srcdir
php_abs_top_builddir=$abs_builddir php_abs_top_builddir=$abs_builddir
dnl Because ``make install'' is often performed by the superuser, dnl Because `make install` is often performed by the superuser, we create the
dnl we create the libs subdirectory as the user who configures PHP. dnl libs subdirectory as the user who configures PHP. Otherwise, the current
dnl Otherwise, the current user will not be able to delete libs dnl user will not be able to delete libs or the contents of libs.
dnl or the contents of libs.
$php_shtool mkdir -p libs $php_shtool mkdir -p libs
rm -f libs/* rm -f libs/*
dnl Checks for programs. dnl Checks for programs.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PKG_PROG_PKG_CONFIG PKG_PROG_PKG_CONFIG
AC_PROG_CC([cc gcc]) AC_PROG_CC([cc gcc])
@ -186,7 +185,7 @@ AC_PROG_CPP
AC_USE_SYSTEM_EXTENSIONS AC_USE_SYSTEM_EXTENSIONS
AC_PROG_LN_S AC_PROG_LN_S
dnl Support systems with system libraries in e.g. /usr/lib64 dnl Support systems with system libraries in e.g. /usr/lib64.
PHP_ARG_WITH([libdir], PHP_ARG_WITH([libdir],
[for system library directory], [for system library directory],
[AS_HELP_STRING([--with-libdir=NAME], [AS_HELP_STRING([--with-libdir=NAME],
@ -201,10 +200,10 @@ PHP_ARG_ENABLE([rpath],
[yes], [yes],
[no]) [no])
dnl check for -R, etc. switch dnl Check for -R, etc. switch.
PHP_RUNPATH_SWITCH PHP_RUNPATH_SWITCH
dnl Checks for some support/generator progs dnl Checks for some support/generator progs.
PHP_PROG_AWK PHP_PROG_AWK
PHP_PROG_BISON([3.0.0]) PHP_PROG_BISON([3.0.0])
PHP_PROG_RE2C([0.13.4]) PHP_PROG_RE2C([0.13.4])
@ -242,7 +241,7 @@ fi
PHP_SUBST(RE2C_FLAGS) PHP_SUBST(RE2C_FLAGS)
dnl Platform-specific compile settings. dnl Platform-specific compile settings.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
dnl See bug #28605 dnl See bug #28605
case $host_cpu in case $host_cpu in
@ -298,8 +297,8 @@ case $host_alias in
;; ;;
esac esac
# Disable PIC mode by default where it is known to be safe to do so, dnl Disable PIC mode by default where it is known to be safe to do so, to avoid
# to avoid the performance hit from the lost register dnl the performance hit from the lost register.
AC_MSG_CHECKING([whether to force non-PIC code in shared modules]) AC_MSG_CHECKING([whether to force non-PIC code in shared modules])
case $host_alias in case $host_alias in
i?86-*-linux*|i?86-*-freebsd*) i?86-*-linux*|i?86-*-freebsd*)
@ -315,16 +314,14 @@ case $host_alias in
;; ;;
esac esac
dnl Include Zend and TSRM configurations. dnl Include Zend and TSRM configurations.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
sinclude(Zend/Zend.m4) sinclude(Zend/Zend.m4)
sinclude(TSRM/threads.m4) sinclude(TSRM/threads.m4)
sinclude(TSRM/tsrm.m4) sinclude(TSRM/tsrm.m4)
dnl . dnl ----------------------------------------------------------------------------
dnl -------------------------------------------------------------------------
PTHREADS_CHECK PTHREADS_CHECK
PHP_HELP_SEPARATOR([SAPI modules:]) PHP_HELP_SEPARATOR([SAPI modules:])
@ -332,11 +329,10 @@ PHP_SHLIB_SUFFIX_NAMES
PHP_BUILD_PROGRAM PHP_BUILD_PROGRAM
PHP_SAPI=none PHP_SAPI=none
dnl SAPI configuration. dnl SAPI configuration.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
dnl paths to the targets are relative to the build directory dnl Paths to the targets are relative to the build directory.
SAPI_SHARED=libs/libphp[]$PHP_MAJOR_VERSION[.]$SHLIB_DL_SUFFIX_NAME SAPI_SHARED=libs/libphp[]$PHP_MAJOR_VERSION[.]$SHLIB_DL_SUFFIX_NAME
SAPI_STATIC=libs/libphp[]$PHP_MAJOR_VERSION[.a] SAPI_STATIC=libs/libphp[]$PHP_MAJOR_VERSION[.a]
SAPI_LIBTOOL=libphp[]$PHP_MAJOR_VERSION[.la] SAPI_LIBTOOL=libphp[]$PHP_MAJOR_VERSION[.la]
@ -345,11 +341,11 @@ PHP_CONFIGURE_PART(Configuring SAPI modules)
esyscmd(./build/config-stubs sapi) esyscmd(./build/config-stubs sapi)
dnl Show which main SAPI was selected dnl Show which main SAPI was selected.
AC_MSG_CHECKING([for chosen SAPI module]) AC_MSG_CHECKING([for chosen SAPI module])
AC_MSG_RESULT([$PHP_SAPI]) AC_MSG_RESULT([$PHP_SAPI])
dnl Show which binaries were selected dnl Show which binaries were selected.
AC_MSG_CHECKING([for executable SAPI binaries]) AC_MSG_CHECKING([for executable SAPI binaries])
if test "$PHP_BINARIES"; then if test "$PHP_BINARIES"; then
AC_MSG_RESULT([$PHP_BINARIES]) AC_MSG_RESULT([$PHP_BINARIES])
@ -357,50 +353,48 @@ else
AC_MSG_RESULT([none]) AC_MSG_RESULT([none])
fi fi
dnl Exit early dnl Exit early.
if test -z "$PHP_INSTALLED_SAPIS"; then if test -z "$PHP_INSTALLED_SAPIS"; then
AC_MSG_ERROR([Nothing to build.]) AC_MSG_ERROR([Nothing to build.])
fi fi
dnl force ZTS dnl Force ZTS.
if test "$enable_zts" = "yes"; then if test "$enable_zts" = "yes"; then
PTHREADS_ASSIGN_VARS PTHREADS_ASSIGN_VARS
PTHREADS_FLAGS PTHREADS_FLAGS
fi fi
dnl Starting system checks. dnl Starting system checks.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PHP_CONFIGURE_PART(Running system checks) PHP_CONFIGURE_PART(Running system checks)
dnl Find sendmail binary dnl Find sendmail binary.
PHP_PROG_SENDMAIL PHP_PROG_SENDMAIL
dnl Check whether the system uses EBCDIC (not ASCII) as its native codeset dnl Check whether the system uses EBCDIC (not ASCII) as its native codeset.
PHP_EBCDIC PHP_EBCDIC
dnl Check whether the system byte ordering is bigendian dnl Check whether the system byte ordering is bigendian.
PHP_C_BIGENDIAN PHP_C_BIGENDIAN
dnl Check whether writing to stdout works dnl Check whether writing to stdout works.
PHP_TEST_WRITE_STDOUT PHP_TEST_WRITE_STDOUT
dnl Check for /usr/pkg/{lib,include} which is where NetBSD puts binary dnl Check for /usr/pkg/{lib,include} which is where NetBSD puts binary and
dnl and source packages. This should be harmless on other OSs. dnl source packages. This should be harmless on other OSs.
if test -d /usr/pkg/include -a -d /usr/pkg/lib ; then if test -d /usr/pkg/include -a -d /usr/pkg/lib ; then
CPPFLAGS="$CPPFLAGS -I/usr/pkg/include" CPPFLAGS="$CPPFLAGS -I/usr/pkg/include"
LDFLAGS="$LDFLAGS -L/usr/pkg/lib" LDFLAGS="$LDFLAGS -L/usr/pkg/lib"
fi fi
test -d /usr/ucblib && PHP_ADD_LIBPATH(/usr/ucblib) test -d /usr/ucblib && PHP_ADD_LIBPATH(/usr/ucblib)
dnl First, library checks. dnl First, library checks.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
dnl Some systems (OpenServer 5) dislike -lsocket -lnsl, so we try dnl Some systems (OpenServer 5) dislike -lsocket -lnsl, so we try to avoid -lnsl
dnl to avoid -lnsl checks, if we already have the functions which dnl checks, if we already have the functions which are usually in libnsl. Also,
dnl are usually in libnsl dnl uClibc will bark at linking with glibc's libnsl.
dnl Also, uClibc will bark at linking with glibc's libnsl.
PHP_CHECK_FUNC(socket, socket) PHP_CHECK_FUNC(socket, socket)
PHP_CHECK_FUNC(socketpair, socket) PHP_CHECK_FUNC(socketpair, socket)
@ -415,14 +409,13 @@ if test "$ac_cv_func_dlopen" = "yes"; then
fi fi
AC_CHECK_LIB(m, sin) AC_CHECK_LIB(m, sin)
dnl Check for inet_aton dnl Check for inet_aton in -lc, -lbind and -lresolv.
dnl in -lc, -lbind and -lresolv
PHP_CHECK_FUNC(inet_aton, resolv, bind) PHP_CHECK_FUNC(inet_aton, resolv, bind)
dnl Then headers. dnl Then headers.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
dnl QNX requires unix.h to allow functions in libunix to work properly dnl QNX requires unix.h to allow functions in libunix to work properly.
AC_CHECK_HEADERS([ \ AC_CHECK_HEADERS([ \
inttypes.h \ inttypes.h \
stdint.h \ stdint.h \
@ -501,7 +494,7 @@ if test "$GCC" = "yes"; then
fi fi
dnl Checks for typedefs, structures, and compiler characteristics. dnl Checks for typedefs, structures, and compiler characteristics.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
AC_STRUCT_TIMEZONE AC_STRUCT_TIMEZONE
@ -510,12 +503,12 @@ PHP_MISSING_FCLOSE_DECL
PHP_STRUCT_FLOCK PHP_STRUCT_FLOCK
PHP_SOCKLEN_T PHP_SOCKLEN_T
dnl These are defined elsewhere than stdio.h dnl These are defined elsewhere than stdio.h.
PHP_CHECK_SIZEOF(intmax_t, 0) PHP_CHECK_SIZEOF(intmax_t, 0)
PHP_CHECK_SIZEOF(ssize_t, 8) PHP_CHECK_SIZEOF(ssize_t, 8)
PHP_CHECK_SIZEOF(ptrdiff_t, 8) PHP_CHECK_SIZEOF(ptrdiff_t, 8)
dnl Check stdint types (must be after header check) dnl Check stdint types (must be after header check).
PHP_CHECK_STDINT_TYPES PHP_CHECK_STDINT_TYPES
dnl Check __builtin_expect dnl Check __builtin_expect
@ -543,17 +536,17 @@ PHP_CHECK_BUILTIN_CPU_INIT
dnl Check __builtin_cpu_supports dnl Check __builtin_cpu_supports
PHP_CHECK_BUILTIN_CPU_SUPPORTS PHP_CHECK_BUILTIN_CPU_SUPPORTS
dnl Check instructions dnl Check instructions.
PHP_CHECK_CPU_SUPPORTS([ssse3]) PHP_CHECK_CPU_SUPPORTS([ssse3])
PHP_CHECK_CPU_SUPPORTS([sse4.2]) PHP_CHECK_CPU_SUPPORTS([sse4.2])
PHP_CHECK_CPU_SUPPORTS([avx]) PHP_CHECK_CPU_SUPPORTS([avx])
PHP_CHECK_CPU_SUPPORTS([avx2]) PHP_CHECK_CPU_SUPPORTS([avx2])
dnl Check for structure members dnl Check for structure members.
AC_CHECK_MEMBERS([struct tm.tm_gmtoff],,,[#include <time.h>]) AC_CHECK_MEMBERS([struct tm.tm_gmtoff],,,[#include <time.h>])
AC_CHECK_MEMBERS([struct stat.st_blksize, struct stat.st_rdev]) AC_CHECK_MEMBERS([struct stat.st_blksize, struct stat.st_rdev])
dnl AC_STRUCT_ST_BLOCKS will screw QNX because fileblocks.o does not exist dnl AC_STRUCT_ST_BLOCKS will screw QNX because fileblocks.o does not exist. The
dnl The WARNING_LEVEL required because cc in QNX hates -w option without an argument dnl WARNING_LEVEL required because cc in QNX hates -w option without an argument
if test "`uname -s 2>/dev/null`" != "QNX"; then if test "`uname -s 2>/dev/null`" != "QNX"; then
AC_STRUCT_ST_BLOCKS AC_STRUCT_ST_BLOCKS
else else
@ -561,15 +554,15 @@ else
WARNING_LEVEL=0 WARNING_LEVEL=0
fi fi
dnl Checks for types dnl Checks for types.
AC_TYPE_SIZE_T AC_TYPE_SIZE_T
AC_TYPE_UID_T AC_TYPE_UID_T
dnl Checks for sockaddr_storage and sockaddr.sa_len dnl Checks for sockaddr_storage and sockaddr.sa_len.
PHP_SOCKADDR_CHECKS PHP_SOCKADDR_CHECKS
dnl Checks for GCC function attributes on all systems except ones without glibc dnl Checks for GCC function attributes on all systems except ones without glibc
dnl Fix for these systems is already included in GCC 7, but not on GCC 6 dnl Fix for these systems is already included in GCC 7, but not on GCC 6.
dnl dnl
dnl At least some versions of FreeBSD seem to have buggy ifunc support, see dnl At least some versions of FreeBSD seem to have buggy ifunc support, see
dnl bug #77284. Conservatively don't use ifuncs on FreeBSD. dnl bug #77284. Conservatively don't use ifuncs on FreeBSD.
@ -578,7 +571,7 @@ AS_CASE([$host_alias], [*-*-*android*|*-*-*uclibc*|*-*-*musl*|*freebsd*], [true]
AX_GCC_FUNC_ATTRIBUTE([target]) AX_GCC_FUNC_ATTRIBUTE([target])
]) ])
dnl Check for IPv6 support dnl Check for IPv6 support.
AC_CACHE_CHECK([for IPv6 support], ac_cv_ipv6_support, AC_CACHE_CHECK([for IPv6 support], ac_cv_ipv6_support,
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h> [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h>
#include <sys/socket.h> #include <sys/socket.h>
@ -586,7 +579,7 @@ AC_CACHE_CHECK([for IPv6 support], ac_cv_ipv6_support,
[ac_cv_ipv6_support=yes], [ac_cv_ipv6_support=no])]) [ac_cv_ipv6_support=yes], [ac_cv_ipv6_support=no])])
dnl Checks for library functions. dnl Checks for library functions.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
AC_CHECK_FUNCS( AC_CHECK_FUNCS(
alphasort \ alphasort \
@ -668,11 +661,11 @@ nanosleep \
AX_FUNC_WHICH_GETHOSTBYNAME_R AX_FUNC_WHICH_GETHOSTBYNAME_R
dnl Some systems (like OpenSolaris) do not have nanosleep in libc dnl Some systems (like OpenSolaris) do not have nanosleep in libc.
PHP_CHECK_FUNC_LIB(nanosleep, rt) PHP_CHECK_FUNC_LIB(nanosleep, rt)
dnl Check for getaddrinfo, should be a better way, but... dnl Check for getaddrinfo, should be a better way, but... Also check for working
dnl Also check for working getaddrinfo dnl getaddrinfo.
AC_CACHE_CHECK([for getaddrinfo], ac_cv_func_getaddrinfo, AC_CACHE_CHECK([for getaddrinfo], ac_cv_func_getaddrinfo,
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <netdb.h>]], [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <netdb.h>]],
[[struct addrinfo *g,h;g=&h;getaddrinfo("","",g,&g);]])],[AC_RUN_IFELSE([AC_LANG_SOURCE([[ [[struct addrinfo *g,h;g=&h;getaddrinfo("","",g,&g);]])],[AC_RUN_IFELSE([AC_LANG_SOURCE([[
@ -717,7 +710,7 @@ if test "$ac_cv_func_getaddrinfo" = yes; then
AC_DEFINE(HAVE_GETADDRINFO,1,[Define if you have the getaddrinfo function]) AC_DEFINE(HAVE_GETADDRINFO,1,[Define if you have the getaddrinfo function])
fi fi
dnl Check for the __sync_fetch_and_add builtin dnl Check for the __sync_fetch_and_add builtin.
AC_CACHE_CHECK([for __sync_fetch_and_add], ac_cv_func_sync_fetch_and_add, AC_CACHE_CHECK([for __sync_fetch_and_add], ac_cv_func_sync_fetch_and_add,
[AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[int x;__sync_fetch_and_add(&x,1);]])],[ac_cv_func_sync_fetch_and_add=yes],[ac_cv_func_sync_fetch_and_add=no])]) [AC_LINK_IFELSE([AC_LANG_PROGRAM([], [[int x;__sync_fetch_and_add(&x,1);]])],[ac_cv_func_sync_fetch_and_add=yes],[ac_cv_func_sync_fetch_and_add=no])])
if test "$ac_cv_func_sync_fetch_and_add" = yes; then if test "$ac_cv_func_sync_fetch_and_add" = yes; then
@ -734,7 +727,7 @@ if test "x$php_crypt_r" = "x1"; then
PHP_CRYPT_R_STYLE PHP_CRYPT_R_STYLE
fi fi
dnl Check for asm goto support dnl Check for asm goto support.
AC_CACHE_CHECK([for asm goto], ac_cv__asm_goto, AC_CACHE_CHECK([for asm goto], ac_cv__asm_goto,
[AC_RUN_IFELSE([AC_LANG_SOURCE([[ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
int main(void) { int main(void) {
@ -752,7 +745,7 @@ if test "$ac_cv__asm_goto" = yes; then
AC_DEFINE(HAVE_ASM_GOTO,1,[Define if asm goto support]) AC_DEFINE(HAVE_ASM_GOTO,1,[Define if asm goto support])
fi fi
dnl Check for variable length array support dnl Check for variable length array support.
AC_CACHE_CHECK([whether compiler supports VLA], ac_cv__compiler_c99_vla, AC_CACHE_CHECK([whether compiler supports VLA], ac_cv__compiler_c99_vla,
[AC_RUN_IFELSE([AC_LANG_SOURCE([[ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
#include <stdlib.h> #include <stdlib.h>
@ -766,7 +759,7 @@ if test "$ac_cv__compiler_c99_vla" = yes; then
AC_DEFINE(HAVE_COMPILER_C99_VLA, 1, [Compiler supports VLA]) AC_DEFINE(HAVE_COMPILER_C99_VLA, 1, [Compiler supports VLA])
fi fi
dnl Check valgrind support dnl Check valgrind support.
PHP_ARG_WITH([valgrind], PHP_ARG_WITH([valgrind],
[whether to enable valgrind support], [whether to enable valgrind support],
[AS_HELP_STRING([--with-valgrind=DIR], [AS_HELP_STRING([--with-valgrind=DIR],
@ -801,7 +794,7 @@ if test "$PHP_VALGRIND" != "no"; then
fi fi
dnl General settings. dnl General settings.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PHP_CONFIGURE_PART(General settings) PHP_CONFIGURE_PART(General settings)
PHP_HELP_SEPARATOR([General settings:]) PHP_HELP_SEPARATOR([General settings:])
@ -819,7 +812,7 @@ if test "$PHP_GCOV" = "yes"; then
AC_MSG_ERROR([GCC is required for --enable-gcov]) AC_MSG_ERROR([GCC is required for --enable-gcov])
fi fi
dnl Check if ccache is being used dnl Check if ccache is being used.
case `$php_shtool path $CC` in case `$php_shtool path $CC` in
*ccache*[)] gcc_ccache=yes;; *ccache*[)] gcc_ccache=yes;;
*[)] gcc_ccache=no;; *[)] gcc_ccache=no;;
@ -829,11 +822,11 @@ if test "$PHP_GCOV" = "yes"; then
AC_MSG_ERROR([ccache must be disabled when --enable-gcov option is used. You can disable ccache by setting environment variable CCACHE_DISABLE=1.]) AC_MSG_ERROR([ccache must be disabled when --enable-gcov option is used. You can disable ccache by setting environment variable CCACHE_DISABLE=1.])
fi fi
dnl min: 1.5 (i.e. 105, major * 100 + minor for easier comparison) dnl Min: 1.5 (i.e. 105, major * 100 + minor for easier comparison).
ltp_version_min="105" ltp_version_min="105"
dnl non-working versions, e.g. "1.8 1.18"; dnl Non-working versions, e.g. "1.8 1.18";
dnl remove "none" when introducing the first incompatible LTP version and dnl Remove "none" when introducing the first incompatible LTP version and
dnl separate any following additions by spaces dnl separate any following additions by spaces.
ltp_version_exclude="1.8" ltp_version_exclude="1.8"
AC_CHECK_PROG(LTP, lcov, lcov) AC_CHECK_PROG(LTP, lcov, lcov)
@ -880,13 +873,13 @@ if test "$PHP_GCOV" = "yes"; then
AC_DEFINE(HAVE_GCOV, 1, [Whether you have gcov]) AC_DEFINE(HAVE_GCOV, 1, [Whether you have gcov])
PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/build/Makefile.gcov, $abs_srcdir) PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/build/Makefile.gcov, $abs_srcdir)
dnl Remove all optimization flags from CFLAGS dnl Remove all optimization flags from CFLAGS.
changequote({,}) changequote({,})
CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'` CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'`
CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'` CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'`
changequote([,]) changequote([,])
dnl Add the special gcc flags dnl Add the special gcc flags.
CFLAGS="$CFLAGS -O0 -fprofile-arcs -ftest-coverage" CFLAGS="$CFLAGS -O0 -fprofile-arcs -ftest-coverage"
CXXFLAGS="$CXXFLAGS -O0 -fprofile-arcs -ftest-coverage" CXXFLAGS="$CXXFLAGS -O0 -fprofile-arcs -ftest-coverage"
fi fi
@ -905,7 +898,7 @@ if test "$PHP_DEBUG" = "yes"; then
CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'` CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'`
CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'` CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'`
changequote([,]) changequote([,])
dnl add -O0 only if GCC or ICC is used dnl Add -O0 only if GCC or ICC is used.
if test "$GCC" = "yes" || test "$ICC" = "yes"; then if test "$GCC" = "yes" || test "$ICC" = "yes"; then
CFLAGS="$CFLAGS -O0" CFLAGS="$CFLAGS -O0"
CXXFLAGS="$CXXFLAGS -g -O0" CXXFLAGS="$CXXFLAGS -g -O0"
@ -1053,10 +1046,7 @@ if test "$PHP_IPV6" != "no" && test "$ac_cv_ipv6_support" = yes; then
AC_DEFINE(HAVE_IPV6, 1, [Whether to enable IPv6 support]) AC_DEFINE(HAVE_IPV6, 1, [Whether to enable IPv6 support])
fi fi
dnl ## dnl DTRACE checks. Note: this has to be done after SAPI configuration.
dnl ## DTRACE CHECKS
dnl ## Note: this has to be done after SAPI configuration!
dnl ##
PHP_ARG_ENABLE([dtrace], PHP_ARG_ENABLE([dtrace],
[whether to enable DTrace support], [whether to enable DTrace support],
[AS_HELP_STRING([--enable-dtrace], [AS_HELP_STRING([--enable-dtrace],
@ -1101,7 +1091,7 @@ PHP_ARG_ENABLE([werror],,
[no]) [no])
dnl Extension configuration. dnl Extension configuration.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PHP_HELP_SEPARATOR([Extensions: PHP_HELP_SEPARATOR([Extensions:
@ -1117,20 +1107,17 @@ PHP_HELP_SEPARATOR([Extensions:
PHP_CONFIGURE_PART(Configuring extensions) PHP_CONFIGURE_PART(Configuring extensions)
dnl dnl Check if all enabled by default extensions should be disabled.
dnl Check if all enabled by default extensions should be disabled
dnl
AC_ARG_ENABLE([all], AC_ARG_ENABLE([all],
[AS_HELP_STRING([--disable-all], [AS_HELP_STRING([--disable-all],
[Disable all extensions which are enabled by default])], [Disable all extensions which are enabled by default])],
[PHP_ENABLE_ALL=$enableval]) [PHP_ENABLE_ALL=$enableval])
# reading config stubs dnl Reading config stubs.
esyscmd(./build/config-stubs ext) esyscmd(./build/config-stubs ext)
dnl Extensions post-config dnl Extensions post-config.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
enable_shared=yes enable_shared=yes
enable_static=yes enable_static=yes
@ -1158,8 +1145,8 @@ esac
EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS" EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS"
dnl this has to be here to prevent the openssl crypt() from dnl This has to be here to prevent the openssl crypt() from overriding the
dnl overriding the system provided crypt(). dnl system provided crypt().
if test "$ac_cv_lib_crypt_crypt" = "yes"; then if test "$ac_cv_lib_crypt_crypt" = "yes"; then
EXTRA_LIBS="-lcrypt $EXTRA_LIBS -lcrypt" EXTRA_LIBS="-lcrypt $EXTRA_LIBS -lcrypt"
fi fi
@ -1167,17 +1154,17 @@ fi
unset LIBS LDFLAGS unset LIBS LDFLAGS
dnl PEAR dnl PEAR
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PHP_HELP_SEPARATOR([PEAR:]) PHP_HELP_SEPARATOR([PEAR:])
PHP_CONFIGURE_PART(Configuring PEAR) PHP_CONFIGURE_PART(Configuring PEAR)
# compatibility dnl Compatibility
if test -z "$with_pear" && test "$enable_pear" = "no"; then if test -z "$with_pear" && test "$enable_pear" = "no"; then
with_pear=no with_pear=no
fi fi
# If CLI is disabled -> disable PEAR dnl If CLI is disabled disable PEAR.
if test "$PHP_CLI" = "no"; then if test "$PHP_CLI" = "no"; then
with_pear=no with_pear=no
fi fi
@ -1191,9 +1178,7 @@ PHP_ARG_WITH([pear],
if test "$PHP_PEAR" != "no"; then if test "$PHP_PEAR" != "no"; then
dnl dnl PEAR dependencies.
dnl PEAR dependencies
dnl
if test "$PHP_XML" = "no"; then if test "$PHP_XML" = "no"; then
pear_error_msg="$pear_error_msg pear_error_msg="$pear_error_msg
PEAR requires XML to be enabled. Add --enable-xml to the configure line. (or --without-pear)" PEAR requires XML to be enabled. Add --enable-xml to the configure line. (or --without-pear)"
@ -1218,9 +1203,8 @@ if test "$PHP_PEAR" != "no"; then
PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/pear/Makefile.frag,$abs_srcdir/pear,pear) PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/pear/Makefile.frag,$abs_srcdir/pear,pear)
fi fi
dnl Configuring Zend and TSRM. dnl Configuring Zend and TSRM.
dnl ------------------------------------------------------------------------- dnl ----------------------------------------------------------------------------
PHP_HELP_SEPARATOR([Zend:]) PHP_HELP_SEPARATOR([Zend:])
PHP_CONFIGURE_PART(Configuring Zend) PHP_CONFIGURE_PART(Configuring Zend)
@ -1288,8 +1272,7 @@ exec_prefix=`eval echo $exec_prefix`
libdir=`eval echo $libdir` libdir=`eval echo $libdir`
datadir=`eval eval echo $datadir` datadir=`eval eval echo $datadir`
dnl Build extension directory path dnl Build extension directory path.
ZEND_MODULE_API_NO=`$EGREP '#define ZEND_MODULE_API_NO ' $srcdir/Zend/zend_modules.h|$SED 's/#define ZEND_MODULE_API_NO //'` ZEND_MODULE_API_NO=`$EGREP '#define ZEND_MODULE_API_NO ' $srcdir/Zend/zend_modules.h|$SED 's/#define ZEND_MODULE_API_NO //'`
if test -z "$EXTENSION_DIR"; then if test -z "$EXTENSION_DIR"; then
@ -1328,7 +1311,7 @@ case $PHP_LAYOUT in
;; ;;
esac esac
dnl Expand all directory names for use in macros/constants dnl Expand all directory names for use in macros/constants.
EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR` EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR`
EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR` EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR`
EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir` EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir`
@ -1373,7 +1356,8 @@ fi
EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PHP_LDFLAGS" EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PHP_LDFLAGS"
EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $PHP_LDFLAGS" EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $PHP_LDFLAGS"
# SOURCE_DATE_EPOCH for reproducible builds https://reproducible-builds.org/specs/source-date-epoch/ dnl SOURCE_DATE_EPOCH for reproducible builds
dnl https://reproducible-builds.org/specs/source-date-epoch/
PHP_BUILD_DATE=`date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" +%Y-%m-%d 2>/dev/null` PHP_BUILD_DATE=`date --utc --date="@${SOURCE_DATE_EPOCH:-$(date +%s)}" +%Y-%m-%d 2>/dev/null`
if test $? -ne 0 ; then if test $? -ne 0 ; then
PHP_BUILD_DATE=`date -u +%Y-%m-%d` PHP_BUILD_DATE=`date -u +%Y-%m-%d`
@ -1466,8 +1450,8 @@ if test "$PHP_THREAD_SAFETY" = "yes" && test -n "$ac_cv_pthreads_cflags"; then
CPPFLAGS="$CPPFLAGS $ac_cv_pthreads_cflags" CPPFLAGS="$CPPFLAGS $ac_cv_pthreads_cflags"
fi fi
dnl This will go away, if we have a facility to run per-extension code dnl This will go away, if we have a facility to run per-extension code after the
dnl after the thread_safety decision was done dnl thread_safety decision was done.
if test "$PHP_THREAD_SAFETY" = "yes" && test "$PHP_MYSQL" = "yes"; then if test "$PHP_THREAD_SAFETY" = "yes" && test "$PHP_MYSQL" = "yes"; then
CPPFLAGS="$CPPFLAGS -DTHREAD=1" CPPFLAGS="$CPPFLAGS -DTHREAD=1"
fi fi
@ -1481,7 +1465,7 @@ ZEND_EXT_TYPE="zend_extension"
PHP_SUBST(ZEND_EXT_TYPE) PHP_SUBST(ZEND_EXT_TYPE)
dnl dnl
dnl Libtool creation dnl Libtool creation.
dnl dnl
PHP_HELP_SEPARATOR([Libtool:]) PHP_HELP_SEPARATOR([Libtool:])
@ -1501,8 +1485,9 @@ dnl Silence warning: `ar: 'u' modifier ignored since 'D' is the default`
dnl See https://github.com/php/php-src/pull/3017 dnl See https://github.com/php/php-src/pull/3017
AC_SUBST(AR_FLAGS, [cr]) AC_SUBST(AR_FLAGS, [cr])
dnl Only allow AC_PROG_CXX and AC_PROG_CXXCPP if they are explicitly called (by PHP_REQUIRE_CXX). dnl Only allow AC_PROG_CXX and AC_PROG_CXXCPP if they are explicitly called (by
dnl Otherwise AC_PROG_LIBTOOL fails if there is no working C++ compiler. dnl PHP_REQUIRE_CXX). Otherwise AC_PROG_LIBTOOL fails if there is no working C++
dnl compiler.
AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [], [ AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [], [
undefine([AC_PROG_CXX]) undefine([AC_PROG_CXX])
AC_DEFUN([AC_PROG_CXX], []) AC_DEFUN([AC_PROG_CXX], [])
@ -1580,8 +1565,8 @@ PHP_ADD_SOURCES(Zend, \
zend_default_classes.c zend_inheritance.c zend_smart_str.c zend_cpuinfo.c zend_gdb.c, \ zend_default_classes.c zend_inheritance.c zend_smart_str.c zend_cpuinfo.c zend_gdb.c, \
-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1) -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
dnl Selectively disable optimization due to high RAM usage during dnl Selectively disable optimization due to high RAM usage during compiling the
dnl compiling the executor. dnl executor.
if test -n "$GCC" && test "$ZEND_INLINE_OPTIMIZATION" != "yes"; then if test -n "$GCC" && test "$ZEND_INLINE_OPTIMIZATION" != "yes"; then
flag=-O0 flag=-O0
else else
@ -1610,14 +1595,10 @@ scripts/phpize scripts/man1/phpize.1 \
scripts/php-config scripts/man1/php-config.1 \ scripts/php-config scripts/man1/php-config.1 \
$PHP_OUTPUT_FILES" $PHP_OUTPUT_FILES"
dnl dnl Check for unknown configure options.
dnl Check for unknown configure options
dnl
PHP_CHECK_CONFIGURE_OPTIONS PHP_CHECK_CONFIGURE_OPTIONS
dnl dnl Generate build files.
dnl Generate build files
dnl
AC_CONFIG_FILES([$ALL_OUTPUT_FILES]) AC_CONFIG_FILES([$ALL_OUTPUT_FILES])
AC_CONFIG_COMMANDS([default],[],[ AC_CONFIG_COMMANDS([default],[],[
@ -1625,10 +1606,8 @@ if test "\$CONFIG_FILES" = "$ALL_OUTPUT_FILES" || test "\$CONFIG_FILES" = " $ALL
REDO_ALL=yes REDO_ALL=yes
fi fi
################################################################ dnl Create configuration headers.
# Create configuration headers dnl ----------------------------------------------------------------------------
#
test -d Zend || $php_shtool mkdir Zend test -d Zend || $php_shtool mkdir Zend
cat >Zend/zend_config.h <<FEO cat >Zend/zend_config.h <<FEO
@ -1638,13 +1617,10 @@ cat >Zend/zend_config.h <<FEO
#endif #endif
FEO FEO
# run this only when generating all the files? dnl Run this only when generating all the files.
if test -n "\$REDO_ALL"; then if test -n "\$REDO_ALL"; then
# Hacking while airborne considered harmful.
#
echo "creating main/internal_functions.c" echo "creating main/internal_functions.c"
extensions="$EXT_STATIC" extensions="$EXT_STATIC"
dnl mv -f main/internal_functions.c main/internal_functions.c.old 2>/dev/null
sh $srcdir/build/genif.sh $srcdir/main/internal_functions.c.in $srcdir "$EXTRA_MODULE_PTRS" $AWK \$extensions > main/internal_functions.c sh $srcdir/build/genif.sh $srcdir/main/internal_functions.c.in $srcdir "$EXTRA_MODULE_PTRS" $AWK \$extensions > main/internal_functions.c
echo "creating main/internal_functions_cli.c" echo "creating main/internal_functions_cli.c"
@ -1691,7 +1667,7 @@ X
fi fi
fi fi
# Warn about Apache if oci8 extension is enabled on linux. dnl Warn about Apache if oci8 extension is enabled on Linux.
if test "$PHP_OCI8" != "no"; then if test "$PHP_OCI8" != "no"; then
if test "$PHP_SIGCHILD" != "yes"; then if test "$PHP_SIGCHILD" != "yes"; then
if test "$PHP_OCI8_INSTANT_CLIENT" = "no"; then if test "$PHP_OCI8_INSTANT_CLIENT" = "no"; then
@ -1723,7 +1699,7 @@ Thank you for using PHP.
X X
# Output unknown configure options dnl Output unknown configure options.
if test "$PHP_UNKNOWN_CONFIGURE_OPTIONS"; then if test "$PHP_UNKNOWN_CONFIGURE_OPTIONS"; then
echo "Notice: Following unknown configure options were used: echo "Notice: Following unknown configure options were used:
$PHP_UNKNOWN_CONFIGURE_OPTIONS $PHP_UNKNOWN_CONFIGURE_OPTIONS

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension bcmath
PHP_ARG_ENABLE([bcmath], PHP_ARG_ENABLE([bcmath],
[whether to enable bc style precision math functions], [whether to enable bc style precision math functions],
[AS_HELP_STRING([--enable-bcmath], [AS_HELP_STRING([--enable-bcmath],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension bz2
PHP_ARG_WITH([bz2], PHP_ARG_WITH([bz2],
[for BZip2 support], [for BZip2 support],
[AS_HELP_STRING([[--with-bz2[=DIR]]], [AS_HELP_STRING([[--with-bz2[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension calendar
PHP_ARG_ENABLE([calendar], PHP_ARG_ENABLE([calendar],
[whether to enable calendar conversion support], [whether to enable calendar conversion support],
[AS_HELP_STRING([--enable-calendar], [AS_HELP_STRING([--enable-calendar],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension ctype
PHP_ARG_ENABLE([ctype], PHP_ARG_ENABLE([ctype],
[whether to enable ctype functions], [whether to enable ctype functions],
[AS_HELP_STRING([--disable-ctype], [AS_HELP_STRING([--disable-ctype],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension curl
PHP_ARG_WITH([curl], PHP_ARG_WITH([curl],
[for cURL support], [for cURL support],
[AS_HELP_STRING([--with-curl], [AS_HELP_STRING([--with-curl],

View file

@ -1,5 +1,3 @@
dnl config.m4 for date extension
dnl Check for headers needed by timelib dnl Check for headers needed by timelib
AC_CHECK_HEADERS([ \ AC_CHECK_HEADERS([ \
strings.h \ strings.h \

View file

@ -1,7 +1,4 @@
dnl config.m4 for extension dba
dnl Suppose we need FlatFile if no support or only CDB is used. dnl Suppose we need FlatFile if no support or only CDB is used.
AC_DEFUN([PHP_DBA_STD_BEGIN],[ AC_DEFUN([PHP_DBA_STD_BEGIN],[
unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
]) ])
@ -136,7 +133,7 @@ dnl
dnl Library checks dnl Library checks
dnl dnl
# QDBM dnl QDBM
if test "$PHP_QDBM" != "no"; then if test "$PHP_QDBM" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
for i in $PHP_QDBM /usr/local /usr; do for i in $PHP_QDBM /usr/local /usr; do
@ -166,7 +163,7 @@ if test "$PHP_QDBM" != "no"; then
fi fi
PHP_DBA_STD_RESULT(qdbm) PHP_DBA_STD_RESULT(qdbm)
# GDBM dnl GDBM
if test "$PHP_GDBM" != "no"; then if test "$PHP_GDBM" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
if test "$HAVE_QDBM" = "1"; then if test "$HAVE_QDBM" = "1"; then
@ -194,7 +191,7 @@ if test "$PHP_GDBM" != "no"; then
fi fi
PHP_DBA_STD_RESULT(gdbm) PHP_DBA_STD_RESULT(gdbm)
# NDBM dnl NDBM
if test "$PHP_NDBM" != "no"; then if test "$PHP_NDBM" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
for i in $PHP_NDBM /usr/local /usr; do for i in $PHP_NDBM /usr/local /usr; do
@ -368,7 +365,7 @@ AC_DEFUN([PHP_DBA_DB_CHECK],[
PHP_DBA_STD_ATTACH PHP_DBA_STD_ATTACH
]) ])
# DB4 dnl DB4
if test "$PHP_DB4" != "no"; then if test "$PHP_DB4" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
dbdp4="/usr/local/BerkeleyDB.4." dbdp4="/usr/local/BerkeleyDB.4."
@ -432,7 +429,7 @@ if test "$PHP_DB4" != "no"; then
fi fi
PHP_DBA_STD_RESULT(db4,Berkeley DB4) PHP_DBA_STD_RESULT(db4,Berkeley DB4)
# DB3 dnl DB3
if test "$PHP_DB3" != "no"; then if test "$PHP_DB3" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
if test "$HAVE_DB4" = "1"; then if test "$HAVE_DB4" = "1"; then
@ -465,7 +462,7 @@ if test "$PHP_DB3" != "no"; then
fi fi
PHP_DBA_STD_RESULT(db3,Berkeley DB3) PHP_DBA_STD_RESULT(db3,Berkeley DB3)
# DB2 dnl DB2
if test "$PHP_DB2" != "no"; then if test "$PHP_DB2" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
if test "$HAVE_DB3" = "1" || test "$HAVE_DB4" = "1"; then if test "$HAVE_DB3" = "1" || test "$HAVE_DB4" = "1"; then
@ -498,7 +495,7 @@ if test "$PHP_DB2" != "no"; then
fi fi
PHP_DBA_STD_RESULT(db2, Berkeley DB2) PHP_DBA_STD_RESULT(db2, Berkeley DB2)
# DB1 dnl DB1
if test "$PHP_DB1" != "no"; then if test "$PHP_DB1" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
AC_MSG_CHECKING([for DB1 in library]) AC_MSG_CHECKING([for DB1 in library])
@ -565,7 +562,7 @@ if test "$PHP_DB1" != "no"; then
fi fi
PHP_DBA_STD_RESULT(db1, DB1) PHP_DBA_STD_RESULT(db1, DB1)
# DBM dnl DBM
if test "$PHP_DBM" != "no"; then if test "$PHP_DBM" != "no"; then
PHP_DBA_STD_BEGIN PHP_DBA_STD_BEGIN
if test "$HAVE_QDBM" = "1"; then if test "$HAVE_QDBM" = "1"; then
@ -610,9 +607,8 @@ if test "$PHP_DBM" != "no"; then
fi fi
PHP_DBA_STD_RESULT(dbm) PHP_DBA_STD_RESULT(dbm)
dnl dnl Bundled modules that should be enabled by default if any other option is
dnl Bundled modules that should be enabled by default if any other option is enabled dnl enabled
dnl
if test "$PHP_DBA" != "no" || test "$HAVE_DBA" = "1" || test "$with_cdb" = "yes" || test "$enable_inifile" = "yes" || test "$enable_flatfile" = "yes"; then if test "$PHP_DBA" != "no" || test "$HAVE_DBA" = "1" || test "$with_cdb" = "yes" || test "$enable_inifile" = "yes" || test "$enable_flatfile" = "yes"; then
php_dba_enable=yes php_dba_enable=yes
else else
@ -637,7 +633,7 @@ PHP_ARG_ENABLE([flatfile],,
[$php_dba_enable], [$php_dba_enable],
[no]) [no])
# CDB dnl CDB
if test "$PHP_CDB" = "yes"; then if test "$PHP_CDB" = "yes"; then
AC_DEFINE(DBA_CDB_BUILTIN, 1, [ ]) AC_DEFINE(DBA_CDB_BUILTIN, 1, [ ])
AC_DEFINE(DBA_CDB_MAKE, 1, [ ]) AC_DEFINE(DBA_CDB_MAKE, 1, [ ])
@ -673,7 +669,7 @@ elif test "$PHP_CDB" != "no"; then
fi fi
PHP_DBA_STD_RESULT(cdb) PHP_DBA_STD_RESULT(cdb)
# INIFILE dnl INIFILE
if test "$PHP_INIFILE" != "no"; then if test "$PHP_INIFILE" != "no"; then
AC_DEFINE(DBA_INIFILE, 1, [ ]) AC_DEFINE(DBA_INIFILE, 1, [ ])
ini_sources="libinifile/inifile.c" ini_sources="libinifile/inifile.c"
@ -681,7 +677,7 @@ if test "$PHP_INIFILE" != "no"; then
fi fi
PHP_DBA_STD_RESULT(inifile, [INI File]) PHP_DBA_STD_RESULT(inifile, [INI File])
# FLATFILE dnl FLATFILE
if test "$PHP_FLATFILE" != "no"; then if test "$PHP_FLATFILE" != "no"; then
AC_DEFINE(DBA_FLATFILE, 1, [ ]) AC_DEFINE(DBA_FLATFILE, 1, [ ])
flat_sources="libflatfile/flatfile.c" flat_sources="libflatfile/flatfile.c"

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension dom
PHP_ARG_ENABLE([dom], PHP_ARG_ENABLE([dom],
[whether to enable DOM support], [whether to enable DOM support],
[AS_HELP_STRING([--disable-dom], [AS_HELP_STRING([--disable-dom],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension enchant
PHP_ARG_WITH([enchant], PHP_ARG_WITH([enchant],
[for ENCHANT support], [for ENCHANT support],
[AS_HELP_STRING([[--with-enchant[=DIR]]], [AS_HELP_STRING([[--with-enchant[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension exif
PHP_ARG_ENABLE([exif], PHP_ARG_ENABLE([exif],
[whether to enable EXIF (metadata from images) support], [whether to enable EXIF (metadata from images) support],
[AS_HELP_STRING([--enable-exif], [AS_HELP_STRING([--enable-exif],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension FFI
PHP_ARG_WITH([ffi], PHP_ARG_WITH([ffi],
[for FFI support], [for FFI support],
[AS_HELP_STRING([--with-ffi], [AS_HELP_STRING([--with-ffi],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension fileinfo
PHP_ARG_ENABLE([fileinfo], PHP_ARG_ENABLE([fileinfo],
[for fileinfo support], [for fileinfo support],
[AS_HELP_STRING([--disable-fileinfo], [AS_HELP_STRING([--disable-fileinfo],

View file

@ -1,5 +1,3 @@
dnl config.m4 for input filtering extension
PHP_ARG_ENABLE([filter], PHP_ARG_ENABLE([filter],
[whether to enable input filter support], [whether to enable input filter support],
[AS_HELP_STRING([--disable-filter], [AS_HELP_STRING([--disable-filter],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension ftp
PHP_ARG_ENABLE([ftp], PHP_ARG_ENABLE([ftp],
[whether to enable FTP support], [whether to enable FTP support],
[AS_HELP_STRING([--enable-ftp], [AS_HELP_STRING([--enable-ftp],

View file

@ -1,9 +1,6 @@
dnl config.m4 for extension gd
dnl dnl
dnl Configure options dnl Configure options
dnl dnl
PHP_ARG_ENABLE([gd], PHP_ARG_ENABLE([gd],
[for GD support], [for GD support],
[AS_HELP_STRING([--enable-gd], [AS_HELP_STRING([--enable-gd],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension gettext
PHP_ARG_WITH([gettext], PHP_ARG_WITH([gettext],
[for GNU gettext support], [for GNU gettext support],
[AS_HELP_STRING([[--with-gettext[=DIR]]], [AS_HELP_STRING([[--with-gettext[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension hash
PHP_ARG_WITH([mhash], PHP_ARG_WITH([mhash],
[for mhash support], [for mhash support],
[AS_HELP_STRING([[--with-mhash[=DIR]]], [AS_HELP_STRING([[--with-mhash[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension iconv
PHP_ARG_WITH([iconv], PHP_ARG_WITH([iconv],
[for iconv support], [for iconv support],
[AS_HELP_STRING([[--without-iconv[=DIR]]], [AS_HELP_STRING([[--without-iconv[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension imap
AC_DEFUN([IMAP_INC_CHK],[if test -r "$i$1/c-client.h"; then AC_DEFUN([IMAP_INC_CHK],[if test -r "$i$1/c-client.h"; then
AC_DEFINE(HAVE_IMAP2000, 1, [ ]) AC_DEFINE(HAVE_IMAP2000, 1, [ ])
IMAP_DIR=$i IMAP_DIR=$i

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension intl
PHP_ARG_ENABLE([intl], PHP_ARG_ENABLE([intl],
[whether to enable internationalization support], [whether to enable internationalization support],
[AS_HELP_STRING([--enable-intl], [AS_HELP_STRING([--enable-intl],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension json
PHP_ARG_ENABLE([json], PHP_ARG_ENABLE([json],
[whether to enable JavaScript Object Serialization support], [whether to enable JavaScript Object Serialization support],
[AS_HELP_STRING([--disable-json], [AS_HELP_STRING([--disable-json],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension ldap
AC_DEFUN([PHP_LDAP_CHECKS], [ AC_DEFUN([PHP_LDAP_CHECKS], [
if test -f $1/include/ldap.h; then if test -f $1/include/ldap.h; then
LDAP_DIR=$1 LDAP_DIR=$1
@ -15,7 +13,8 @@ AC_DEFUN([PHP_LDAP_CHECKS], [
LDAP_LIBDIR=$1/$PHP_LIBDIR LDAP_LIBDIR=$1/$PHP_LIBDIR
else else
dnl Find Oracle Instant Client RPM header location corresponding to the given lib path e.g. for --with-ldap=/usr/lib/oracle/12.1/client64/lib dnl Find Oracle Instant Client RPM header location corresponding to the
dnl given lib path e.g. for --with-ldap=/usr/lib/oracle/12.1/client64/lib
AC_CHECK_SIZEOF([long]) AC_CHECK_SIZEOF([long])
AC_MSG_CHECKING([if we're at 64-bit platform]) AC_MSG_CHECKING([if we're at 64-bit platform])
AS_IF([test "$ac_cv_sizeof_long" -eq 4],[ AS_IF([test "$ac_cv_sizeof_long" -eq 4],[
@ -114,9 +113,8 @@ if test "$PHP_LDAP" != "no"; then
AC_MSG_ERROR(Cannot find ldap.h) AC_MSG_ERROR(Cannot find ldap.h)
fi fi
dnl The Linux version of the SDK need -lpthread dnl The Linux version of the SDK needs -lpthread. Solaris tested, and it
dnl I have tested Solaris, and it doesn't, but others may. Add dnl doesn't, but others may. Add these here if necessary. -RL
dnl these here if necessary. -RL
dnl Is this really necessary? -Troels Arvin dnl Is this really necessary? -Troels Arvin
if test `uname` = "Linux"; then if test `uname` = "Linux"; then
@ -212,20 +210,16 @@ if test "$PHP_LDAP" != "no"; then
AC_DEFINE(HAVE_3ARG_SETREBINDPROC,1,[Whether 3 arg set_rebind_proc()]) AC_DEFINE(HAVE_3ARG_SETREBINDPROC,1,[Whether 3 arg set_rebind_proc()])
fi fi
dnl Solaris 2.8 claims to be 2004 API, but doesn't have dnl Solaris 2.8 claims to be 2004 API, but doesn't have ldap_parse_reference()
dnl ldap_parse_reference() nor ldap_start_tls_s() dnl nor ldap_start_tls_s()
AC_CHECK_FUNCS([ldap_parse_result ldap_parse_reference ldap_start_tls_s ldap_control_find ldap_parse_extended_result ldap_extended_operation ldap_extended_operation_s ldap_passwd ldap_whoami_s ldap_refresh_s]) AC_CHECK_FUNCS([ldap_parse_result ldap_parse_reference ldap_start_tls_s ldap_control_find ldap_parse_extended_result ldap_extended_operation ldap_extended_operation_s ldap_passwd ldap_whoami_s ldap_refresh_s])
dnl
dnl SASL check dnl SASL check
dnl
if test "$PHP_LDAP_SASL" != "no"; then if test "$PHP_LDAP_SASL" != "no"; then
PHP_LDAP_SASL_CHECKS([$PHP_LDAP_SASL]) PHP_LDAP_SASL_CHECKS([$PHP_LDAP_SASL])
fi fi
dnl
dnl Sanity check dnl Sanity check
dnl
AC_CHECK_FUNC(ldap_bind_s, [], [ AC_CHECK_FUNC(ldap_bind_s, [], [
AC_MSG_ERROR([LDAP build check failed. Please check config.log for more information.]) AC_MSG_ERROR([LDAP build check failed. Please check config.log for more information.])
]) ])

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension libxml
PHP_ARG_WITH([libxml], PHP_ARG_WITH([libxml],
[whether to build with LIBXML support], [whether to build with LIBXML support],
[AS_HELP_STRING([--without-libxml], [AS_HELP_STRING([--without-libxml],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension mbstring
AC_DEFUN([PHP_MBSTRING_ADD_SOURCES], [ AC_DEFUN([PHP_MBSTRING_ADD_SOURCES], [
PHP_MBSTRING_SOURCES="$PHP_MBSTRING_SOURCES $1" PHP_MBSTRING_SOURCES="$PHP_MBSTRING_SOURCES $1"
]) ])

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension mysqli
dnl ext/pdo_mysql/config.m4 also depends on this macro. dnl ext/pdo_mysql/config.m4 also depends on this macro.
AC_DEFUN([PHP_MYSQL_SOCKET_SEARCH], [ AC_DEFUN([PHP_MYSQL_SOCKET_SEARCH], [
for i in \ for i in \

View file

@ -1,5 +1,3 @@
dnl config.m4 for mysqlnd driver
PHP_ARG_ENABLE([mysqlnd], PHP_ARG_ENABLE([mysqlnd],
[whether to enable mysqlnd], [whether to enable mysqlnd],
[AS_HELP_STRING([--enable-mysqlnd], [AS_HELP_STRING([--enable-mysqlnd],

View file

@ -23,7 +23,8 @@ AC_DEFUN([AC_OCI8_CHECK_LIB_DIR],[
elif test -d "$OCI8_DIR/lib" && test -d "$OCI8_DIR/lib32"; then elif test -d "$OCI8_DIR/lib" && test -d "$OCI8_DIR/lib32"; then
OCI8_LIB_DIR=$PHP_OCI8_OH_LIBDIR OCI8_LIB_DIR=$PHP_OCI8_OH_LIBDIR
else else
dnl This isn't an ORACLE_HOME. Try heuristic examination of the dir to help the user dnl This isn't an ORACLE_HOME. Try heuristic examination of the dir to help
dnl the user.
if test -f "$OCI8_DIR/libociei.$SHLIB_SUFFIX_NAME"; then if test -f "$OCI8_DIR/libociei.$SHLIB_SUFFIX_NAME"; then
AC_MSG_ERROR([Expected an ORACLE_HOME top level directory but ${OCI8_DIR} appears to be an Instant Client directory. Try --with-oci8=instantclient,${OCI8_DIR}]) AC_MSG_ERROR([Expected an ORACLE_HOME top level directory but ${OCI8_DIR} appears to be an Instant Client directory. Try --with-oci8=instantclient,${OCI8_DIR}])
else else
@ -36,7 +37,8 @@ AC_DEFUN([AC_OCI8_CHECK_LIB_DIR],[
AC_DEFUN([AC_OCI8IC_VERSION],[ AC_DEFUN([AC_OCI8IC_VERSION],[
AC_MSG_CHECKING([Oracle Instant Client library version compatibility]) AC_MSG_CHECKING([Oracle Instant Client library version compatibility])
OCI8_LCS_BASE=$PHP_OCI8_INSTANT_CLIENT/libclntsh.$SHLIB_SUFFIX_NAME OCI8_LCS_BASE=$PHP_OCI8_INSTANT_CLIENT/libclntsh.$SHLIB_SUFFIX_NAME
OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1` # Oracle 10g, 11g etc dnl Oracle 10g, 11g etc
OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1`
OCI8_NNZ=`ls $PHP_OCI8_INSTANT_CLIENT/libnnz*.$SHLIB_SUFFIX_NAME 2> /dev/null | $PHP_OCI8_TAIL1` OCI8_NNZ=`ls $PHP_OCI8_INSTANT_CLIENT/libnnz*.$SHLIB_SUFFIX_NAME 2> /dev/null | $PHP_OCI8_TAIL1`
if test -f "$OCI8_NNZ" && test -f "$OCI8_LCS"; then if test -f "$OCI8_NNZ" && test -f "$OCI8_LCS"; then
if test ! -f "$OCI8_LCS_BASE"; then if test ! -f "$OCI8_LCS_BASE"; then
@ -52,15 +54,18 @@ AC_DEFUN([AC_OCI8IC_VERSION],[
AC_DEFUN([AC_OCI8_ORACLE_VERSION],[ AC_DEFUN([AC_OCI8_ORACLE_VERSION],[
AC_MSG_CHECKING([Oracle library version compatibility]) AC_MSG_CHECKING([Oracle library version compatibility])
OCI8_LCS_BASE=$OCI8_DIR/$OCI8_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME OCI8_LCS_BASE=$OCI8_DIR/$OCI8_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME
OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1` # Oracle 10g, 11g etc dnl Oracle 10g, 11g etc
OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1`
if test -s "$OCI8_DIR/orainst/unix.rgs"; then if test -s "$OCI8_DIR/orainst/unix.rgs"; then
OCI8_ORACLE_VERSION=`grep '"ocommon"' $OCI8_DIR/orainst/unix.rgs | $PHP_OCI8_SED 's/[ ][ ]*/:/g' | cut -d: -f 6 | cut -c 2-4` OCI8_ORACLE_VERSION=`grep '"ocommon"' $OCI8_DIR/orainst/unix.rgs | $PHP_OCI8_SED 's/[ ][ ]*/:/g' | cut -d: -f 6 | cut -c 2-4`
test -z "$OCI8_ORACLE_VERSION" && OCI8_ORACLE_VERSION=7.3 test -z "$OCI8_ORACLE_VERSION" && OCI8_ORACLE_VERSION=7.3
elif test -f "$OCI8_LCS"; then elif test -f "$OCI8_LCS"; then
dnl Oracle 10g, 11g etc. The x.2 version libraries are named x.1 for drop in compatibility dnl Oracle 10g, 11g etc. The x.2 version libraries are named x.1 for drop in
dnl compatibility
OCI8_ORACLE_VERSION=`echo $OCI8_LCS | $PHP_OCI8_SED -e 's/.*\.\(.*\)\.1$/\1.1/'` OCI8_ORACLE_VERSION=`echo $OCI8_LCS | $PHP_OCI8_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
elif test -f $OCI8_LCS_BASE.9.0; then elif test -f $OCI8_LCS_BASE.9.0; then
dnl There is no case for Oracle 9.2. Oracle 9.2 libraries have a 9.0 suffix for drop-in compatibility with Oracle 9.0 dnl There is no case for Oracle 9.2. Oracle 9.2 libraries have a 9.0 suffix
dnl for drop-in compatibility with Oracle 9.0
OCI8_ORACLE_VERSION=9.0 OCI8_ORACLE_VERSION=9.0
elif test -f $OCI8_LCS_BASE.8.0; then elif test -f $OCI8_LCS_BASE.8.0; then
OCI8_ORACLE_VERSION=8.1 OCI8_ORACLE_VERSION=8.1
@ -80,12 +85,11 @@ AC_DEFUN([AC_OCI8_ORACLE_VERSION],[
dnl dnl
dnl OCI8_INIT_DTRACE(providerdesc, header-file, sources) dnl OCI8_INIT_DTRACE(providerdesc, header-file, sources)
dnl This mimics PHP_INIT_DTRACE from PHP 5.4's acinclude.m4. It is dnl This mimics PHP_INIT_DTRACE from build/php.m4. It is necessarily different
dnl necessarily different from PHP_INIT_DTRACE which doesn't currently dnl from PHP_INIT_DTRACE which doesn't currently support DTrace for extensions.
dnl support DTrace for extensions. Creating OCI8_INIT_DTRACE dnl Creating OCI8_INIT_DTRACE independently instead of using a refactored
dnl independently instead of using a refactored PHP_INIT_DTRACE allows dnl PHP_INIT_DTRACE allows OCI8 to be DTraced on versions of PHP where core PHP
dnl OCI8 to be DTraced on versions of PHP where core PHP DTrace support dnl DTrace support isn't available.
dnl isn't available.
dnl dnl
AC_DEFUN([OCI8_INIT_DTRACE],[ AC_DEFUN([OCI8_INIT_DTRACE],[
ac_srcdir=[]PHP_EXT_SRCDIR([oci8])/ ac_srcdir=[]PHP_EXT_SRCDIR([oci8])/
@ -112,9 +116,9 @@ dnl DTrace objects
dtrace_oci8_objs="[$]dtrace_oci8_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`" dtrace_oci8_objs="[$]dtrace_oci8_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
done; done;
dnl Generate Makefile.objects entry dnl Generate Makefile.objects entry. The empty $ac_provsrc command stops an
dnl The empty $ac_provsrc command stops an implicit circular dependency dnl implicit circular dependency in GNU Make which causes the .d file to be
dnl in GNU Make which causes the .d file to be overwritten (Bug 61268) dnl overwritten (Bug 61268).
cat>>Makefile.objects<<EOF cat>>Makefile.objects<<EOF
PHP_EXT_SRCDIR([oci8])/$ac_provsrc:; PHP_EXT_SRCDIR([oci8])/$ac_provsrc:;
@ -135,7 +139,8 @@ EOF
for ac_lo in $OCI8_DTRACE_OBJS; do for ac_lo in $OCI8_DTRACE_OBJS; do
dtrace_oci8_lib_objs="[$]dtrace_oci8_lib_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`" dtrace_oci8_lib_objs="[$]dtrace_oci8_lib_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
done; done;
dnl Always attempt to create both PIC and non-PIC DTrace objects (Bug 63692)
dnl Always attempt to create both PIC and non-PIC DTrace objects (Bug 63692)
cat>>Makefile.objects<<EOF cat>>Makefile.objects<<EOF
$ac_bdir[$]ac_provsrc.lo: \$(OCI8_DTRACE_OBJS) $ac_bdir[$]ac_provsrc.lo: \$(OCI8_DTRACE_OBJS)
echo "[#] Generated by Makefile for libtool" > \$[]@ echo "[#] Generated by Makefile for libtool" > \$[]@
@ -164,7 +169,6 @@ EOF
esac esac
]) ])
dnl --with-oci8=shared,instantclient,/path/to/client/dir/lib dnl --with-oci8=shared,instantclient,/path/to/client/dir/lib
dnl or dnl or
dnl --with-oci8=shared,/path/to/oracle/home dnl --with-oci8=shared,/path/to/oracle/home
@ -178,12 +182,12 @@ PHP_ARG_WITH([oci8],
if test "$PHP_OCI8" != "no"; then if test "$PHP_OCI8" != "no"; then
if test -z "$PHP_OCI8"; then if test -z "$PHP_OCI8"; then
dnl --with-oci8=$ORACLE_HOME where ORACLE_HOME isn't set (or is mistyped) will match this case dnl --with-oci8=$ORACLE_HOME where ORACLE_HOME isn't set (or is mistyped)
dnl will match this case.
AC_MSG_ERROR([Empty parameter value passed to --with-oci8]) AC_MSG_ERROR([Empty parameter value passed to --with-oci8])
fi fi
dnl Check PHP version is compatible with this extension dnl Check PHP version is compatible with this extension.
AC_MSG_CHECKING([PHP version]) AC_MSG_CHECKING([PHP version])
tmp_version=$PHP_VERSION tmp_version=$PHP_VERSION
@ -212,9 +216,9 @@ if test "$PHP_OCI8" != "no"; then
AC_MSG_RESULT([$php_version, ok]) AC_MSG_RESULT([$php_version, ok])
fi fi
dnl Check whether --enable-dtrace was set. dnl Check whether --enable-dtrace was set. To use DTrace with a PECL install,
dnl To use DTrace with a PECL install, extract the OCI8 archive, phpize it, and set dnl extract the OCI8 archive, phpize it, and set PHP_DTRACE=yes before running
dnl PHP_DTRACE=yes before running configure dnl configure.
AC_MSG_CHECKING([OCI8 DTrace support]) AC_MSG_CHECKING([OCI8 DTrace support])
oci8_do_dtrace="`echo $PHP_OCI8 | cut -d, -f3`" oci8_do_dtrace="`echo $PHP_OCI8 | cut -d, -f3`"
if test "$PHP_DTRACE" = "yes" -o "$oci8_do_dtrace" = "dtrace" ; then if test "$PHP_DTRACE" = "yes" -o "$oci8_do_dtrace" = "dtrace" ; then
@ -231,14 +235,15 @@ if test "$PHP_OCI8" != "no"; then
]) ])
PHP_SUBST(OCI8_DTRACE_OBJS) PHP_SUBST(OCI8_DTRACE_OBJS)
AC_DEFINE(HAVE_OCI8_DTRACE,1,[Defined to 1 if PHP OCI8 DTrace support was enabled during configuration]) AC_DEFINE(HAVE_OCI8_DTRACE,1,[Defined to 1 if PHP OCI8 DTrace support was enabled during configuration])
dnl Developer warning: hard coded extension is OK for the known supported environments dnl Developer warning: hard coded extension is OK for the known supported
dnl environments.
shared_objects_oci8="$shared_objects_oci8 PHP_EXT_BUILDDIR(oci8)/oci8_dtrace.d.lo" shared_objects_oci8="$shared_objects_oci8 PHP_EXT_BUILDDIR(oci8)/oci8_dtrace.d.lo"
fi fi
else else
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
fi fi
dnl Set some port specific directory components for use later dnl Set some port specific directory components for use later.
AC_CHECK_SIZEOF([long]) AC_CHECK_SIZEOF([long])
AC_MSG_CHECKING([if we're at 64-bit platform]) AC_MSG_CHECKING([if we're at 64-bit platform])
AS_IF([test "$ac_cv_sizeof_long" -eq 4],[ AS_IF([test "$ac_cv_sizeof_long" -eq 4],[
@ -251,15 +256,15 @@ if test "$PHP_OCI8" != "no"; then
PHP_OCI8_IC_LIBDIR_SUFFIX=64 PHP_OCI8_IC_LIBDIR_SUFFIX=64
]) ])
dnl Determine if the user wants to use Oracle Instant Client libraries dnl Determine if the user wants to use Oracle Instant Client libraries.
PHP_OCI8_INSTANT_CLIENT="no" PHP_OCI8_INSTANT_CLIENT="no"
dnl PECL Bug 14268 (Allow "pecl install oci8" command to "autodetect" dnl PECL Bug 14268 (Allow "pecl install oci8" command to "autodetect" an
dnl an Instant Client RPM install). This also has a benefit for non dnl Instant Client RPM install). This also has a benefit for non
dnl "pecl install" builds: if the user does --with-oci8 or dnl "pecl install" builds: if the user does --with-oci8 or --with-oci8=shared
dnl --with-oci8=shared but the ORACLE_HOME environment variable is not dnl but the ORACLE_HOME environment variable is not actually set, the install
dnl actually set, the install tries to locate the Instant Client RPM dnl tries to locate the Instant Client RPM.
if test "$PHP_OCI8" = "yes" && test -z "$ORACLE_HOME"; then if test "$PHP_OCI8" = "yes" && test -z "$ORACLE_HOME"; then
AC_MSG_WARN([OCI8 extension: ORACLE_HOME is not set, looking for default Oracle Instant Client instead]) AC_MSG_WARN([OCI8 extension: ORACLE_HOME is not set, looking for default Oracle Instant Client instead])
PHP_OCI8=instantclient PHP_OCI8=instantclient
@ -355,11 +360,11 @@ if test "$PHP_OCI8" != "no"; then
AC_MSG_CHECKING([Oracle Instant Client directory]) AC_MSG_CHECKING([Oracle Instant Client directory])
if test "$PHP_OCI8_INSTANT_CLIENT" = "yes"; then if test "$PHP_OCI8_INSTANT_CLIENT" = "yes"; then
dnl Find the directory if user specified "instantclient" but did not dnl Find the directory if user specified "instantclient" but did not give
dnl give a dir. Generally the Instant Client can be anywhere so the dnl a dir. Generally the Instant Client can be anywhere so the user must
dnl user must pass in the library directory. But on Linux we default dnl pass in the library directory. But on Linux we default to the most
dnl to the most recent version in /usr/lib which is where the Oracle dnl recent version in /usr/lib which is where the Oracle Instant Client
dnl Instant Client RPM gets installed. dnl RPM gets installed.
PHP_OCI8_INSTANT_CLIENT=`ls -d /usr/lib/oracle/*/client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib/libclntsh.* 2> /dev/null | $PHP_OCI8_TAIL1 | $PHP_OCI8_SED -e 's#/libclntsh[^/]*##'` PHP_OCI8_INSTANT_CLIENT=`ls -d /usr/lib/oracle/*/client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib/libclntsh.* 2> /dev/null | $PHP_OCI8_TAIL1 | $PHP_OCI8_SED -e 's#/libclntsh[^/]*##'`
if test -z "$PHP_OCI8_INSTANT_CLIENT"; then if test -z "$PHP_OCI8_INSTANT_CLIENT"; then
AC_MSG_ERROR([Oracle Instant Client directory /usr/lib/oracle/.../client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib libraries not found. Try --with-oci8=instantclient,DIR]) AC_MSG_ERROR([Oracle Instant Client directory /usr/lib/oracle/.../client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib libraries not found. Try --with-oci8=instantclient,DIR])

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension odbc
AC_DEFUN([PHP_ODBC_CHECK_HEADER],[ AC_DEFUN([PHP_ODBC_CHECK_HEADER],[
if ! test -f "$ODBC_INCDIR/$1"; then if ! test -f "$ODBC_INCDIR/$1"; then
AC_MSG_ERROR([ODBC header file '$ODBC_INCDIR/$1' not found!]) AC_MSG_ERROR([ODBC header file '$ODBC_INCDIR/$1' not found!])
@ -48,14 +46,10 @@ AC_DEFUN([PHP_ODBC_FIND_SOLID_LIBS],[
ac_solid_prefix=scl ac_solid_prefix=scl
fi fi
# dnl Check for the library files, and setup the ODBC_LIBS path.
# Check for the library files, and setup the ODBC_LIBS path...
#
if test ! -f $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so -a \ if test ! -f $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so -a \
! -f $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a; then ! -f $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a; then
# dnl we have an error and should bail out, as we can't find the libs!
# we have an error and should bail out, as we can't find the libs!
#
echo "" echo ""
echo "*********************************************************************" echo "*********************************************************************"
echo "* Unable to locate $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so or $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a" echo "* Unable to locate $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so or $1/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a"
@ -393,10 +387,10 @@ PHP_ARG_WITH([dbmaker],,
AC_MSG_CHECKING(for DBMaker support) AC_MSG_CHECKING(for DBMaker support)
if test "$PHP_DBMAKER" != "no"; then if test "$PHP_DBMAKER" != "no"; then
if test "$PHP_DBMAKER" = "yes"; then if test "$PHP_DBMAKER" = "yes"; then
# find dbmaker's home directory dnl Find dbmaker's home directory
DBMAKER_HOME=`grep "^dbmaker:" /etc/passwd | $AWK -F: '{print $6}'` DBMAKER_HOME=`grep "^dbmaker:" /etc/passwd | $AWK -F: '{print $6}'`
# check DBMaker version (from 5.0 to 2.0) dnl check DBMaker version (from 5.0 to 2.0)
DBMAKER_VERSION=5.0 DBMAKER_VERSION=5.0
while test ! -d $DBMAKER_HOME/$DBMAKER_VERSION -a "$DBMAKER_VERSION" != "2.9"; do while test ! -d $DBMAKER_HOME/$DBMAKER_VERSION -a "$DBMAKER_VERSION" != "2.9"; do
@ -445,10 +439,7 @@ else
AC_DEFINE(ODBCVER, 0x0300, [ The highest supported ODBC version ]) AC_DEFINE(ODBCVER, 0x0300, [ The highest supported ODBC version ])
fi fi
dnl
dnl Extension setup dnl Extension setup
dnl
if test -n "$ODBC_TYPE"; then if test -n "$ODBC_TYPE"; then
if test "$ODBC_TYPE" != "dbmaker"; then if test "$ODBC_TYPE" != "dbmaker"; then
PHP_EVAL_LIBLINE([$ODBC_LFLAGS $ODBC_LIBS], ODBC_SHARED_LIBADD) PHP_EVAL_LIBLINE([$ODBC_LFLAGS $ODBC_LIBS], ODBC_SHARED_LIBADD)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension opcache
PHP_ARG_ENABLE([opcache], PHP_ARG_ENABLE([opcache],
[whether to enable Zend OPcache support], [whether to enable Zend OPcache support],
[AS_HELP_STRING([--disable-opcache], [AS_HELP_STRING([--disable-opcache],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension openssl
PHP_ARG_WITH([openssl], PHP_ARG_WITH([openssl],
[for OpenSSL support], [for OpenSSL support],
[AS_HELP_STRING([--with-openssl], [AS_HELP_STRING([--with-openssl],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pcntl
PHP_ARG_ENABLE([pcntl], PHP_ARG_ENABLE([pcntl],
[whether to enable pcntl support], [whether to enable pcntl support],
[AS_HELP_STRING([--enable-pcntl], [AS_HELP_STRING([--enable-pcntl],

View file

@ -1,8 +1,5 @@
dnl config.m4 for extension pcre dnl By default we'll compile and link against the bundled PCRE library. If
dnl --with-external-pcre is supplied, we'll use that for linking.
dnl By default we'll compile and link against the bundled PCRE library
dnl if DIR is supplied, we'll use that for linking
PHP_ARG_WITH([external-pcre],, PHP_ARG_WITH([external-pcre],,
[AS_HELP_STRING([--with-external-pcre], [AS_HELP_STRING([--with-external-pcre],
[Use external library for PCRE support])], [Use external library for PCRE support])],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo
PHP_ARG_ENABLE([pdo], PHP_ARG_ENABLE([pdo],
[whether to enable PDO support], [whether to enable PDO support],
[AS_HELP_STRING([--disable-pdo], [AS_HELP_STRING([--disable-pdo],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_dblib
PHP_ARG_WITH([pdo-dblib], PHP_ARG_WITH([pdo-dblib],
[for PDO_DBLIB support via FreeTDS], [for PDO_DBLIB support via FreeTDS],
[AS_HELP_STRING([[--with-pdo-dblib[=DIR]]], [AS_HELP_STRING([[--with-pdo-dblib[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_mysql
PHP_ARG_WITH([pdo-mysql], PHP_ARG_WITH([pdo-mysql],
[for MySQL support for PDO], [for MySQL support for PDO],
[AS_HELP_STRING([[--with-pdo-mysql[=DIR]]], [AS_HELP_STRING([[--with-pdo-mysql[=DIR]]],
@ -16,8 +14,8 @@ if test -z "$PHP_ZLIB_DIR"; then
fi fi
if test "$PHP_PDO_MYSQL" != "no"; then if test "$PHP_PDO_MYSQL" != "no"; then
dnl This depends on ext/mysqli/config.m4 providing the dnl This depends on ext/mysqli/config.m4 providing the PHP_MYSQL_SOCKET_SEARCH
dnl PHP_MYSQL_SOCKET_SEARCH macro and --with-mysql-sock configure option. dnl macro and --with-mysql-sock configure option.
AC_MSG_CHECKING([for MySQL UNIX socket location]) AC_MSG_CHECKING([for MySQL UNIX socket location])
if test "$PHP_MYSQL_SOCK" != "no" && test "$PHP_MYSQL_SOCK" != "yes"; then if test "$PHP_MYSQL_SOCK" != "no" && test "$PHP_MYSQL_SOCK" != "yes"; then
MYSQL_SOCK=$PHP_MYSQL_SOCK MYSQL_SOCK=$PHP_MYSQL_SOCK

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_oci
if test -z "$SED"; then if test -z "$SED"; then
PHP_PDO_OCI_SED="sed"; PHP_PDO_OCI_SED="sed";
else else
@ -16,12 +14,15 @@ fi
AC_DEFUN([AC_PDO_OCI_VERSION],[ AC_DEFUN([AC_PDO_OCI_VERSION],[
AC_MSG_CHECKING([Oracle version]) AC_MSG_CHECKING([Oracle version])
PDO_OCI_LCS_BASE=$PDO_OCI_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME PDO_OCI_LCS_BASE=$PDO_OCI_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME
PDO_OCI_LCS=`ls $PDO_OCI_LCS_BASE.*.1 2> /dev/null | $PHP_PDO_OCI_TAIL1` # Oracle 10g, 11g, 12c etc dnl Oracle 10g, 11g, 12c etc
PDO_OCI_LCS=`ls $PDO_OCI_LCS_BASE.*.1 2> /dev/null | $PHP_PDO_OCI_TAIL1`
if test -f "$PDO_OCI_LCS"; then if test -f "$PDO_OCI_LCS"; then
dnl Oracle 10g, 11g 12c etc. The x.2 version libraries are named x.1 for drop in compatibility dnl Oracle 10g, 11g 12c etc. The x.2 version libraries are named x.1 for
dnl drop in compatibility
PDO_OCI_VERSION=`echo $PDO_OCI_LCS | $PHP_PDO_OCI_SED -e 's/.*\.\(.*\)\.1$/\1.1/'` PDO_OCI_VERSION=`echo $PDO_OCI_LCS | $PHP_PDO_OCI_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
elif test -f $PDO_OCI_LCS_BASE.9.0; then elif test -f $PDO_OCI_LCS_BASE.9.0; then
dnl There is no case for Oracle 9.2. Oracle 9.2 libraries have a 9.0 suffix for drop-in compatibility with Oracle 9.0 dnl There is no case for Oracle 9.2. Oracle 9.2 libraries have a 9.0 suffix
dnl for drop-in compatibility with Oracle 9.0
PDO_OCI_VERSION=9.0 PDO_OCI_VERSION=9.0
else else
AC_MSG_ERROR(Oracle libclntsh.$SHLIB_SUFFIX_NAME client library not found or its version is lower than 9) AC_MSG_ERROR(Oracle libclntsh.$SHLIB_SUFFIX_NAME client library not found or its version is lower than 9)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_odbc
define([PDO_ODBC_HELP_TEXT],[[ define([PDO_ODBC_HELP_TEXT],[[
The include and lib dirs are looked for under 'dir'. The 'flavour' can be one The include and lib dirs are looked for under 'dir'. The 'flavour' can be one
of: ibm-db2, iODBC, unixODBC, generic. If ',dir' part is omitted, default for of: ibm-db2, iODBC, unixODBC, generic. If ',dir' part is omitted, default for
@ -141,8 +139,8 @@ if test "$PHP_PDO_ODBC" != "no"; then
dnl Check first for an ODBC 1.0 function to assert that the libraries work dnl Check first for an ODBC 1.0 function to assert that the libraries work
PHP_CHECK_LIBRARY($pdo_odbc_def_lib, SQLBindCol, PHP_CHECK_LIBRARY($pdo_odbc_def_lib, SQLBindCol,
[ [
dnl And now check for an ODBC 3.0 function to assert that they're dnl And now check for an ODBC 3.0 function to assert that they're *good*
dnl *good* libraries. dnl libraries.
PHP_CHECK_LIBRARY($pdo_odbc_def_lib, SQLAllocHandle, PHP_CHECK_LIBRARY($pdo_odbc_def_lib, SQLAllocHandle,
[], [ [], [
AC_MSG_ERROR([ AC_MSG_ERROR([

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_pgsql
PHP_ARG_WITH([pdo-pgsql], PHP_ARG_WITH([pdo-pgsql],
[for PostgreSQL support for PDO], [for PostgreSQL support for PDO],
[AS_HELP_STRING([[--with-pdo-pgsql[=DIR]]], [AS_HELP_STRING([[--with-pdo-pgsql[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pdo_sqlite
PHP_ARG_WITH([pdo-sqlite], PHP_ARG_WITH([pdo-sqlite],
[for sqlite 3 support for PDO], [for sqlite 3 support for PDO],
[AS_HELP_STRING([[--without-pdo-sqlite[=DIR]]], [AS_HELP_STRING([[--without-pdo-sqlite[=DIR]]],
@ -32,11 +30,15 @@ if test "$PHP_PDO_SQLITE" != "no"; then
php_pdo_sqlite_sources_core="pdo_sqlite.c sqlite_driver.c sqlite_statement.c" php_pdo_sqlite_sources_core="pdo_sqlite.c sqlite_driver.c sqlite_statement.c"
SEARCH_PATH="$PHP_PDO_SQLITE /usr/local /usr" # you might want to change this dnl you might want to change this
SEARCH_FOR="/include/sqlite3.h" # you most likely want to change this SEARCH_PATH="$PHP_PDO_SQLITE /usr/local /usr"
if test -r $PHP_PDO_SQLITE/$SEARCH_FOR; then # path given as parameter dnl you most likely want to change this
SEARCH_FOR="/include/sqlite3.h"
if test -r $PHP_PDO_SQLITE/$SEARCH_FOR; then
dnl path given as parameter
PDO_SQLITE_DIR=$PHP_PDO_SQLITE PDO_SQLITE_DIR=$PHP_PDO_SQLITE
else # search default path list else
dnl search default path list
AC_MSG_CHECKING([for sqlite3 files in default path]) AC_MSG_CHECKING([for sqlite3 files in default path])
for i in $SEARCH_PATH ; do for i in $SEARCH_PATH ; do
if test -r $i/$SEARCH_FOR; then if test -r $i/$SEARCH_FOR; then

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pgsql
PHP_ARG_WITH([pgsql], PHP_ARG_WITH([pgsql],
[for PostgreSQL support], [for PostgreSQL support],
[AS_HELP_STRING([[--with-pgsql[=DIR]]], [AS_HELP_STRING([[--with-pgsql[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension phar
PHP_ARG_ENABLE([phar], PHP_ARG_ENABLE([phar],
[for phar archive support], [for phar archive support],
[AS_HELP_STRING([--disable-phar], [AS_HELP_STRING([--disable-phar],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension posix
PHP_ARG_ENABLE([posix], PHP_ARG_ENABLE([posix],
[whether to enable POSIX-like functions], [whether to enable POSIX-like functions],
[AS_HELP_STRING([--disable-posix], [AS_HELP_STRING([--disable-posix],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension pspell
PHP_ARG_WITH([pspell], PHP_ARG_WITH([pspell],
[for PSPELL support], [for PSPELL support],
[AS_HELP_STRING([[--with-pspell[=DIR]]], [AS_HELP_STRING([[--with-pspell[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension readline
PHP_ARG_WITH([libedit], PHP_ARG_WITH([libedit],
[for libedit readline replacement], [for libedit readline replacement],
[AS_HELP_STRING([--with-libedit], [AS_HELP_STRING([--with-libedit],
@ -11,7 +9,8 @@ if test "$PHP_LIBEDIT" = "no"; then
[AS_HELP_STRING([[--with-readline[=DIR]]], [AS_HELP_STRING([[--with-readline[=DIR]]],
[Include readline support (CLI/CGI only)])]) [Include readline support (CLI/CGI only)])])
else else
dnl "register" the --with-readline option to preven invalid "unknown configure option" warning dnl "register" the --with-readline option to prevent invalid "unknown
dnl configure option" warning
php_with_readline=no php_with_readline=no
fi fi

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension recode
PHP_ARG_WITH([recode], PHP_ARG_WITH([recode],
[for recode support], [for recode support],
[AS_HELP_STRING([[--with-recode[=DIR]]], [AS_HELP_STRING([[--with-recode[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension recode
dnl Check for extensions with which Recode can not work dnl Check for extensions with which Recode can not work
if test "$PHP_RECODE" != "no"; then if test "$PHP_RECODE" != "no"; then
test "$PHP_IMAP" != "no" && recode_conflict="$recode_conflict imap" test "$PHP_IMAP" != "no" && recode_conflict="$recode_conflict imap"

View file

@ -1,3 +1 @@
dnl config.m4 for extension reflection
PHP_NEW_EXTENSION(reflection, php_reflection.c, no,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1) PHP_NEW_EXTENSION(reflection, php_reflection.c, no,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension session
PHP_ARG_ENABLE([session], PHP_ARG_ENABLE([session],
[whether to enable PHP sessions], [whether to enable PHP sessions],
[AS_HELP_STRING([--disable-session], [AS_HELP_STRING([--disable-session],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension shmop
PHP_ARG_ENABLE([shmop], PHP_ARG_ENABLE([shmop],
[whether to enable shmop support], [whether to enable shmop support],
[AS_HELP_STRING([--enable-shmop], [AS_HELP_STRING([--enable-shmop],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension simplexml
PHP_ARG_ENABLE([simplexml], PHP_ARG_ENABLE([simplexml],
[whether to enable SimpleXML support], [whether to enable SimpleXML support],
[AS_HELP_STRING([--disable-simplexml], [AS_HELP_STRING([--disable-simplexml],

View file

@ -33,7 +33,7 @@ if test "$PHP_%EXTNAMECAPS%" != "no"; then
dnl PKG_CHECK_MODULES([LIBFOO], [foo = 1.2.3]) dnl PKG_CHECK_MODULES([LIBFOO], [foo = 1.2.3])
dnl Remove this code block if the library supports pkg-config. dnl Remove this code block if the library supports pkg-config.
dnl # --with-%EXTNAME% -> check with-path dnl --with-%EXTNAME% -> check with-path
dnl SEARCH_PATH="/usr/local /usr" # you might want to change this dnl SEARCH_PATH="/usr/local /usr" # you might want to change this
dnl SEARCH_FOR="/include/%EXTNAME%.h" # you most likely want to change this dnl SEARCH_FOR="/include/%EXTNAME%.h" # you most likely want to change this
dnl if test -r $PHP_%EXTNAMECAPS%/$SEARCH_FOR; then # path given as parameter dnl if test -r $PHP_%EXTNAMECAPS%/$SEARCH_FOR; then # path given as parameter
@ -54,11 +54,11 @@ if test "$PHP_%EXTNAMECAPS%" != "no"; then
dnl fi dnl fi
dnl Remove this code block if the library supports pkg-config. dnl Remove this code block if the library supports pkg-config.
dnl # --with-%EXTNAME% -> add include path dnl --with-%EXTNAME% -> add include path
dnl PHP_ADD_INCLUDE($%EXTNAMECAPS%_DIR/include) dnl PHP_ADD_INCLUDE($%EXTNAMECAPS%_DIR/include)
dnl Remove this code block if the library supports pkg-config. dnl Remove this code block if the library supports pkg-config.
dnl # --with-%EXTNAME% -> check for lib and symbol presence dnl --with-%EXTNAME% -> check for lib and symbol presence
dnl LIBNAME=%EXTNAMECAPS% # you may want to change this dnl LIBNAME=%EXTNAMECAPS% # you may want to change this
dnl LIBSYMBOL=%EXTNAMECAPS% # you most likely want to change this dnl LIBSYMBOL=%EXTNAMECAPS% # you most likely want to change this
@ -87,7 +87,7 @@ if test "$PHP_%EXTNAMECAPS%" != "no"; then
dnl dnl
dnl PHP_SUBST(%EXTNAMECAPS%_SHARED_LIBADD) dnl PHP_SUBST(%EXTNAMECAPS%_SHARED_LIBADD)
dnl # In case of no dependencies dnl In case of no dependencies
AC_DEFINE(HAVE_%EXTNAMECAPS%, 1, [ Have %EXTNAME% support ]) AC_DEFINE(HAVE_%EXTNAMECAPS%, 1, [ Have %EXTNAME% support ])
PHP_NEW_EXTENSION(%EXTNAME%, %EXTNAME%.c, $ext_shared) PHP_NEW_EXTENSION(%EXTNAME%, %EXTNAME%.c, $ext_shared)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension snmp
PHP_ARG_WITH([snmp], PHP_ARG_WITH([snmp],
[for SNMP support], [for SNMP support],
[AS_HELP_STRING([[--with-snmp[=DIR]]], [AS_HELP_STRING([[--with-snmp[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension soap
PHP_ARG_ENABLE([soap], PHP_ARG_ENABLE([soap],
[whether to enable SOAP support], [whether to enable SOAP support],
[AS_HELP_STRING([--enable-soap], [AS_HELP_STRING([--enable-soap],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sockets
PHP_ARG_ENABLE([sockets], PHP_ARG_ENABLE([sockets],
[whether to enable sockets support], [whether to enable sockets support],
[AS_HELP_STRING([--enable-sockets], [AS_HELP_STRING([--enable-sockets],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sodium
PHP_ARG_WITH([sodium], PHP_ARG_WITH([sodium],
[for sodium support], [for sodium support],
[AS_HELP_STRING([--with-sodium], [AS_HELP_STRING([--with-sodium],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension SPL PHP_NEW_EXTENSION(spl, php_spl.c spl_functions.c spl_engine.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c, no,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
PHP_INSTALL_HEADERS([ext/spl], [php_spl.h spl_array.h spl_directory.h spl_engine.h spl_exceptions.h spl_functions.h spl_iterators.h spl_observer.h spl_dllist.h spl_heap.h spl_fixedarray.h])
PHP_NEW_EXTENSION(spl, php_spl.c spl_functions.c spl_engine.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c, no,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1) PHP_ADD_EXTENSION_DEP(spl, pcre, true)
PHP_INSTALL_HEADERS([ext/spl], [php_spl.h spl_array.h spl_directory.h spl_engine.h spl_exceptions.h spl_functions.h spl_iterators.h spl_observer.h spl_dllist.h spl_heap.h spl_fixedarray.h])
PHP_ADD_EXTENSION_DEP(spl, pcre, true)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sqlite3
PHP_ARG_WITH([sqlite3], PHP_ARG_WITH([sqlite3],
[whether to enable the SQLite3 extension], [whether to enable the SQLite3 extension],
[AS_HELP_STRING([[--without-sqlite3[=DIR]]], [AS_HELP_STRING([[--without-sqlite3[=DIR]]],

View file

@ -284,14 +284,14 @@ fi
dnl dnl
dnl Check for available functions dnl Check for available functions
dnl dnl
dnl log2 could be used to improve the log function, however it requires C99. The check for log2 should be turned on, dnl log2 could be used to improve the log function, however it requires C99. The
dnl as soon as we support C99. dnl check for log2 should be turned on, as soon as we support C99.
AC_CHECK_FUNCS(getcwd getwd asinh acosh atanh log1p hypot glob strfmon nice fpclass mempcpy strpncpy) AC_CHECK_FUNCS(getcwd getwd asinh acosh atanh log1p hypot glob strfmon nice fpclass mempcpy strpncpy)
AC_FUNC_FNMATCH AC_FUNC_FNMATCH
dnl dnl
dnl Check if there is a support means of creating a new process dnl Check if there is a support means of creating a new process and defining
dnl and defining which handles it receives dnl which handles it receives
dnl dnl
AC_CHECK_FUNCS(fork CreateProcess, [ AC_CHECK_FUNCS(fork CreateProcess, [
php_can_support_proc_open=yes php_can_support_proc_open=yes
@ -335,7 +335,8 @@ fi
dnl dnl
dnl Detect library functions needed by php dns_xxx functions dnl Detect library functions needed by php dns_xxx functions
dnl ext/standard/php_dns.h will collect these in a single define: HAVE_FULL_DNS_FUNCS dnl ext/standard/php_dns.h will collect these in a single define
dnl HAVE_FULL_DNS_FUNCS
dnl dnl
PHP_CHECK_FUNC(res_nsearch, resolv, bind, socket) PHP_CHECK_FUNC(res_nsearch, resolv, bind, socket)
PHP_CHECK_FUNC(res_ndestroy, resolv, bind, socket) PHP_CHECK_FUNC(res_ndestroy, resolv, bind, socket)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sysvmsg
PHP_ARG_ENABLE([sysvmsg], PHP_ARG_ENABLE([sysvmsg],
[whether to enable System V IPC support], [whether to enable System V IPC support],
[AS_HELP_STRING([--enable-sysvmsg], [AS_HELP_STRING([--enable-sysvmsg],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sysvsem
PHP_ARG_ENABLE([sysvsem], PHP_ARG_ENABLE([sysvsem],
[whether to enable System V semaphore support], [whether to enable System V semaphore support],
[AS_HELP_STRING([--enable-sysvsem], [AS_HELP_STRING([--enable-sysvsem],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension sysvshm
PHP_ARG_ENABLE([sysvshm], PHP_ARG_ENABLE([sysvshm],
[whether to enable System V shared memory support], [whether to enable System V shared memory support],
[AS_HELP_STRING([--enable-sysvshm], [AS_HELP_STRING([--enable-sysvshm],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension tidy
PHP_ARG_WITH([tidy], PHP_ARG_WITH([tidy],
[for TIDY support], [for TIDY support],
[AS_HELP_STRING([[--with-tidy[=DIR]]], [AS_HELP_STRING([[--with-tidy[=DIR]]],
@ -32,10 +30,9 @@ if test "$PHP_TIDY" != "no"; then
if test -z "$TIDY_DIR"; then if test -z "$TIDY_DIR"; then
AC_MSG_ERROR(Cannot find libtidy) AC_MSG_ERROR(Cannot find libtidy)
else else
dnl Check for tidybuffio.h (as opposed to simply buffio.h) dnl Check for tidybuffio.h (as opposed to simply buffio.h) which indicates
dnl which indicates that we are building against tidy-html5 dnl that we are building against tidy-html5 and not the legacy htmltidy. The
dnl and not the legacy htmltidy. The two are compatible, dnl two are compatible, except for with regard to this header file.
dnl except for with regard to this header file.
if test -f "$TIDY_INCDIR/tidybuffio.h"; then if test -f "$TIDY_INCDIR/tidybuffio.h"; then
AC_DEFINE(HAVE_TIDYBUFFIO_H,1,[defined if tidybuffio.h exists]) AC_DEFINE(HAVE_TIDYBUFFIO_H,1,[defined if tidybuffio.h exists])
fi fi

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension tokenizer
PHP_ARG_ENABLE([tokenizer], PHP_ARG_ENABLE([tokenizer],
[whether to enable tokenizer support], [whether to enable tokenizer support],
[AS_HELP_STRING([--disable-tokenizer], [AS_HELP_STRING([--disable-tokenizer],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension xml
PHP_ARG_ENABLE([xml], PHP_ARG_ENABLE([xml],
[whether to enable XML support], [whether to enable XML support],
[AS_HELP_STRING([--disable-xml], [AS_HELP_STRING([--disable-xml],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension xmlreader
PHP_ARG_ENABLE([xmlreader], PHP_ARG_ENABLE([xmlreader],
[whether to enable XMLReader support], [whether to enable XMLReader support],
[AS_HELP_STRING([--disable-xmlreader], [AS_HELP_STRING([--disable-xmlreader],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension xmlrpc
PHP_ARG_WITH([xmlrpc], PHP_ARG_WITH([xmlrpc],
[for XMLRPC-EPI support], [for XMLRPC-EPI support],
[AS_HELP_STRING([[--with-xmlrpc[=DIR]]], [AS_HELP_STRING([[--with-xmlrpc[=DIR]]],
@ -91,9 +89,9 @@ elif test "$PHP_XMLRPC" != "no"; then
if test -r $PHP_XMLRPC/include/xmlrpc.h; then if test -r $PHP_XMLRPC/include/xmlrpc.h; then
XMLRPC_DIR=$PHP_XMLRPC/include XMLRPC_DIR=$PHP_XMLRPC/include
elif test -r $PHP_XMLRPC/include/xmlrpc-epi/xmlrpc.h; then elif test -r $PHP_XMLRPC/include/xmlrpc-epi/xmlrpc.h; then
dnl some xmlrpc-epi header files have generic file names like dnl Some xmlrpc-epi header files have generic file names like queue.h or
dnl queue.h or base64.h. Distributions have to create dir dnl base64.h. Distributions have to create dir for xmlrpc-epi because of
dnl for xmlrpc-epi because of this. dnl this.
XMLRPC_DIR=$PHP_XMLRPC/include/xmlrpc-epi XMLRPC_DIR=$PHP_XMLRPC/include/xmlrpc-epi
else else
AC_MSG_CHECKING(for XMLRPC-EPI in default path) AC_MSG_CHECKING(for XMLRPC-EPI in default path)

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension xmlwriter
PHP_ARG_ENABLE([xmlwriter], PHP_ARG_ENABLE([xmlwriter],
[whether to enable XMLWriter support], [whether to enable XMLWriter support],
[AS_HELP_STRING([--disable-xmlwriter], [AS_HELP_STRING([--disable-xmlwriter],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension xsl
PHP_ARG_WITH([xsl], PHP_ARG_WITH([xsl],
[for XSL support], [for XSL support],
[AS_HELP_STRING([[--with-xsl[=DIR]]], [AS_HELP_STRING([[--with-xsl[=DIR]]],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension zip
PHP_ARG_WITH([zip], PHP_ARG_WITH([zip],
[for zip archive read/write support], [for zip archive read/write support],
[AS_HELP_STRING([--with-zip], [AS_HELP_STRING([--with-zip],

View file

@ -1,5 +1,3 @@
dnl config.m4 for extension zlib
PHP_ARG_WITH([zlib], PHP_ARG_WITH([zlib],
[for ZLIB support], [for ZLIB support],
[AS_HELP_STRING([--with-zlib], [AS_HELP_STRING([--with-zlib],

View file

@ -1,5 +1,3 @@
dnl config.m4 for sapi apache2handler
PHP_ARG_WITH([apxs2],, PHP_ARG_WITH([apxs2],,
[AS_HELP_STRING([[--with-apxs2[=FILE]]], [AS_HELP_STRING([[--with-apxs2[=FILE]]],
[Build shared Apache 2.0 Handler module. FILE is the optional pathname to [Build shared Apache 2.0 Handler module. FILE is the optional pathname to
@ -42,7 +40,7 @@ if test "$PHP_APXS2" != "no"; then
APU_BINDIR=`$APXS -q APU_BINDIR` APU_BINDIR=`$APXS -q APU_BINDIR`
APR_BINDIR=`$APXS -q APR_BINDIR` APR_BINDIR=`$APXS -q APR_BINDIR`
# Pick up ap[ru]-N-config if using httpd >=2.1 dnl Pick up ap[ru]-N-config if using httpd >=2.1
APR_CONFIG=`$APXS -q APR_CONFIG 2>/dev/null || APR_CONFIG=`$APXS -q APR_CONFIG 2>/dev/null ||
echo $APR_BINDIR/apr-config` echo $APR_BINDIR/apr-config`
APU_CONFIG=`$APXS -q APU_CONFIG 2>/dev/null || APU_CONFIG=`$APXS -q APU_CONFIG 2>/dev/null ||
@ -59,7 +57,7 @@ if test "$PHP_APXS2" != "no"; then
APACHE_CFLAGS="$APACHE_CPPFLAGS -I$APXS_INCLUDEDIR $APR_CFLAGS $APU_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1" APACHE_CFLAGS="$APACHE_CPPFLAGS -I$APXS_INCLUDEDIR $APR_CFLAGS $APU_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
# Test that we're trying to configure with apache 2.x dnl Test that we're trying to configure with apache 2.x
PHP_AP_EXTRACT_VERSION($APXS_HTTPD) PHP_AP_EXTRACT_VERSION($APXS_HTTPD)
if test "$APACHE_VERSION" -le 2000000; then if test "$APACHE_VERSION" -le 2000000; then
AC_MSG_ERROR([You have enabled Apache 2 support while your server is Apache 1.3. Please use the appropriate switch --with-apxs (without the 2)]) AC_MSG_ERROR([You have enabled Apache 2 support while your server is Apache 1.3. Please use the appropriate switch --with-apxs (without the 2)])
@ -88,10 +86,9 @@ if test "$PHP_APXS2" != "no"; then
INSTALL_IT="$INSTALL_IT $SAPI_LIBTOOL" INSTALL_IT="$INSTALL_IT $SAPI_LIBTOOL"
;; ;;
*darwin*) *darwin*)
dnl When using bundles on Darwin, we must resolve all symbols. However, dnl When using bundles on Darwin, we must resolve all symbols. However, the
dnl the linker does not recursively look at the bundle loader and dnl linker does not recursively look at the bundle loader and pull in its
dnl pull in its dependencies. Therefore, we must pull in the APR dnl dependencies. Therefore, we must pull in the APR and APR-util libraries.
dnl and APR-util libraries.
if test -x "$APR_CONFIG"; then if test -x "$APR_CONFIG"; then
MH_BUNDLE_FLAGS="`$APR_CONFIG --ldflags --link-ld --libs`" MH_BUNDLE_FLAGS="`$APR_CONFIG --ldflags --link-ld --libs`"
fi fi

View file

@ -1,14 +1,10 @@
dnl config.m4 for sapi cgi
PHP_ARG_ENABLE([cgi],, PHP_ARG_ENABLE([cgi],,
[AS_HELP_STRING([--disable-cgi], [AS_HELP_STRING([--disable-cgi],
[Disable building CGI version of PHP])], [Disable building CGI version of PHP])],
[yes], [yes],
[no]) [no])
dnl dnl CGI setup.
dnl CGI setup
dnl
AC_MSG_CHECKING(for CGI build) AC_MSG_CHECKING(for CGI build)
if test "$PHP_CGI" != "no"; then if test "$PHP_CGI" != "no"; then
AC_MSG_RESULT(yes) AC_MSG_RESULT(yes)
@ -40,7 +36,7 @@ if test "$PHP_CGI" != "no"; then
PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cgi/Makefile.frag) PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cgi/Makefile.frag)
dnl Set filename dnl Set filename.
case $host_alias in case $host_alias in
*cygwin* ) *cygwin* )
SAPI_CGI_PATH=sapi/cgi/php-cgi.exe SAPI_CGI_PATH=sapi/cgi/php-cgi.exe
@ -50,7 +46,7 @@ if test "$PHP_CGI" != "no"; then
;; ;;
esac esac
dnl Select SAPI dnl Select SAPI.
PHP_SELECT_SAPI(cgi, program, cgi_main.c, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1, '$(SAPI_CGI_PATH)') PHP_SELECT_SAPI(cgi, program, cgi_main.c, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1, '$(SAPI_CGI_PATH)')
case $host_alias in case $host_alias in
@ -69,7 +65,7 @@ if test "$PHP_CGI" != "no"; then
;; ;;
esac esac
dnl Expose to Makefile dnl Expose to Makefile.
PHP_SUBST(SAPI_CGI_PATH) PHP_SUBST(SAPI_CGI_PATH)
PHP_SUBST(BUILD_CGI) PHP_SUBST(BUILD_CGI)

View file

@ -1,5 +1,3 @@
dnl config.m4 for sapi cli
PHP_ARG_ENABLE([cli],, PHP_ARG_ENABLE([cli],,
[AS_HELP_STRING([--disable-cli], [AS_HELP_STRING([--disable-cli],
[Disable building CLI version of PHP (this forces --without-pear)])], [Disable building CLI version of PHP (this forces --without-pear)])],
@ -26,10 +24,10 @@ AC_MSG_CHECKING(for CLI build)
if test "$PHP_CLI" != "no"; then if test "$PHP_CLI" != "no"; then
PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cli/Makefile.frag) PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/sapi/cli/Makefile.frag)
dnl Set filename dnl Set filename.
SAPI_CLI_PATH=sapi/cli/php SAPI_CLI_PATH=sapi/cli/php
dnl Select SAPI dnl Select SAPI.
PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c ps_title.c php_cli_process_title.c, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1, '$(SAPI_CLI_PATH)') PHP_SELECT_SAPI(cli, program, php_cli.c php_http_parser.c php_cli_server.c ps_title.c php_cli_process_title.c, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1, '$(SAPI_CLI_PATH)')
case $host_alias in case $host_alias in
@ -48,11 +46,11 @@ if test "$PHP_CLI" != "no"; then
;; ;;
esac esac
dnl Set executable for tests dnl Set executable for tests.
PHP_EXECUTABLE="\$(top_builddir)/\$(SAPI_CLI_PATH)" PHP_EXECUTABLE="\$(top_builddir)/\$(SAPI_CLI_PATH)"
PHP_SUBST(PHP_EXECUTABLE) PHP_SUBST(PHP_EXECUTABLE)
dnl Expose to Makefile dnl Expose to Makefile.
PHP_SUBST(SAPI_CLI_PATH) PHP_SUBST(SAPI_CLI_PATH)
PHP_SUBST(BUILD_CLI) PHP_SUBST(BUILD_CLI)

View file

@ -1,5 +1,3 @@
dnl config.m4 for sapi embed
PHP_ARG_ENABLE([embed],, PHP_ARG_ENABLE([embed],,
[AS_HELP_STRING([[--enable-embed[=TYPE]]], [AS_HELP_STRING([[--enable-embed[=TYPE]]],
[EXPERIMENTAL: Enable building of embedded SAPI library TYPE is either [EXPERIMENTAL: Enable building of embedded SAPI library TYPE is either

View file

@ -1,12 +1,10 @@
dnl config.m4 for sapi fpm
PHP_ARG_ENABLE([fpm],, PHP_ARG_ENABLE([fpm],,
[AS_HELP_STRING([--enable-fpm], [AS_HELP_STRING([--enable-fpm],
[Enable building of the fpm SAPI executable])], [Enable building of the fpm SAPI executable])],
[no], [no],
[no]) [no])
dnl configure checks {{{ dnl Configure checks.
AC_DEFUN([AC_FPM_STDLIBS], AC_DEFUN([AC_FPM_STDLIBS],
[ [
AC_CHECK_FUNCS(clearenv setproctitle setproctitle_fast) AC_CHECK_FUNCS(clearenv setproctitle setproctitle_fast)
@ -341,7 +339,6 @@ AC_DEFUN([AC_FPM_LQ],
fi fi
fi fi
]) ])
dnl }}}
AC_DEFUN([AC_FPM_SYSCONF], AC_DEFUN([AC_FPM_SYSCONF],
[ [
@ -354,7 +351,6 @@ AC_DEFUN([AC_FPM_SYSCONF],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_TIMES], AC_DEFUN([AC_FPM_TIMES],
[ [
@ -367,7 +363,6 @@ AC_DEFUN([AC_FPM_TIMES],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_KQUEUE], AC_DEFUN([AC_FPM_KQUEUE],
[ [
@ -390,7 +385,6 @@ AC_DEFUN([AC_FPM_KQUEUE],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_PORT], AC_DEFUN([AC_FPM_PORT],
[ [
@ -412,7 +406,6 @@ AC_DEFUN([AC_FPM_PORT],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_DEVPOLL], AC_DEFUN([AC_FPM_DEVPOLL],
[ [
@ -436,7 +429,6 @@ AC_DEFUN([AC_FPM_DEVPOLL],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_EPOLL], AC_DEFUN([AC_FPM_EPOLL],
[ [
@ -471,7 +463,6 @@ AC_DEFUN([AC_FPM_EPOLL],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_POLL], AC_DEFUN([AC_FPM_POLL],
[ [
@ -496,7 +487,6 @@ AC_DEFUN([AC_FPM_POLL],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_SELECT], AC_DEFUN([AC_FPM_SELECT],
[ [
@ -526,7 +516,6 @@ AC_DEFUN([AC_FPM_SELECT],
AC_MSG_RESULT([no]) AC_MSG_RESULT([no])
]) ])
]) ])
dnl }}}
AC_DEFUN([AC_FPM_APPARMOR], AC_DEFUN([AC_FPM_APPARMOR],
[ [
@ -544,7 +533,6 @@ AC_DEFUN([AC_FPM_APPARMOR],
]) ])
]) ])
AC_MSG_CHECKING(for FPM build) AC_MSG_CHECKING(for FPM build)
if test "$PHP_FPM" != "no"; then if test "$PHP_FPM" != "no"; then
AC_MSG_RESULT($PHP_FPM) AC_MSG_RESULT($PHP_FPM)
@ -609,7 +597,7 @@ if test "$PHP_FPM" != "no"; then
if test "$PHP_FPM_ACL" != "no" ; then if test "$PHP_FPM_ACL" != "no" ; then
AC_CHECK_HEADERS([sys/acl.h]) AC_CHECK_HEADERS([sys/acl.h])
dnl *BSD has acl_* built into libc dnl *BSD has acl_* built into libc.
AC_CHECK_FUNC(acl_free, [ AC_CHECK_FUNC(acl_free, [
AC_DEFINE(HAVE_FPM_ACL, 1, [ POSIX Access Control List ]) AC_DEFINE(HAVE_FPM_ACL, 1, [ POSIX Access Control List ])
],[ ],[

View file

@ -1,5 +1,3 @@
dnl config.m4 for sapi litespeed
AC_MSG_CHECKING(for LiteSpeed support) AC_MSG_CHECKING(for LiteSpeed support)
PHP_ARG_WITH([litespeed],, PHP_ARG_WITH([litespeed],,

View file

@ -1,5 +1,3 @@
dnl config.m4 for sapi phpdbg
PHP_ARG_ENABLE([phpdbg], PHP_ARG_ENABLE([phpdbg],
[for phpdbg support], [for phpdbg support],
[AS_HELP_STRING([--enable-phpdbg], [AS_HELP_STRING([--enable-phpdbg],

View file

@ -17,7 +17,6 @@ AC_PRESERVE_HELP_ORDER
PHP_CONFIG_NICE(config.nice) PHP_CONFIG_NICE(config.nice)
dnl
AC_DEFUN([PHP_EXT_BUILDDIR],[.])dnl AC_DEFUN([PHP_EXT_BUILDDIR],[.])dnl
AC_DEFUN([PHP_EXT_DIR],[""])dnl AC_DEFUN([PHP_EXT_DIR],[""])dnl
AC_DEFUN([PHP_EXT_SRCDIR],[$abs_srcdir])dnl AC_DEFUN([PHP_EXT_SRCDIR],[$abs_srcdir])dnl
@ -26,7 +25,6 @@ AC_DEFUN([PHP_ALWAYS_SHARED],[
ext_shared=yes ext_shared=yes
test "[$]$1" = "no" && $1=yes test "[$]$1" = "no" && $1=yes
])dnl ])dnl
dnl
test -z "$CFLAGS" && auto_cflags=1 test -z "$CFLAGS" && auto_cflags=1
@ -38,7 +36,7 @@ AC_PROG_CC([cc gcc])
PHP_DETECT_ICC PHP_DETECT_ICC
PHP_DETECT_SUNCC PHP_DETECT_SUNCC
dnl Support systems with system libraries in e.g. /usr/lib64 dnl Support systems with system libraries in e.g. /usr/lib64.
PHP_ARG_WITH([libdir], PHP_ARG_WITH([libdir],
[for system library directory], [for system library directory],
[AS_HELP_STRING([--with-libdir=NAME], [AS_HELP_STRING([--with-libdir=NAME],
@ -49,14 +47,14 @@ PHP_ARG_WITH([libdir],
PHP_RUNPATH_SWITCH PHP_RUNPATH_SWITCH
PHP_SHLIB_SUFFIX_NAMES PHP_SHLIB_SUFFIX_NAMES
dnl Find php-config script dnl Find php-config script.
PHP_ARG_WITH([php-config],, PHP_ARG_WITH([php-config],,
[AS_HELP_STRING([--with-php-config=PATH], [AS_HELP_STRING([--with-php-config=PATH],
[Path to php-config [php-config]])], [Path to php-config [php-config]])],
[php-config], [php-config],
[no]) [no])
dnl For BC dnl For BC.
PHP_CONFIG=$PHP_PHP_CONFIG PHP_CONFIG=$PHP_PHP_CONFIG
prefix=`$PHP_CONFIG --prefix 2>/dev/null` prefix=`$PHP_CONFIG --prefix 2>/dev/null`
phpincludedir=`$PHP_CONFIG --include-dir 2>/dev/null` phpincludedir=`$PHP_CONFIG --include-dir 2>/dev/null`
@ -80,7 +78,7 @@ AC_MSG_RESULT([$EXTENSION_DIR])
AC_MSG_CHECKING([for PHP installed headers prefix]) AC_MSG_CHECKING([for PHP installed headers prefix])
AC_MSG_RESULT([$phpincludedir]) AC_MSG_RESULT([$phpincludedir])
dnl Checks for PHP_DEBUG / ZEND_DEBUG / ZTS dnl Checks for PHP_DEBUG / ZEND_DEBUG / ZTS.
AC_MSG_CHECKING([if debug is enabled]) AC_MSG_CHECKING([if debug is enabled])
old_CPPFLAGS=$CPPFLAGS old_CPPFLAGS=$CPPFLAGS
CPPFLAGS="-I$phpincludedir" CPPFLAGS="-I$phpincludedir"
@ -113,11 +111,11 @@ php_zts_is_enabled
CPPFLAGS=$old_CPPFLAGS CPPFLAGS=$old_CPPFLAGS
AC_MSG_RESULT([$PHP_THREAD_SAFETY]) AC_MSG_RESULT([$PHP_THREAD_SAFETY])
dnl Support for building and testing Zend extensions dnl Support for building and testing Zend extensions.
ZEND_EXT_TYPE="zend_extension" ZEND_EXT_TYPE="zend_extension"
PHP_SUBST(ZEND_EXT_TYPE) PHP_SUBST(ZEND_EXT_TYPE)
dnl Discard optimization flags when debugging is enabled dnl Discard optimization flags when debugging is enabled.
if test "$PHP_DEBUG" = "yes"; then if test "$PHP_DEBUG" = "yes"; then
PHP_DEBUG=1 PHP_DEBUG=1
ZEND_DEBUG=yes ZEND_DEBUG=yes
@ -125,7 +123,7 @@ if test "$PHP_DEBUG" = "yes"; then
CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'` CFLAGS=`echo "$CFLAGS" | $SED -e 's/-O[0-9s]*//g'`
CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'` CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'`
changequote([,]) changequote([,])
dnl add -O0 only if GCC or ICC is used dnl Add -O0 only if GCC or ICC is used.
if test "$GCC" = "yes" || test "$ICC" = "yes"; then if test "$GCC" = "yes" || test "$ICC" = "yes"; then
CFLAGS="$CFLAGS -O0" CFLAGS="$CFLAGS -O0"
CXXFLAGS="$CXXFLAGS -g -O0" CXXFLAGS="$CXXFLAGS -g -O0"
@ -144,10 +142,10 @@ else
ZEND_DEBUG=no ZEND_DEBUG=no
fi fi
dnl Always shared dnl Always shared.
PHP_BUILD_SHARED PHP_BUILD_SHARED
dnl Required programs dnl Required programs.
PHP_PROG_AWK PHP_PROG_AWK
sinclude(config.m4) sinclude(config.m4)
@ -155,8 +153,9 @@ sinclude(config.m4)
enable_static=no enable_static=no
enable_shared=yes enable_shared=yes
dnl Only allow AC_PROG_CXX and AC_PROG_CXXCPP if they are explicitly called (by PHP_REQUIRE_CXX). dnl Only allow AC_PROG_CXX and AC_PROG_CXXCPP if they are explicitly called (by
dnl Otherwise AC_PROG_LIBTOOL fails if there is no working C++ compiler. dnl PHP_REQUIRE_CXX). Otherwise AC_PROG_LIBTOOL fails if there is no working C++
dnl compiler.
AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [], [ AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [], [
undefine([AC_PROG_CXX]) undefine([AC_PROG_CXX])
AC_DEFUN([AC_PROG_CXX], []) AC_DEFUN([AC_PROG_CXX], [])