Annotation of embedaddon/php/ext/xsl/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(xsl, for XSL support,
6: [ --with-xsl[=DIR] Include XSL support. DIR is the libxslt base
7: install directory (libxslt >= 1.1.0 required)])
8:
9: if test "$PHP_XSL" != "no"; then
10:
11: if test "$PHP_LIBXML" = "no"; then
12: AC_MSG_ERROR([XSL extension requires LIBXML extension, add --enable-libxml])
13: fi
14:
15: if test "$PHP_DOM" = "no"; then
16: AC_MSG_ERROR([XSL extension requires DOM extension, add --enable-dom])
17: fi
18:
19: for i in $PHP_XSL /usr/local /usr; do
20: if test -x "$i/bin/xslt-config"; then
21: XSLT_CONFIG=$i/bin/xslt-config
22: break
23: fi
24: done
25:
26: if test -z "$XSLT_CONFIG"; then
27: AC_MSG_ERROR([xslt-config not found. Please reinstall the libxslt >= 1.1.0 distribution])
28: else
29: libxslt_full_version=`$XSLT_CONFIG --version`
30: ac_IFS=$IFS
31: IFS="."
32: set $libxslt_full_version
33: IFS=$ac_IFS
34: LIBXSLT_VERSION=`expr [$]1 \* 1000000 + [$]2 \* 1000 + [$]3`
35: if test "$LIBXSLT_VERSION" -ge "1001000"; then
36: XSL_LIBS=`$XSLT_CONFIG --libs`
37: XSL_INCS=`$XSLT_CONFIG --cflags`
38: PHP_EVAL_LIBLINE($XSL_LIBS, XSL_SHARED_LIBADD)
39: PHP_EVAL_INCLINE($XSL_INCS)
40:
41: AC_MSG_CHECKING([for EXSLT support])
42: for i in $PHP_XSL /usr/local /usr; do
43: if test -r "$i/include/libexslt/exslt.h"; then
44: PHP_XSL_EXSL_DIR=$i
45: break
46: fi
47: done
48: if test -z "$PHP_XSL_EXSL_DIR"; then
49: AC_MSG_RESULT(not found)
50: else
51: AC_MSG_RESULT(found)
52: PHP_ADD_LIBRARY_WITH_PATH(exslt, $PHP_XSL_EXSL_DIR/$PHP_LIBDIR, XSL_SHARED_LIBADD)
53: PHP_ADD_INCLUDE($PHP_XSL_EXSL_DIR/include)
54: AC_DEFINE(HAVE_XSL_EXSLT,1,[ ])
55: fi
56: else
57: AC_MSG_ERROR([libxslt version 1.1.0 or greater required.])
58: fi
59:
60:
61: fi
62:
63: AC_DEFINE(HAVE_XSL,1,[ ])
64: PHP_NEW_EXTENSION(xsl, php_xsl.c xsltprocessor.c, $ext_shared)
65: PHP_SUBST(XSL_SHARED_LIBADD)
66: PHP_ADD_EXTENSION_DEP(xsl, libxml)
67: fi
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>