1 dnl Copyright (C) 2010 NorthScale
2 dnl This file is free software; NorthScale
3 dnl gives unlimited permission to copy and/or distribute it,
4 dnl with or without modifications, as long as this notice is preserved.
6 AC_DEFUN([_PANDORA_SEARCH_LIBHASHKIT],[
7 AC_REQUIRE([AC_LIB_PREFIX])
9 dnl --------------------------------------------------------------------
10 dnl Check for libhashkit
11 dnl --------------------------------------------------------------------
13 AC_ARG_ENABLE([libhashkit],
14 [AS_HELP_STRING([--disable-libhashkit],
15 [Build with libhashkit support @<:@default=on@:>@])],
16 [ac_enable_libhashkit="$enableval"],
17 [ac_enable_libhashkit="yes"])
19 AS_IF([test "x$ac_enable_libhashkit" = "xyes"],[
20 AC_LIB_HAVE_LINKFLAGS(hashkit,,[
21 #include <libhashkit/hashkit.h>
24 hashkit_st *kit = hashkit_create(&foo);
31 AM_CONDITIONAL(HAVE_LIBHASHKIT, [test "x${ac_cv_libhashkit}" = "xyes"])
34 AC_DEFUN([PANDORA_HAVE_LIBHASHKIT],[
35 AC_REQUIRE([_PANDORA_SEARCH_LIBHASHKIT])
38 AC_DEFUN([PANDORA_REQUIRE_LIBHASHKIT],[
39 AC_REQUIRE([PANDORA_HAVE_LIBHASHKIT])
40 AS_IF([test x$ac_cv_libhashkit = xno],
41 AC_MSG_ERROR([libhashkit is required for ${PACKAGE}]))