summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1994-04-19 13:40:42 +0000
committerJim Meyering <jim@meyering.net>1994-04-19 13:40:42 +0000
commit33955663adecd4b67164dff735df6ff5d517900e (patch)
treed55da9921b10f8ad3bf845a1fdc1566c25d7fa9c /lib
parente614cf3cbbb27c13ca1c56c3c925a8ebaa60ccb1 (diff)
downloadcoreutils-33955663adecd4b67164dff735df6ff5d517900e.tar.xz
merge with 1.9.4e
Diffstat (limited to 'lib')
-rw-r--r--lib/getdate.y21
-rw-r--r--lib/getopt.c9
2 files changed, 6 insertions, 24 deletions
diff --git a/lib/getdate.y b/lib/getdate.y
index f3014fb94..6d93a57d6 100644
--- a/lib/getdate.y
+++ b/lib/getdate.y
@@ -31,26 +31,6 @@
#undef static
#endif
-/* The following block of alloca-related preprocessor directives is here
- solely to allow compilation by non GNU-C compilers of the C parser
- produced from this file by old versions of bison. Newer versions of
- bison include a block similar to this one in bison.simple. */
-
-#ifdef __GNUC__
-#undef alloca
-#define alloca __builtin_alloca
-#else
-#ifdef HAVE_ALLOCA_H
-#include <alloca.h>
-#else
-#ifdef _AIX /* for Bison */
- #pragma alloca
-#else
-void *alloca ();
-#endif
-#endif
-#endif
-
#include <stdio.h>
#include <ctype.h>
@@ -967,6 +947,7 @@ get_date(p, now)
#if defined(TEST)
/* ARGSUSED */
+int
main(ac, av)
int ac;
char *av[];
diff --git a/lib/getopt.c b/lib/getopt.c
index 812258ae3..654f76159 100644
--- a/lib/getopt.c
+++ b/lib/getopt.c
@@ -190,11 +190,12 @@ my_index (str, chr)
/* If using GCC, we can safely declare strlen this way.
If not using GCC, it is ok not to declare it. */
#ifdef __GNUC__
+/* Note that Motorola Delta 68k R3V7 comes with GCC but not stddef.h.
+ That was relevant to code that was here before. */
#ifndef __STDC__
-/* Motorola Delta 68k R3V7 comes with GCC but not stddef.h.
- Enable Emacs to compile on it. */
-#include <stddef.h>
-extern size_t strlen (const char *);
+/* gcc with -traditional declares the built-in strlen to return int,
+ and has done so at least since version 2.4.5. -- rms. */
+extern int strlen (const char *);
#endif /* not __STDC__ */
#endif /* __GNUC__ */