Check for xlog_assign_lsn in xfs headers
authorEric Sandeen <sandeen@sandeen.net>
Wed, 3 Jun 2009 20:15:15 +0000 (15:15 -0500)
committerEric Sandeen <sandeen@sandeen.net>
Wed, 3 Jun 2009 20:15:15 +0000 (15:15 -0500)
Checking for libxfs.h isn't enough; some debian installs
have libxfs.h but no xlog_assign_lsn, and the loggen build still
fails.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Tested-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
aclocal.m4
configure.in
include/builddefs.in
m4/package_xfslibs.m4
src/Makefile

index ac616d1..8a61e39 100644 (file)
@@ -421,6 +421,13 @@ AC_DEFUN([AC_PACKAGE_WANT_XFS_LIBXFS_H],
     AC_SUBST(have_libxfs)
   ])
 
+AC_DEFUN([AC_PACKAGE_WANT_XLOG_ASSIGN_LSN],
+  [
+    AC_CHECK_DECL(xlog_assign_lsn,
+      [ have_xlog_assign_lsn=true ], [ have_xlog_assign_lsn=false ],
+      [[#include <xfs/libxfs.h>]])
+  ])
+
 AC_DEFUN([AC_PACKAGE_NEED_XFS_XQM_H],
   [ AC_CHECK_HEADERS([xfs/xqm.h])
     if test "$ac_cv_header_xfs_xqm_h" != "yes"; then
index 210a91e..6c2afe7 100644 (file)
@@ -46,6 +46,7 @@ in
                AC_MULTILIB($enable_lib64)
                AC_PACKAGE_NEED_XFS_XFS_H
                AC_PACKAGE_WANT_XFS_LIBXFS_H
+               AC_PACKAGE_WANT_XLOG_ASSIGN_LSN
                AC_PACKAGE_NEED_XFS_XQM_H
                AC_PACKAGE_NEED_XFSCTL_MACRO
                AC_PACKAGE_NEED_XFS_HANDLE_H
index e8f4b6b..7827ed5 100644 (file)
@@ -15,6 +15,7 @@ CFLAGS = @CFLAGS@
 CPPFLAGS = @CPPFLAGS@
 
 HAVE_LIBXFS = @have_libxfs@
+HAVE_XLOG_ASSIGN_LSN = @have_xlog_assign_lsn@
 LIBXFS = @libxfs@
 LIBACL = @libacl@
 LIBATTR = @libattr@
index 903e4a7..870882f 100644 (file)
@@ -13,6 +13,14 @@ AC_DEFUN([AC_PACKAGE_WANT_LIBXFS_H],
     AC_SUBST(have_libxfs)
   ])
 
+AC_DEFUN([AC_PACKAGE_WANT_XLOG_ASSIGN_LSN],
+  [
+    AC_CHECK_DECL(xlog_assign_lsn,
+      [ have_xlog_assign_lsn=true ], [ have_xlog_assign_lsn=false ],
+      [[#include <xfs/libxfs.h>]])
+    AC_SUBST(have_have_xlog_assign_lsn)
+  ])
+
 AC_DEFUN([AC_PACKAGE_NEED_XFS_XQM_H],
   [ AC_CHECK_HEADERS([xfs/xqm.h])
     if test "$ac_cv_header_xfs_xqm_h" != "yes"; then
index 515e16e..7b01754 100644 (file)
@@ -17,7 +17,7 @@ LINUX_TARGETS = xfsctl bstat t_mtab getdevicesize \
        fs_perms testx looptest locktest unwritten_mmap \
        bulkstat_unlink_test bulkstat_unlink_test_modified t_dir_offset
 
-ifeq ($(HAVE_LIBXFS), true)
+ifeq ($(HAVE_XLOG_ASSIGN_LSN), true)
 LINUX_TARGETS += loggen
 endif