]> git.decadent.org.uk Git - nfs-utils.git/commitdiff
Enable nfsidmap to compile
authorSteve Dickson <steved@redhat.com>
Sat, 20 Nov 2010 20:01:21 +0000 (15:01 -0500)
committerSteve Dickson <steved@redhat.com>
Mon, 22 Nov 2010 16:38:54 +0000 (11:38 -0500)
Only enable the compilation of nfsidmap when libnfsidmap support it.

Signed-off-by: Steve Dickson <steved@redhat.com>
.gitignore
aclocal/libnfsidmap.m4
configure.ac
utils/Makefile.am

index 4bff9e382a27e1c3855126fbdf430a7fc1290e72..f5b5cf044f2ede7bf0c8972604d372d552a52797 100644 (file)
@@ -64,6 +64,7 @@ tests/nsm_client/nlm_sm_inter.h
 tests/nsm_client/nlm_sm_inter_clnt.c
 tests/nsm_client/nlm_sm_inter_svc.c
 tests/nsm_client/nlm_sm_inter_xdr.c
+utils/nfsidmap/nfsidmap
 # cscope database files
 cscope.*
 # generic editor backup et al
index cfcde2f8fafc1594295ded6079e2c1463e0b9973..4faa923f190c2b14df663ee93697e42b9ecf4b75 100644 (file)
@@ -14,4 +14,8 @@ AC_DEFUN([AC_LIBNFSIDMAP], [
                [AC_DEFINE([HAVE_NFS4_SET_DEBUG], 1,
                           [Define to 1 if you have the `nfs4_set_debug' function.])])
 
+  dnl only enable nfsidmap when libnfsidmap supports it
+  AC_CHECK_LIB([nfsidmap], [nfs4_owner_to_uid], [enable_nfsidmap=yes],
+               [enable_nfsidmap=no])
+
 ])dnl
index b39dbcde7dc2382318bc7ac82e82424c01991b05..92833e3f5b9e8c13206a9dd5a272725aa7f9fce4 100644 (file)
@@ -247,6 +247,9 @@ if test "$enable_nfsv4" = yes; then
   dnl check for nfsidmap libraries and headers
   AC_LIBNFSIDMAP
 
+  dnl enable nfsidmap when its support by libnfsidmap
+  AM_CONDITIONAL(CONFIG_NFSIDMAP, [test "$enable_nfsidmap" = "yes"])
+
   dnl check for the keyutils libraries and headers
   AC_KEYUTILS
 
index 86651833cb57e5cf69a99aa4e1a89c7c86a48c44..a0ea11629a1e6e8bc32a22e7754db1006aff5a69 100644 (file)
@@ -4,6 +4,9 @@ OPTDIRS =
 
 if CONFIG_NFSV4
 OPTDIRS += idmapd
+if CONFIG_NFSIDMAP
+OPTDIRS += nfsidmap
+endif
 endif
 
 if CONFIG_GSS