1 dnl $Id$
3 PHP_ARG_WITH(rrdtool, for RRDTool support,
4 [ --with-rrdtool[=DIR] Include RRDTool support. DIR is the rrdtool
5 install directory.])
7 if test "$PHP_RRDTOOL" != "no"; then
8 for i in /usr/local /usr /opt/rrdtool /usr/local/rrdtool $PHP_RRDTOOL; do
9 if test -f $i/include/rrd.h; then
10 RRDTOOL_DIR=$i
11 fi
12 done
14 if test -z "$RRDTOOL_DIR"; then
15 AC_MSG_ERROR(Please reinstall rrdtool, or specify a directory - I cannot find rrd.h)
16 fi
17 AC_ADD_INCLUDE($RRDTOOL_DIR/include)
18 AC_ADD_LIBRARY_WITH_PATH(rrd, $RRDTOOL_DIR/lib, RRDTOOL_SHARED_LIBADD)
19 PHP_SUBST(RRDTOOL_SHARED_LIBADD)
21 AC_DEFINE(HAVE_RRDTOOL,1,[ ])
23 PHP_EXTENSION(rrdtool, $ext_shared)
24 fi