From 415612949005edffa3ca05133ea5f1358f578161 Mon Sep 17 00:00:00 2001 From: Alexander Bokovoy Date: Tue, 20 Feb 2007 15:55:12 +0000 Subject: r21467: Add GPFS-provided DMAPI support based on their GPL library (This used to be commit 5876bedda51fce0c932ca0cdab074629b31a9c94) --- source3/aclocal.m4 | 10 +++++++++- source3/smbd/dmapi.c | 2 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/source3/aclocal.m4 b/source3/aclocal.m4 index 00c57bacee..d36749a5f5 100644 --- a/source3/aclocal.m4 +++ b/source3/aclocal.m4 @@ -592,9 +592,15 @@ AC_DEFUN([SMB_CHECK_DMAPI], [samba_dmapi_libs="-lxdsm"], []) fi + if test x"$samba_dmapi_libs" = x"" ; then + AC_CHECK_LIB(dmapi, dm_get_eventlist, + [samba_dmapi_libs="-ldmapi"], []) + fi + + # Only bother to test ehaders if we have a candidate DMAPI library if test x"$samba_dmapi_libs" != x"" ; then - AC_CHECK_HEADERS(sys/dmi.h xfs/dmapi.h sys/jfsdmapi.h sys/dmapi.h) + AC_CHECK_HEADERS(sys/dmi.h xfs/dmapi.h sys/jfsdmapi.h sys/dmapi.h dmapi.h) fi if test x"$samba_dmapi_libs" != x"" ; then @@ -612,6 +618,8 @@ AC_DEFUN([SMB_CHECK_DMAPI], #include #elif defined(HAVE_SYS_DMAPI_H) #include +#elif defined(HAVE_DMAPI_H) +#include #endif ], [ diff --git a/source3/smbd/dmapi.c b/source3/smbd/dmapi.c index b42b7d51f0..b8c23c2dce 100644 --- a/source3/smbd/dmapi.c +++ b/source3/smbd/dmapi.c @@ -40,6 +40,8 @@ BOOL dmapi_have_session(void) { return False; } #include #elif defined(HAVE_SYS_DMAPI_H) #include +#elif defined(HAVE_DMAPI_H) +#include #endif #define DMAPI_SESSION_NAME "samba" -- cgit