• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1dnl
2dnl Copyright (c) 2013 Fujitsu Ltd.
3dnl Author: DAN LI <li.dan@cn.fujitsu.com>
4dnl
5dnl This program is free software;  you can redistribute it and/or modify
6dnl it under the terms of the GNU General Public License as published by
7dnl the Free Software Foundation; either version 2 of the License, or
8dnl (at your option) any later version.
9dnl
10dnl This program is distributed in the hope that it will be useful,
11dnl but WITHOUT ANY WARRANTY;  without even the implied warranty of
12dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See
13dnl the GNU General Public License for more details.
14dnl
15dnl You should have received a copy of the GNU General Public License
16dnl along with this program;  if not, write to the Free Software
17dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18dnl
19
20dnl
21dnl LTP_CHECK_XFS_QUOTACTL
22dnl ----------------------------
23dnl
24AC_DEFUN([LTP_CHECK_XFS_QUOTACTL],[dnl
25	AC_MSG_CHECKING([for XFS quota (xfs/xqm.h)])
26	AC_LINK_IFELSE([AC_LANG_SOURCE([
27#include <xfs/xqm.h>
28#include <sys/quota.h>
29int main(void) {
30	struct fs_quota_stat qstat;
31	return quotactl(QCMD(Q_XGETQSTAT, USRQUOTA), "/dev/null", geteuid(),
32			(caddr_t) &qstat);
33}])],[has_xfs_quota="yes"])
34
35if test "x$has_xfs_quota" = xyes; then
36	AC_DEFINE(HAVE_XFS_QUOTA,1,[Define to 1 if you have xfs quota])
37	AC_MSG_RESULT(yes)
38else
39	AC_MSG_RESULT(no)
40fi
41])
42