Added new command: memcached_flush_buffers
[m6w6/libmemcached] / config / dtrace.m4
1 dnl ---------------------------------------------------------------------------
2 dnl Macro: DTRACE_TEST
3 dnl ---------------------------------------------------------------------------
4 AC_ARG_ENABLE(dtrace,
5 [ --enable-dtrace Build with support for the DTRACE.],
6 [
7 AC_PATH_PROG([DTRACE], [dtrace], "no", [/usr/sbin:$PATH])
8 if test "x$DTRACE" != "xno"; then
9 AC_DEFINE([HAVE_DTRACE], [1], [Enables DTRACE Support])
10 DTRACE_HEADER=dtrace_probes.h
11
12 # DTrace on MacOSX does not use -G option
13 $DTRACE -G -o conftest.$$ -s libmemcached/libmemcached_probes.d 2>/dev/zero
14 if test $? -eq 0
15 then
16 DTRACE_OBJ=libmemcached_probes.lo
17 rm conftest.$$
18 fi
19
20 ENABLE_DTRACE="yes"
21 AC_SUBST(HAVE_DTRACE)
22 else
23 AC_MSG_ERROR([Need dtrace binary and OS support.])
24 fi
25 ],
26 [
27 ENABLE_DTRACE="no"
28 ]
29 )
30
31 AC_SUBST(DTRACEFLAGS)
32 AC_SUBST(DTRACE_HEADER)
33 AC_SUBST(DTRACE_OBJ)
34 AM_CONDITIONAL([HAVE_DTRACE], [ test "$ENABLE_DTRACE" = "yes" ])
35 dnl ---------------------------------------------------------------------------
36 dnl End Macro: DTRACE_TEST
37 dnl ---------------------------------------------------------------------------