docs: cmake build
[m6w6/libmemcached] / m4 / have_libpq.m4
1 dnl Copyright (C) 2011 Brian Aker (brian@tangent.org)
2
3 AC_DEFUN([AX_HAVE_LIBPQ],[
4 AC_ARG_ENABLE([libpq],
5 [AS_HELP_STRING([--disable-libpq],
6 [Build with libpq, ie Postgres, support @<:@default=on@:>@])],
7 [ac_cv_libpq="$enableval"],
8 [ac_cv_libpq="yes"])
9
10 AC_REQUIRE([AX_LIB_POSTGRESQL])
11
12 AS_IF([test "x$ac_cv_libpq" = "xyes" -a "x$found_postgresql" = "xyes"],
13 [
14 AC_DEFINE([HAVE_LIBPQ], [ 1 ], [Enable libpq support])
15 ],
16 [
17 AC_DEFINE([HAVE_LIBPQ], [ 0 ], [Enable libpq support])
18 # if --enable-libpq, but no Postgres, force --disable-libpq
19 ac_cv_libpq="no"
20 ])
21
22 AM_CONDITIONAL(HAVE_LIBPQ, [test "x$ac_cv_libpq" = "xyes"])
23 ])