mirror of
git://git.sv.gnu.org/autoconf
synced 2025-01-06 10:25:53 +08:00
autoconf: don't assume sys/stat.h and sys/types.h when testing C89
Problem reported by Patrick Pelissier in <http://lists.gnu.org/archive/html/bug-autoconf/2010-11/msg00019.html>. * lib/autoconf/c.m4 (_AC_PROG_CC_C89): Don't include sys/types.h and sys/stat.h. Instead, define a dummy struct stat. C89 doesn't guarantee sys/types.h and sys/stat.h.
This commit is contained in:
parent
5668bc9791
commit
234d3c3268
@ -1,3 +1,12 @@
|
||||
2010-11-20 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
autoconf: don't assume sys/stat.h and sys/types.h when testing C89
|
||||
Problem reported by Patrick Pelissier in
|
||||
<http://lists.gnu.org/archive/html/bug-autoconf/2010-11/msg00019.html>.
|
||||
* lib/autoconf/c.m4 (_AC_PROG_CC_C89): Don't include sys/types.h
|
||||
and sys/stat.h. Instead, define a dummy struct stat. C89 doesn't
|
||||
guarantee sys/types.h and sys/stat.h.
|
||||
|
||||
2010-11-10 Reuben Thomas <rrt@sc3d.org> (tiny change)
|
||||
|
||||
docs: avoid first person, and credit history to David MacKenzie
|
||||
|
@ -1102,8 +1102,7 @@ AC_DEFUN([_AC_PROG_CC_C89],
|
||||
[_AC_C_STD_TRY([c89],
|
||||
[[#include <stdarg.h>
|
||||
#include <stdio.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
struct stat;
|
||||
/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
|
||||
struct buf { int x; };
|
||||
FILE * (*rcsopen) (struct buf *, struct stat *, int);
|
||||
|
Loading…
Reference in New Issue
Block a user