Need to check for IN_MOVE_SELF too, added somewhere in the 2.6.13 rc

series.


SVN revision: 16400
This commit is contained in:
sebastid 2005-08-29 16:19:53 +00:00 committed by sebastid
parent a83d7cb3b3
commit c483ab195e
1 changed files with 6 additions and 3 deletions

View File

@ -868,12 +868,15 @@ AC_ARG_ENABLE(inotify,
dnl It's hard to find a good test on how to check the correct
dnl inotify version. They changed the headers a lot.
dnl in kernel 2.6.13 __NR_inotify_init was added to the defined syscalls
dnl in asm/unistd.h
dnl in asm/unistd.h and IN_MOVE_SELF was added to linux/inotify.h
dnl so with this check you need a very new kernel and kernel-headers!
if test "x$use_inotify" = "xyes"; then
AC_TRY_COMPILE(
[#include <asm/unistd.h>],
[int i = __NR_inotify_init;],
[
#include <asm/unistd.h>
#include <linux/inotify.h>
],
[int a = __NR_inotify_init; int b = IN_MOVE_SELF;],
[
AC_DEFINE(HAVE_INOTIFY, 1, [ File monitoring with Inotify ])
use_inotify="yes"