diff options
author | Aaron W. LaFramboise <aaronavay62@aaronwl.com> | 2004-09-18 17:55:22 -0600 |
---|---|---|
committer | Paul Brook <pbrook@gcc.gnu.org> | 2004-09-18 23:55:22 +0000 |
commit | f596fc98eae2d6f6c706084a48f2c3cfc1654af0 (patch) | |
tree | 9fc0e6f0808aab6252b356bb1128fac96c0b3d69 /libgfortran/io/unix.c | |
parent | 16d1b0bd17190fd36413ef28af6ef2ecebb31011 (diff) | |
download | gcc-f596fc98eae2d6f6c706084a48f2c3cfc1654af0.zip gcc-f596fc98eae2d6f6c706084a48f2c3cfc1654af0.tar.gz gcc-f596fc98eae2d6f6c706084a48f2c3cfc1654af0.tar.bz2 |
config.h.in: Regenerate.
2004-09-15 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
* config.h.in: Regenerate.
* configure: Regenerate.
* configure.ac (AC_CHECK_HEADERS): Check for sys/mman.h.
* unix.c: Include stdio.h.
(HAVE_SYS_MMAN_H): Check.
(PROT_READ, PROT_WRITE): Provide default definitions.
From-SVN: r87714
Diffstat (limited to 'libgfortran/io/unix.c')
-rw-r--r-- | libgfortran/io/unix.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libgfortran/io/unix.c b/libgfortran/io/unix.c index 377cadd..e55966b 100644 --- a/libgfortran/io/unix.c +++ b/libgfortran/io/unix.c @@ -28,7 +28,9 @@ Boston, MA 02111-1307, USA. */ #include <sys/stat.h> #include <fcntl.h> +#ifdef HAVE_SYS_MMAN_H #include <sys/mman.h> +#endif #include <string.h> #include <errno.h> @@ -43,6 +45,14 @@ Boston, MA 02111-1307, USA. */ #define MAP_FAILED ((void *) -1) #endif +#ifndef PROT_READ +#define PROT_READ 1 +#endif + +#ifndef PROT_WRITE +#define PROT_WRITE 2 +#endif + /* This implementation of stream I/O is based on the paper: * * "Exploiting the advantages of mapped files for stream I/O", |