From b08defd70c2bab030dcdd174fbd8e3564b09533c Mon Sep 17 00:00:00 2001 From: Karl DeBisschop Date: Wed, 18 Feb 2004 14:56:39 +0000 Subject: underquoted defines cause warning on FC2 git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@805 f882894a-f735-0410-b71e-b25c423dba1c --- acinclude.m4 | 2 +- lib/afs.m4 | 23 ++++++++++++----------- lib/fstypename.m4 | 8 ++++---- lib/fsusage.m4 | 23 ++++++++++++++--------- 4 files changed, 31 insertions(+), 25 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 70d82e4b..7de65550 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -14,7 +14,7 @@ dnl dnl based on version by Caolan McNamara dnl based on David Arnold's autoconf suggestion in the threads faq dnl -AC_DEFUN(ACX_WHICH_GETHOSTBYNAME_R, +AC_DEFUN([ACX_WHICH_GETHOSTBYNAME_R], [AC_CACHE_CHECK(number of arguments to gethostbyname_r, acx_which_gethostbyname_r, [ AC_TRY_COMPILE([ diff --git a/lib/afs.m4 b/lib/afs.m4 index 905ef42a..9e7d7731 100644 --- a/lib/afs.m4 +++ b/lib/afs.m4 @@ -1,12 +1,13 @@ -#serial 3 +#serial 5 -AC_DEFUN(jm_AFS, - AC_MSG_CHECKING(for AFS) - if test -d /afs; then - AC_DEFINE_UNQUOTED(AFS, 1, [Define if you have the Andrew File System.]) - ac_result=yes - else - ac_result=no - fi - AC_MSG_RESULT($ac_result) -) +AC_DEFUN([jm_AFS], + [ + AC_MSG_CHECKING(for AFS) + if test -d /afs; then + AC_DEFINE(AFS, 1, [Define if you have the Andrew File System.]) + ac_result=yes + else + ac_result=no + fi + AC_MSG_RESULT($ac_result) + ]) diff --git a/lib/fstypename.m4 b/lib/fstypename.m4 index 70abc12b..75723a14 100644 --- a/lib/fstypename.m4 +++ b/lib/fstypename.m4 @@ -1,4 +1,4 @@ -#serial 2 +#serial 3 dnl From Jim Meyering. dnl @@ -6,7 +6,7 @@ dnl See if struct statfs has the f_fstypename member. dnl If so, define HAVE_F_FSTYPENAME_IN_STATFS. dnl -AC_DEFUN(jm_FSTYPENAME, +AC_DEFUN([jm_FSTYPENAME], [ AC_CACHE_CHECK([for f_fstypename in struct statfs], fu_cv_sys_f_fstypename_in_statfs, @@ -25,8 +25,8 @@ AC_DEFUN(jm_FSTYPENAME, ) if test $fu_cv_sys_f_fstypename_in_statfs = yes; then - AC_DEFINE_UNQUOTED(HAVE_F_FSTYPENAME_IN_STATFS, 1, - [Define if struct statfs has the f_fstypename member.]) + AC_DEFINE(HAVE_F_FSTYPENAME_IN_STATFS, 1, + [Define if struct statfs has the f_fstypename member.]) fi ] ) diff --git a/lib/fsusage.m4 b/lib/fsusage.m4 index d5c646f4..85d0fc8f 100644 --- a/lib/fsusage.m4 +++ b/lib/fsusage.m4 @@ -1,4 +1,4 @@ -#serial 7 +#serial 9 # From fileutils/configure.in @@ -8,7 +8,7 @@ # # jm_FILE_SYSTEM_USAGE([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) -AC_DEFUN(jm_FILE_SYSTEM_USAGE, +AC_DEFUN([jm_FILE_SYSTEM_USAGE], [ echo "checking how to get filesystem space usage..." @@ -24,13 +24,18 @@ if test $ac_fsusage_space = no; then # SVR4 AC_CACHE_CHECK([for statvfs function (SVR4)], fu_cv_sys_stat_statvfs, [AC_TRY_LINK([#include +#ifdef __GLIBC__ +Do not use statvfs on systems with GNU libc, because that function stats +all preceding entries in /proc/mounts, and that makes df hang if even +one of the corresponding file systems is hard-mounted, but not available. +#endif #include ], [struct statvfs fsd; statvfs (0, &fsd);], fu_cv_sys_stat_statvfs=yes, fu_cv_sys_stat_statvfs=no)]) if test $fu_cv_sys_stat_statvfs = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATVFS, 1, + AC_DEFINE(STAT_STATVFS, 1, [ Define if there is a function named statvfs. (SVR4)]) fi fi @@ -55,7 +60,7 @@ if test $ac_fsusage_space = no; then AC_MSG_RESULT($fu_cv_sys_stat_statfs3_osf1) if test $fu_cv_sys_stat_statfs3_osf1 = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATFS3_OSF1, 1, + AC_DEFINE(STAT_STATFS3_OSF1, 1, [ Define if statfs takes 3 args. (DEC Alpha running OSF/1)]) fi fi @@ -87,7 +92,7 @@ member (AIX, 4.3BSD)]) AC_MSG_RESULT($fu_cv_sys_stat_statfs2_bsize) if test $fu_cv_sys_stat_statfs2_bsize = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATFS2_BSIZE, 1, + AC_DEFINE(STAT_STATFS2_BSIZE, 1, [ Define if statfs takes 2 args and struct statfs has a field named f_bsize. (4.3BSD, SunOS 4, HP-UX, AIX PS/2)]) fi @@ -110,7 +115,7 @@ if test $ac_fsusage_space = no; then AC_MSG_RESULT($fu_cv_sys_stat_statfs4) if test $fu_cv_sys_stat_statfs4 = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATFS4, 1, + AC_DEFINE(STAT_STATFS4, 1, [ Define if statfs takes 4 args. (SVR3, Dynix, Irix, Dolphin)]) fi fi @@ -139,7 +144,7 @@ member (4.4BSD and NetBSD)]) AC_MSG_RESULT($fu_cv_sys_stat_statfs2_fsize) if test $fu_cv_sys_stat_statfs2_fsize = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATFS2_FSIZE, 1, + AC_DEFINE(STAT_STATFS2_FSIZE, 1, [ Define if statfs takes 2 args and struct statfs has a field named f_fsize. (4.4BSD, NetBSD)]) fi @@ -172,7 +177,7 @@ if test $ac_fsusage_space = no; then AC_MSG_RESULT($fu_cv_sys_stat_fs_data) if test $fu_cv_sys_stat_fs_data = yes; then ac_fsusage_space=yes - AC_DEFINE_UNQUOTED(STAT_STATFS2_FS_DATA, 1, + AC_DEFINE(STAT_STATFS2_FS_DATA, 1, [ Define if statfs takes 2 args and the second argument has type struct fs_data. (Ultrix)]) fi @@ -182,7 +187,7 @@ if test $ac_fsusage_space = no; then # SVR2 AC_TRY_CPP([#include ], - AC_DEFINE_UNQUOTED(STAT_READ_FILSYS, 1, + AC_DEFINE(STAT_READ_FILSYS, 1, [Define if there is no specific function for reading filesystems usage information and you have the header file. (SVR2)]) ac_fsusage_space=yes) -- cgit v1.2.3