From d1623ec025efa74f31db1177727c8cc0d34d03b6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bj=C3=B6rn=20Jacke?= Date: Thu, 6 Sep 2012 17:26:55 +0200 Subject: [PATCH] s3:sysquota_xfs: check and include the right fs header file for xfs quotas --- source3/configure.in | 7 ++++--- source3/lib/sysquotas_xfs.c | 5 +++-- source3/wscript | 2 +- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/source3/configure.in b/source3/configure.in index c144e6fc82b..e76e4e42c0d 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -4554,7 +4554,6 @@ case "$host_os" in AC_MSG_CHECKING(whether to use the lib/sysquotas_linux.c builtin support) AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_LINUX_XFS_QUOTAS,1,[Whether Linux xfs quota support is available]) AC_MSG_CHECKING(whether to use the lib/sysquotas_xfs.c builtin support) AC_MSG_RESULT(yes) ;; @@ -4575,8 +4574,10 @@ AC_CHECK_HEADER(asm/types.h,[ # For quotas on Veritas VxFS filesystems AC_CHECK_HEADERS(sys/fs/vx_quota.h) -# For quotas on Linux XFS filesystems -AC_CHECK_HEADERS(linux/dqblk_xfs.h) +# For quotas on XFS filesystems, Linux style +AC_CHECK_HEADERS(xfs/xqm.h,[ + AC_DEFINE(HAVE_LINUX_XFS_QUOTAS,1,[Whether Linux xfs quota support is available]) + ]) # For sys/quota.h and linux/quota.h AC_CHECK_HEADERS(sys/quota.h) diff --git a/source3/lib/sysquotas_xfs.c b/source3/lib/sysquotas_xfs.c index 1e438e9a6d6..7da40efd9b2 100644 --- a/source3/lib/sysquotas_xfs.c +++ b/source3/lib/sysquotas_xfs.c @@ -33,9 +33,10 @@ #ifdef HAVE_LINUX_XFS_QUOTAS #include "samba_linux_quota.h" -#ifdef HAVE_LINUX_DQBLK_XFS_H -#include +#ifdef HAVE_XFS_XQM_H +#include #endif + #define HAVE_GROUP_QUOTA #else /* IRIX */ #include diff --git a/source3/wscript b/source3/wscript index 39a9b92f55d..a496aaa306e 100755 --- a/source3/wscript +++ b/source3/wscript @@ -1189,7 +1189,7 @@ main() { # For quotas on Veritas VxFS filesystems conf.CHECK_HEADERS('sys/fs/vx_quota.h') # For quotas on Linux XFS filesystems - conf.CHECK_HEADERS('linux/dqblk_xfs.h') + conf.CHECK_HEADERS('xfs/xqm.h') # For sys/quota.h and linux/quota.h conf.CHECK_HEADERS('sys/quota.h') # For quotas on BSD systems -- 2.11.4.GIT