From 767773f33c10dfeaf44ef7d6aea0946f5d9d248f Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Mon, 16 Mar 2009 13:30:26 -0400 Subject: configure: pull common nfsidmap and event checks into aclocal/ Clean up: Create an aclocal script for the nfsidmap library and headers checks used for both --enable-gss and --enable-nfsv4. Move libevent checks out too. Signed-off-by: Chuck Lever Signed-off-by: Steve Dickson --- aclocal/libevent.m4 | 11 +++++++++++ aclocal/libnfsidmap.m4 | 17 +++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 aclocal/libevent.m4 create mode 100644 aclocal/libnfsidmap.m4 (limited to 'aclocal') diff --git a/aclocal/libevent.m4 b/aclocal/libevent.m4 new file mode 100644 index 0000000..3c962b3 --- /dev/null +++ b/aclocal/libevent.m4 @@ -0,0 +1,11 @@ +dnl Checks for libevent +AC_DEFUN([AC_LIBEVENT], [ + + dnl Check for libevent, but do not add -levent to LIBS + AC_CHECK_LIB([event], [event_dispatch], [libevent=1], + [AC_MSG_ERROR([libevent not found.])]) + + AC_CHECK_HEADERS([event.h], , + [AC_MSG_ERROR([libevent headers not found.])]) + +])dnl diff --git a/aclocal/libnfsidmap.m4 b/aclocal/libnfsidmap.m4 new file mode 100644 index 0000000..cfcde2f --- /dev/null +++ b/aclocal/libnfsidmap.m4 @@ -0,0 +1,17 @@ +dnl Checks for libnfsidmap +dnl +AC_DEFUN([AC_LIBNFSIDMAP], [ + + dnl Check for libnfsidmap, but do not add -lnfsidmap to LIBS + AC_CHECK_LIB([nfsidmap], [nfs4_init_name_mapping], [libnfsidmap=1], + [AC_MSG_ERROR([libnfsidmap not found.])]) + + AC_CHECK_HEADERS([nfsidmap.h], , + [AC_MSG_ERROR([libnfsidmap headers not found.])]) + + dnl nfs4_set_debug() doesn't appear in all versions of libnfsidmap + AC_CHECK_LIB([nfsidmap], [nfs4_set_debug], + [AC_DEFINE([HAVE_NFS4_SET_DEBUG], 1, + [Define to 1 if you have the `nfs4_set_debug' function.])]) + +])dnl -- cgit