From 826d6e4b7f34dbee3e6c3d0bdc08f2497e46d2f6 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Fri, 6 Apr 2007 01:09:19 +0000 Subject: r22097: Add detection for linux readahead() syscall. Jeremy. (This used to be commit 4e3232aad4179e4ca9a1138bc43addec2ea6d9cc) --- source3/configure.in | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'source3/configure.in') 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 +#endif +#include ], + [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 -- cgit