]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
DEVEL15-linux-aio-functions-improved-test-20061011
authorDerrick Brashear <shadow@dementia.org>
Thu, 12 Oct 2006 03:58:05 +0000 (03:58 +0000)
committerDerrick Brashear <shadow@dementia.org>
Thu, 12 Oct 2006 03:58:05 +0000 (03:58 +0000)
detect properly if we have nothing

(cherry picked from commit d71d42d29f923750be4f4f518b8d0e72dba8fa23)

src/cf/linux-test4.m4

index 4585ea7d43e54a14f161760f0656cf0a390c9c04..4693871306278f93913ac668b9d8422453d6c1de 100644 (file)
@@ -650,9 +650,16 @@ AC_DEFUN([LINUX_DO_SYNC_READ], [
   AC_CACHE_VAL([ac_cv_linux_do_sync_read], [
     AC_TRY_KBUILD(
 [#include <linux/fs.h>],
+[do_sync_read(NULL, NULL, 0, NULL, 0);],
+      ac_cv_linux_do_sync_read=no,
+      ac_cv_linux_do_sync_read=maybe)
+    if test "x$ac_cv_linux_do_sync_read" = "xmaybe"; then
+    AC_TRY_KBUILD(
+[#include <linux/fs.h>],
 [do_sync_read(NULL, NULL, 0, NULL);],
       ac_cv_linux_do_sync_read=yes,
       ac_cv_linux_do_sync_read=no)])
+    fi
   AC_MSG_RESULT($ac_cv_linux_do_sync_read)
   if test "x$ac_cv_linux_do_sync_read" = "xyes"; then
     AC_DEFINE([DO_SYNC_READ], 1, [define if your kernel has do_sync_read()])
@@ -663,10 +670,18 @@ AC_DEFUN([LINUX_GENERIC_FILE_AIO_READ], [
   AC_CACHE_VAL([ac_cv_linux_generic_file_aio_read], [
     AC_TRY_KBUILD(
 [#include <linux/fs.h>],
+[generic_file_aio_read(NULL, NULL, 0, 0, 0);],
+      ac_cv_linux_generic_file_aio_read=no,
+      ac_cv_linux_generic_file_aio_read=maybe)
+    if test "x$ac_cv_linux_generic_file_aio_read" = "xmaybe"; then
+    AC_TRY_KBUILD(
+[#include <linux/fs.h>],
 [generic_file_aio_read(NULL, NULL, 0, 0);],
       ac_cv_linux_generic_file_aio_read=yes,
       ac_cv_linux_generic_file_aio_read=no)])
+    fi
   AC_MSG_RESULT($ac_cv_linux_generic_file_aio_read)
   if test "x$ac_cv_linux_generic_file_aio_read" = "xyes"; then
     AC_DEFINE([GENERIC_FILE_AIO_READ], 1, [define if your kernel has generic_file_aio_read()])
   fi])
+