From 2f17b5a85fb0021903daea2f4cc0026507e114f2 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sat, 8 Oct 1994 02:04:47 +0000 Subject: . --- lib/fsusage.c | 33 +++++++++++++++------------------ 1 file changed, 15 insertions(+), 18 deletions(-) (limited to 'lib/fsusage.c') diff --git a/lib/fsusage.c b/lib/fsusage.c index 9bef62aba7..503b3875ec 100644 --- a/lib/fsusage.c +++ b/lib/fsusage.c @@ -25,39 +25,36 @@ int statfs (); -#if defined (STAT_STATFS3_OSF1) /* DEC Alpha running OSF/1 */ -# include +#ifdef HAVE_SYS_PARAM_H +#include #endif -#if defined(STAT_STATFS2_BSIZE) && !defined(_IBMR2) /* 4.3BSD, SunOS 4, HP-UX, AIX PS/2. */ -#include +#ifdef HAVE_SYS_MOUNT_H +#include #endif -#ifdef STAT_STATFS2_FSIZE /* 4.4BSD. */ -#include +#ifdef HAVE_SYS_VFS_H +#include #endif -#ifdef STAT_STATFS2_FS_DATA /* Ultrix. */ -#include -#include +#ifdef HAVE_SYS_FILSYS_H +#include /* SVR2. */ #endif -#ifdef STAT_READ /* SVR2. */ -#include -#include +#ifdef HAVE_FCNTL_H #include #endif -#if defined(STAT_STATFS4) || (defined(_AIX) && defined(_IBMR2)) /* SVR3, Dynix, Irix, AIX RS6000. */ +#ifdef HAVE_SYS_STATFS_H #include #endif -#if defined(_AIX) && defined(_I386) /* AIX PS/2. */ +#ifdef HAVE_DUSTAT_H /* AIX PS/2. */ #include #include #endif -#ifdef STAT_STATVFS /* SVR4. */ +#ifdef HAVE_SYS_STATVFS_H /* SVR4. */ #include int statvfs (); #endif @@ -116,7 +113,7 @@ get_fs_usage (path, disk, fsp) fsp->fsu_ffree = fsd.fd_req.gfree; #endif -#ifdef STAT_READ /* SVR2. */ +#ifdef STAT_READ_FILSYS /* SVR2. */ #ifndef SUPERBOFF #define SUPERBOFF (SUPERB * 512) #endif @@ -173,7 +170,7 @@ get_fs_usage (path, disk, fsp) #endif #endif -#ifdef STAT_STATVFS /* SVR4. */ +#ifdef HAVE_SYS_STATVFS_H /* SVR4. */ struct statvfs fsd; if (statvfs (path, &fsd) < 0) @@ -183,7 +180,7 @@ get_fs_usage (path, disk, fsp) adjust_blocks ((b), fsd.f_frsize ? fsd.f_frsize : fsd.f_bsize, 512) #endif -#if !defined(STAT_STATFS2_FS_DATA) && !defined(STAT_READ) /* !Ultrix && !SVR2. */ +#if !defined(STAT_STATFS2_FS_DATA) && !defined(STAT_READ_FILSYS) /* !Ultrix && !SVR2. */ fsp->fsu_blocks = CONVERT_BLOCKS (fsd.f_blocks); fsp->fsu_bfree = CONVERT_BLOCKS (fsd.f_bfree); fsp->fsu_bavail = CONVERT_BLOCKS (fsd.f_bavail); -- cgit v1.2.1