Annotation of embedaddon/php/sapi/roxen/config.m4, revision 1.1.1.2

1.1       misho       1: dnl
1.1.1.2 ! misho       2: dnl $Id$
1.1       misho       3: dnl
                      4: 
                      5: PHP_ARG_WITH(roxen,, 
                      6: [  --with-roxen=DIR        Build PHP as a Pike module. DIR is the base Roxen
                      7:                           directory, normally /usr/local/roxen/server], no, no)
                      8: 
                      9: PHP_ARG_ENABLE(roxen-zts, whether Roxen module is build using ZTS,
                     10: [  --enable-roxen-zts        ROXEN: Build the Roxen module using Zend Thread Safety], no, no)
                     11: 
                     12: RESULT=
                     13: AC_MSG_CHECKING([for Roxen/Pike support])
                     14: if test "$PHP_ROXEN" != "no"; then
                     15:   if test ! -d $PHP_ROXEN ; then
                     16:     AC_MSG_ERROR([You did not specify a directory])
                     17:   fi
                     18:   if test -f $PHP_ROXEN/bin/roxen; then
                     19:     PIKE=$PHP_ROXEN/bin/roxen
                     20:   elif test -f $PHP_ROXEN/bin/pike; then
                     21:     PIKE=$PHP_ROXEN/bin/pike
                     22:   else
                     23:     AC_MSG_ERROR([Could not find a pike in $PHP_ROXEN/bin/])
                     24:   fi
                     25: 
                     26:   if $PIKE -e 'float v; catch(v = __VERSION__ + (__BUILD__/10000.0)); if(v < 0.7079) exit(1); exit(0);'; then
                     27:     PIKE_MODULE_DIR=`$PIKE --show-paths 2>&1| grep '^Module' | sed -e 's/.*: //'`
                     28:     PIKE_INCLUDE_DIR=`echo $PIKE_MODULE_DIR | sed -e 's,lib/pike/modules,include/pike,' -e 's,lib/modules,include/pike,'`
                     29:     if test -z "$PIKE_INCLUDE_DIR" || test -z "$PIKE_MODULE_DIR"; then
                     30:       AC_MSG_ERROR([Failed to figure out Pike module and include directories])
                     31:     fi
                     32:   else
                     33:     AC_MSG_ERROR([Roxen/PHP requires Pike 0.7.79 or newer])
                     34:   fi
                     35:    
                     36:   PHP_ADD_INCLUDE($PIKE_INCLUDE_DIR)
                     37:   AC_DEFINE(HAVE_ROXEN, 1, [Whether you use Roxen])
                     38:   PHP_SELECT_SAPI(roxen, shared, roxen.c)
                     39:   INSTALL_IT="\$(INSTALL) -m 0755 $SAPI_SHARED $PIKE_MODULE_DIR/PHP5.so"
                     40:   RESULT="yes
                     41:   Pike binary used:      $PIKE
                     42:   Pike include dir:      $PIKE_INCLUDE_DIR
                     43:   Pike module directory: $PIKE_MODULE_DIR"
                     44:   PIKE_INCLUDE_DIR=" -I$PIKE_INCLUDE_DIR "
                     45: 
                     46:   if test "$PHP_ROXEN_ZTS" != "no"; then
                     47:     PHP_BUILD_THREAD_SAFE
                     48:     AC_DEFINE(ROXEN_USE_ZTS, 1, [Whether to use Roxen in ZTS mode])
                     49:   fi
                     50: fi
                     51: AC_MSG_RESULT([$RESULT])
                     52: 
                     53: dnl ## Local Variables:
                     54: dnl ## tab-width: 4
                     55: dnl ## End:

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>