summaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2011-01-19 22:15:41 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2011-01-19 22:16:29 -0800
commit80905e10d427a3abdeb61e2677a6cbe0f8ac1aba (patch)
treee589c23789b3d0811bbd6f9c2203af595b9cd833 /README
parentc93f15eceb7bad3fd57d32ebf7f0676fb5fd3247 (diff)
downloadgnulib-80905e10d427a3abdeb61e2677a6cbe0f8ac1aba.tar.gz
assume <ctype.h>, ..., <time.h> exist
For years gnulib has been assuming the existence of the headers <ctime.h>, <errno.h>, <fcntl.h>, <locale.h>, <signal.h>, <stdio.h>, <stdlib.h>, <string.h>, and <time.h>. Omit checks for them, since they don't appear to be needed. * README (Portability guidelines): Document this. * lib/flock.c: Assume <fcntl.h> exists. * lib/regex_internal.h: Assume <locale.h> exists. * m4/ctype.m4 (gl_CTYPE_H): Assume <ctype.h> exists. * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Assume <errno.h> exists. * m4/fcntl_h.m4 (gl_FCNTL_H): Assume <fcntl.h> exists. * m4/flock.m4 (gl_PREREQ_FLOCK): Likewise. * m4/locale_h.m4 (gl_LOCALE_H): Assume <locale.h> exists. * m4/regex.m4 (gl_REGEX): Likewise. * m4/signal_h.m4 (gl_SIGNAL_H): Assume <signal.h> exists. * m4/stdio_h.m4 (gl_STDIO_H): Assume <stdio.h> exists. * m4/stdlib_h.m4 (gl_STDLIB_H): Assume <stdlib.h> exists. * m4/string_h.m4 (gl_STRING_H): Assume <string.h> exists. * tests/test-argp.c: Likewise. * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Assume <time.h> exists.
Diffstat (limited to 'README')
-rw-r--r--README11
1 files changed, 7 insertions, 4 deletions
diff --git a/README b/README
index 0d8ac6dd88..492827a03e 100644
--- a/README
+++ b/README
@@ -221,13 +221,16 @@ some point we may start assuming a C89 library as well.
Because we assume a freestanding C89 compiler, Gnulib code can include
<float.h>, <limits.h>, <stdarg.h>, and <stddef.h> unconditionally. It
-can also include hosted headers like <errno.h> that were present in
-Unix Version 7 and are thus widely available. Similarly, many modules
-include <sys/types.h> even though it's not even in C99; that's OK
-since <sys/types.h> has been around nearly forever. <string.h> and
+can also assume the existence of <ctime.h>, <errno.h>, <fcntl.h>,
+<locale.h>, <signal.h>, <stdio.h>, <stdlib.h>, <string.h>, and
+<time.h>. Some of these headers, such as <errno.h>, were present in
+Unix Version 7 and are thus widely available. <string.h> and
<stdlib.h> were not in Unix Version 7, so they weren't universally
available on ancient hosts, but they are both in SunOS 4 (the oldest
platform still in relatively-common use) so Gnulib assumes them now.
+Similarly, many modules include <sys/types.h> even though it's not
+even in C99; that's OK since <sys/types.h> has been around nearly
+forever.
Even if the include files exist, they may not conform to C89.
However, GCC has a "fixincludes" script that attempts to fix most