1999-11-24 07:08:10 +08:00
|
|
|
dnl ## $Id$ -*- sh -*-
|
|
|
|
|
|
|
|
RESULT=no
|
|
|
|
AC_MSG_CHECKING(for Roxen/Pike support)
|
1999-11-25 08:28:19 +08:00
|
|
|
AC_ARG_WITH(roxen,
|
|
|
|
[ --with-roxen=DIR Build PHP as a Pike module. DIR is the base Roxen
|
|
|
|
directory, normally /usr/local/roxen/server.],
|
1999-11-24 07:08:10 +08:00
|
|
|
[
|
|
|
|
if test ! -d $withval ; then
|
|
|
|
AC_MSG_ERROR(You did not specify a directory)
|
|
|
|
fi
|
1999-11-24 15:17:17 +08:00
|
|
|
if test -f $withval/bin/roxen; then
|
2001-05-12 19:09:05 +08:00
|
|
|
PIKE=$withval/bin/roxen
|
1999-11-24 15:17:17 +08:00
|
|
|
elif test -f $withval/bin/pike; then
|
2001-05-12 19:09:05 +08:00
|
|
|
PIKE=$withval/bin/pike
|
1999-11-24 15:17:17 +08:00
|
|
|
else
|
|
|
|
AC_MSG_ERROR(Couldn't find a pike in $withval/bin/)
|
|
|
|
fi
|
1999-12-22 13:02:07 +08:00
|
|
|
if $PIKE -e 'float v; catch(v = __VERSION__ + (__BUILD__/10000.0)); if(v < 0.7079) exit(1); exit(0);'; then
|
2001-05-12 19:09:05 +08:00
|
|
|
PIKE_MODULE_DIR=`$PIKE --show-paths 2>&1| grep '^Module' | sed -e 's/.*: //'`
|
|
|
|
PIKE_INCLUDE_DIR=`echo $PIKE_MODULE_DIR | sed -e 's,lib/pike/modules,include/pike,' -e 's,lib/modules,include/pike,'`
|
1999-11-24 15:17:17 +08:00
|
|
|
if test -z "$PIKE_INCLUDE_DIR" -o -z "$PIKE_MODULE_DIR"; then
|
|
|
|
AC_MSG_ERROR(Failed to figure out Pike module and include directories)
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
AC_MSG_ERROR(Roxen/PHP requires Pike 0.7.79 or newer)
|
|
|
|
fi
|
2000-06-06 05:05:40 +08:00
|
|
|
|
2001-03-28 04:35:04 +08:00
|
|
|
PHP_ADD_INCLUDE($PIKE_INCLUDE_DIR)
|
1999-12-30 05:24:43 +08:00
|
|
|
AC_DEFINE(HAVE_ROXEN,1,[Whether you use Roxen])
|
1999-11-24 07:08:10 +08:00
|
|
|
PHP_SAPI=roxen
|
|
|
|
PHP_BUILD_SHARED
|
2000-03-07 03:26:39 +08:00
|
|
|
INSTALL_IT="\$(INSTALL) -m 0755 $SAPI_SHARED $PIKE_MODULE_DIR/PHP4.so"
|
1999-11-24 15:17:17 +08:00
|
|
|
RESULT="yes
|
1999-11-25 08:28:19 +08:00
|
|
|
Pike binary used: $PIKE
|
1999-11-24 15:17:17 +08:00
|
|
|
Pike include dir: $PIKE_INCLUDE_DIR
|
|
|
|
Pike module directory: $PIKE_MODULE_DIR"
|
2000-06-06 05:05:40 +08:00
|
|
|
PIKE_INCLUDE_DIR=" -I$PIKE_INCLUDE_DIR "
|
1999-11-24 07:08:10 +08:00
|
|
|
])
|
|
|
|
AC_MSG_RESULT($RESULT)
|
|
|
|
|
1999-11-25 08:28:19 +08:00
|
|
|
if test "$RESULT" != "no" ; then
|
|
|
|
RESULT=no
|
|
|
|
AC_MSG_CHECKING(if Roxen should use ZTS)
|
|
|
|
AC_ARG_ENABLE(roxen-zts,
|
2000-02-29 09:10:37 +08:00
|
|
|
[ --enable-roxen-zts Build the Roxen module using Zend Thread Safety.],
|
1999-11-25 08:28:19 +08:00
|
|
|
[
|
|
|
|
PHP_BUILD_THREAD_SAFE
|
1999-12-30 05:24:43 +08:00
|
|
|
AC_DEFINE(ROXEN_USE_ZTS,1,[Whether to use Roxen in ZTS mode])
|
2001-05-12 19:09:05 +08:00
|
|
|
RESULT=yes
|
1999-11-25 08:28:19 +08:00
|
|
|
|
|
|
|
])
|
|
|
|
AC_MSG_RESULT($RESULT)
|
|
|
|
fi
|
1999-11-24 07:08:10 +08:00
|
|
|
dnl ## Local Variables:
|
|
|
|
dnl ## tab-width: 4
|
|
|
|
dnl ## End:
|
1999-12-30 05:24:43 +08:00
|
|
|
|