Ignore *.exe
[awesomized/libmemcached] / m4 / pandora_have_libhashkit.m4
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.
5
6 AC_DEFUN([_PANDORA_SEARCH_LIBHASHKIT],[
7 AC_REQUIRE([AC_LIB_PREFIX])
8
9 dnl --------------------------------------------------------------------
10 dnl Check for libhashkit
11 dnl --------------------------------------------------------------------
12
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"])
18
19 AS_IF([test "x$ac_enable_libhashkit" = "xyes"],[
20 AC_LIB_HAVE_LINKFLAGS(hashkit,,[
21 #include <libhashkit/hashkit.h>
22 ],[
23 hashkit_st foo;
24 hashkit_st *kit = hashkit_create(&foo);
25 hashkit_free(kit);
26 ])
27 ],[
28 ac_cv_libhashkit="no"
29 ])
30
31 AM_CONDITIONAL(HAVE_LIBHASHKIT, [test "x${ac_cv_libhashkit}" = "xyes"])
32 ])
33
34 AC_DEFUN([PANDORA_HAVE_LIBHASHKIT],[
35 AC_REQUIRE([_PANDORA_SEARCH_LIBHASHKIT])
36 ])
37
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}]))
42 ])