changeset 268:a080344c8007

GNU file utilities
author Jim Meyering <jim@meyering.net>
date Tue, 01 Nov 1994 14:36:55 +0000
parents 9bbfbe0458f4
children 021883d392fd
files lib/Makefile.in lib/fsusage.c lib/obstack.c lib/obstack.h
diffstat 4 files changed, 20 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/lib/Makefile.in	Thu Oct 27 23:25:03 1994 +0000
+++ b/lib/Makefile.in	Tue Nov 01 14:36:55 1994 +0000
@@ -61,7 +61,7 @@
 
 subdir = lib
 Makefile: ../config.status Makefile.in
-	cd ..; CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
+	cd .. && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
 
 installdirs:
 
--- a/lib/fsusage.c	Thu Oct 27 23:25:03 1994 +0000
+++ b/lib/fsusage.c	Tue Nov 01 14:36:55 1994 +0000
@@ -154,7 +154,7 @@
 #define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_fsize, 512)
 #endif
 
-#ifdef STAT_STATFS4		/* SVR3, Dynix, Irix.  */
+#ifdef STAT_STATFS4		/* SVR3, Dynix, Irix, AIX.  */
   struct statfs fsd;
 
   if (statfs (path, &fsd, sizeof fsd, 0) < 0)
@@ -162,12 +162,16 @@
   /* Empirically, the block counts on most SVR3 and SVR3-derived
      systems seem to always be in terms of 512-byte blocks,
      no matter what value f_bsize has.  */
-#define CONVERT_BLOCKS(b) (b)
-#ifndef _SEQUENT_		/* _SEQUENT_ is DYNIX/ptx.  */
-#ifndef DOLPHIN			/* DOLPHIN 3.8.alfa/7.18 has f_bavail */
-#define f_bavail f_bfree
-#endif
-#endif
+# if _AIX
+#  define CONVERT_BLOCKS(b) adjust_blocks ((b), fsd.f_bsize, 512)
+# else
+#  define CONVERT_BLOCKS(b) (b)
+#  ifndef _SEQUENT_		/* _SEQUENT_ is DYNIX/ptx.  */
+#   ifndef DOLPHIN		/* DOLPHIN 3.8.alfa/7.18 has f_bavail */
+#    define f_bavail f_bfree
+#   endif
+#  endif
+# endif
 #endif
 
 #ifdef STAT_STATVFS		/* SVR4.  */
--- a/lib/obstack.c	Thu Oct 27 23:25:03 1994 +0000
+++ b/lib/obstack.c	Tue Nov 01 14:36:55 1994 +0000
@@ -31,7 +31,7 @@
 #if defined (_LIBC) || !defined (__GNU_LIBRARY__)
 
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 #define POINTER void *
 #else
 #define POINTER char *
@@ -267,7 +267,7 @@
    This is here for debugging.
    If you use it in a program, you are probably losing.  */
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 /* Suppress -Wmissing-prototypes warning.  We don't want to declare this in
    obstack.h because it is just for debugging.  */
 int _obstack_allocated_p (struct obstack *h, POINTER obj);
@@ -374,7 +374,7 @@
 /* Now define the functional versions of the obstack macros.
    Define them to simply use the corresponding macros to do the job.  */
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 /* These function definitions do not work with non-ANSI preprocessors;
    they won't pass through the macro names in parentheses.  */
 
--- a/lib/obstack.h	Thu Oct 27 23:25:03 1994 +0000
+++ b/lib/obstack.h	Tue Nov 01 14:36:55 1994 +0000
@@ -119,7 +119,7 @@
    but in traditional C it is usually long.  If we are in ANSI C and
    don't already have ptrdiff_t get it.  */
 
-#if defined (__STDC__) && ! defined (offsetof)
+#if defined (__STDC__) && __STDC__ && ! defined (offsetof)
 #if defined (__GNUC__) && defined (IN_GCC)
 /* On Next machine, the system's stddef.h screws up if included
    after we have defined just ptrdiff_t, so include all of stddef.h.
@@ -132,7 +132,7 @@
 #include <stddef.h>
 #endif
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 #define PTR_INT_TYPE ptrdiff_t
 #else
 #define PTR_INT_TYPE long
@@ -167,7 +167,7 @@
 
 /* Declare the external functions we use; they are in obstack.c.  */
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 extern void _obstack_newchunk (struct obstack *, int);
 extern void _obstack_free (struct obstack *, void *);
 extern int _obstack_begin (struct obstack *, int, int,
@@ -181,7 +181,7 @@
 extern int _obstack_begin_1 ();
 #endif
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 
 /* Do the function-declarations after the structs
    but before defining the macros.  */
@@ -492,7 +492,7 @@
   (h)->object_base = (h)->next_free,					\
   __INT_TO_PTR ((h)->temp)))
 
-#ifdef __STDC__
+#if defined (__STDC__) && __STDC__
 #define obstack_free(h,obj)						\
 ( (h)->temp = (char *)(obj) - (char *) (h)->chunk,			\
   (((h)->temp > 0 && (h)->temp < (h)->chunk_limit - (char *) (h)->chunk)\