diff options
Diffstat (limited to 'io')
-rw-r--r-- | io/Makefile | 6 | ||||
-rw-r--r-- | io/Versions | 4 | ||||
-rw-r--r-- | io/fcntl.h | 41 |
3 files changed, 48 insertions, 3 deletions
diff --git a/io/Makefile b/io/Makefile index 9dccdb96df..5d7c4c864e 100644 --- a/io/Makefile +++ b/io/Makefile @@ -1,4 +1,4 @@ -# Copyright (C) 1992, 93, 94, 95, 96, 97, 98, 99 Free Software Foundation, Inc. +# Copyright (C) 1992-1999, 2000 Free Software Foundation, Inc. # This file is part of the GNU C Library. # The GNU C Library is free software; you can redistribute it and/or @@ -44,7 +44,9 @@ routines := \ ttyname ttyname_r isatty \ link symlink readlink \ unlink rmdir \ - ftw ftw64 fts poll + ftw ftw64 fts poll \ + posix_fadvise posix_fadvise64 \ + posix_fallocate posix_fallocate64 # These routines will be omitted from the libc shared object. # Instead the static object files will be included in a special archive diff --git a/io/Versions b/io/Versions index 3cfe41511a..10df42253a 100644 --- a/io/Versions +++ b/io/Versions @@ -91,4 +91,8 @@ libc { # For the cancelation wrappers. __libc_open64; __libc_lseek64; } + GLIBC_2.2 { + # p* + posix_fadvise; posix_fadvise64; posix_fallocate; posix_fallocate64; + } } diff --git a/io/fcntl.h b/io/fcntl.h index 8706a44dc8..7ab542642c 100644 --- a/io/fcntl.h +++ b/io/fcntl.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1991,92,94,95,96,97,98,99 Free Software Foundation, Inc. +/* Copyright (C) 1991,92,94,95,96,97,98,99, 2000 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -125,6 +125,45 @@ extern int lockf64 (int __fd, int __cmd, __off64_t __len) __THROW; # endif #endif +#ifdef __USE_XOPEN2K +/* Advice the system about the expected behaviour of the application with + respect to the file associated with FD. */ +# ifndef __USE_FILE_OFFSET64 +extern int posix_fadvise (int __fd, __off_t __offset, size_t __len, + int __advise) __THROW; +# else +# ifdef __REDIRECT +extern int __REDIRECT (posix_fadvise, (int __fd, __off64_t __offset, + size_t __len, int __advise) __THROW, + posix_fadvise64); +# else +# define posix_fadvise posix_fadvise64 +# endif +# endif +# ifdef __USE_LARGEFILE64 +extern int posix_fadvise64 (int __fd, __off64_t __offset, size_t __len, + int __advise) __THROW; +# endif + + +/* Reserve storage for the data of the file associated with FD. */ +# ifndef __USE_FILE_OFFSET64 +extern int posix_fallocate (int __fd, __off_t __offset, size_t __len) __THROW; +# else +# ifdef __REDIRECT +extern int __REDIRECT (posix_fallocate, (int __fd, __off64_t __offset, + size_t __len) __THROW, + posix_fallocate64); +# else +# define posix_fallocate posix_fallocate64 +# endif +# endif +# ifdef __USE_LARGEFILE64 +extern int posix_fallocate64 (int __fd, __off64_t __offset, size_t __len) + __THROW; +# endif +#endif + __END_DECLS #endif /* fcntl.h */ |