hiredis.m4 779 B

1234567891011121314151617181920212223242526
  1. # Copyright (C) 2011 Brian Aker (brian@tangent.org)
  2. #
  3. # serial 2
  4. AC_DEFUN([_SEARCH_HIREDIS],
  5. [AC_REQUIRE([AX_CHECK_LIBRARY])
  6. AS_IF([test "x$ac_enable_hiredis" = "xyes"],
  7. [hiredis_header="hiredis/hiredis.h"],
  8. [hiredis_header="does_not_exist"])
  9. AX_CHECK_LIBRARY([HIREDIS],[$hiredis_header],[hiredis],,
  10. [AC_DEFINE([HAVE_HIREDIS],[0],[Define to 1 if HIREDIS is found])])
  11. AS_IF([test "x$ax_cv_have_HIREDIS" = xno],[ac_enable_hiredis="no"])
  12. ])
  13. AC_DEFUN([AX_ENABLE_LIBHIREDIS],
  14. [AC_ARG_ENABLE([hiredis],
  15. [AS_HELP_STRING([--disable-hiredis],
  16. [Build with hiredis support @<:@default=on@:>@])],
  17. [ac_enable_hiredis="$enableval"],
  18. [ac_enable_hiredis="yes"])
  19. _SEARCH_HIREDIS
  20. ])