From 0b7fe2dc03f9a8e5330f4c96f5d6279f61f3fb1d Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Mon, 4 Oct 1993 21:07:58 +0000 Subject: [PATCH] GNU shell utilities --- lib/alloca.c | 4 ++++ lib/getopt.c | 6 +++++- lib/getopt1.c | 6 +++++- lib/xmalloc.c | 3 ++- 4 files changed, 16 insertions(+), 3 deletions(-) diff --git a/lib/alloca.c b/lib/alloca.c index cab9645b7..bd4932aa4 100644 --- a/lib/alloca.c +++ b/lib/alloca.c @@ -22,8 +22,12 @@ your main control loop, etc. to force garbage collection. */ #ifdef HAVE_CONFIG_H +#if defined (emacs) || defined (CONFIG_BROKETS) +#include +#else #include "config.h" #endif +#endif /* If compiling with GCC 2, this file's not needed. */ #if !defined (__GNUC__) || __GNUC__ < 2 diff --git a/lib/getopt.c b/lib/getopt.c index 49db99856..7a4673b8d 100644 --- a/lib/getopt.c +++ b/lib/getopt.c @@ -21,10 +21,14 @@ Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ #ifdef HAVE_CONFIG_H +#if defined (emacs) || defined (CONFIG_BROKETS) /* We use instead of "config.h" so that a compilation using -I. -I$srcdir will use ./config.h rather than $srcdir/config.h - (which it would do because getopt.c was found in $srcdir). */ + (which it would do because it found this file in $srcdir). */ #include +#else +#include "config.h" +#endif #endif #ifndef __STDC__ diff --git a/lib/getopt1.c b/lib/getopt1.c index 2b93f7835..f784b5757 100644 --- a/lib/getopt1.c +++ b/lib/getopt1.c @@ -17,10 +17,14 @@ Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ #ifdef HAVE_CONFIG_H +#if defined (emacs) || defined (CONFIG_BROKETS) /* We use instead of "config.h" so that a compilation using -I. -I$srcdir will use ./config.h rather than $srcdir/config.h - (which it would do because getopt1.c was found in $srcdir). */ + (which it would do because it found this file in $srcdir). */ #include +#else +#include "config.h" +#endif #endif #include "getopt.h" diff --git a/lib/xmalloc.c b/lib/xmalloc.c index d58db5ed5..bce432513 100644 --- a/lib/xmalloc.c +++ b/lib/xmalloc.c @@ -25,10 +25,11 @@ #define VOID char #endif +#include + #if STDC_HEADERS #include #else -#include VOID *malloc (); VOID *realloc (); void free (); -- 2.11.0