Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 19 additions & 7 deletions config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ PHP_ARG_ENABLE(lz4, whether to enable lz4 support,
PHP_ARG_WITH(lz4-includedir, for lz4 header,
[ --with-lz4-includedir=DIR lz4 header files], no, no)

PHP_ARG_ENABLE(apcu, whether to enable APCu support,
[ --enable-apcu Enable APCu support], auto, no)

if test "$PHP_LZ4" != "no"; then

AC_MSG_CHECKING([searching for liblz4])
Expand Down Expand Up @@ -65,13 +68,22 @@ if test "$PHP_LZ4" != "no"; then
PHP_ADD_INCLUDE([$ext_srcdir/lz4/lib])
fi

AC_MSG_CHECKING([for APCu includes])
if test -f "$phpincludedir/ext/apcu/apc_serializer.h"; then
apc_inc_path="$phpincludedir"
AC_MSG_RESULT([APCu in $apc_inc_path])
AC_DEFINE(HAVE_APCU_SUPPORT,1,[Whether to enable APCu support])
else
AC_MSG_RESULT([not found])
dnl APCu
if test "$PHP_APCU" != "no"; then
AC_MSG_CHECKING([for APCu includes])
if test ! -f "$phpincludedir/ext/apcu/apc_serializer.h" && test -f "$abs_srcdir/ext/apcu/apc_serializer.h"; then
phpincludedir="$abs_srcdir"
fi
if test -f "$phpincludedir/ext/apcu/apc_serializer.h"; then
apc_inc_path="$phpincludedir"
AC_MSG_RESULT([APCu in $apc_inc_path])
AC_DEFINE(HAVE_APCU_SUPPORT, 1, [Whether to enable APCu support])
else
if test "$PHP_APCU" != "auto"; then
AC_MSG_ERROR([apc_serializer.h header not found])
Comment thread
coderabbitai[bot] marked this conversation as resolved.
fi
AC_MSG_RESULT([not found])
fi
fi
fi

Expand Down