1
0
mirror of https://git.savannah.gnu.org/git/gperf.git synced 2025-12-02 21:19:24 +00:00

Tweak last commit.

This commit is contained in:
Bruno Haible
2016-11-27 19:52:08 +01:00
parent cabd2af10e
commit 13df195c62
2 changed files with 8 additions and 2 deletions

View File

@@ -2,8 +2,8 @@
Assume the available C compiler supports ANSI C. Remove K&R C cruft.
* lib/getopt.h: Assume 'const' is defined. Use ANSI C prototypes.
* lib/getopt.c: Assume 'const' is defined, 'strlen' is declared. Use
ANSI C prototypes.
* lib/getopt.c: Assume 'const' is defined. Use ANSI C prototypes.
Include <stddef.h>. Declare strcmp and strlen.
* lib/getopt1.c: Assume 'const' and NULL are defined. Use ANSI C
prototypes.
* lib/getopt.h.patch: Remove file.

View File

@@ -50,6 +50,9 @@
#ifndef ELIDE_CODE
/* Get size_t. */
#include <stddef.h>
/* This needs to come after some library #include
to get __GNU_LIBRARY__ defined. */
#ifdef __GNU_LIBRARY__
@@ -206,6 +209,9 @@ my_index (const char *str, int chr)
return 0;
}
extern int strcmp (const char *, const char *);
extern size_t strlen (const char *);
#endif /* not __GNU_LIBRARY__ */
/* Handle permutation of arguments. */