diff options
author | Jeremy Allison <jra@samba.org> | 2007-04-06 01:09:19 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:19:12 -0500 |
commit | 826d6e4b7f34dbee3e6c3d0bdc08f2497e46d2f6 (patch) | |
tree | 07bb74050f7cab7135d463e70e78ae808e2fef84 /source3 | |
parent | bc45c82904e268327bfbf72cd3f35699ae6e7397 (diff) | |
download | samba-826d6e4b7f34dbee3e6c3d0bdc08f2497e46d2f6.tar.gz samba-826d6e4b7f34dbee3e6c3d0bdc08f2497e46d2f6.tar.bz2 samba-826d6e4b7f34dbee3e6c3d0bdc08f2497e46d2f6.zip |
r22097: Add detection for linux readahead() syscall.
Jeremy.
(This used to be commit 4e3232aad4179e4ca9a1138bc43addec2ea6d9cc)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/configure.in | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/source3/configure.in b/source3/configure.in index 803425a66a..7eb1b78a01 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -5649,6 +5649,25 @@ samba_cv_HAVE_SENDFILE=yes,samba_cv_HAVE_SENDFILE=no)]) AC_MSG_RESULT(yes) ) +############################################ +# See if we have the Linux readahead syscall. + +AC_CACHE_CHECK([for Linux readahead], + samba_cv_HAVE_LINUX_READAHEAD,[ + AC_TRY_LINK([ +#if defined(HAVE_UNISTD_H) +#include <unistd.h> +#endif +#include <fcntl.h>], + [ssize_t err = readahead(0,0,0x80000);], + samba_cv_HAVE_LINUX_READAHEAD=yes, + samba_cv_HAVE_LINUX_READAHEAD=no)]) + +if test x"$samba_cv_HAVE_LINUX_READAHEAD" = x"yes"; then + AC_DEFINE(HAVE_LINUX_READAHEAD,1, + [Whether Linux readahead is available]) +fi + ################################################# # Check whether winbind is supported on this platform. If so we need to |