Israel G. Lugo: make sure that only one of inotify or FAM gets enabled, giving priority to inotify.
This commit is contained in:
parent
93d0aa3fee
commit
e932144440
@ -80,11 +80,36 @@ if test X$withAspell != Xno ; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if test -f /usr/include/sys/inotify.h ; then
|
||||||
|
inot_default=yes
|
||||||
|
else
|
||||||
|
inot_default=no
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Real time monitoring with inotify
|
||||||
|
AC_ARG_WITH(inotify,
|
||||||
|
AC_HELP_STRING([--with-inotify],
|
||||||
|
[Use inotify for almost real time indexing of modified files.]),
|
||||||
|
withInotify=$withval, withInotify=$inot_default)
|
||||||
|
|
||||||
|
if test X$withInotify != Xno ; then
|
||||||
|
AC_MSG_NOTICE([enabled support for inotify monitoring])
|
||||||
|
AC_DEFINE(RCL_MONITOR, 1, [Real time monitoring option])
|
||||||
|
AC_DEFINE(RCL_USE_INOTIFY, 1, [Compile the inotify interface])
|
||||||
|
else
|
||||||
|
AC_MSG_NOTICE([inotify monitoring disabled])
|
||||||
|
fi
|
||||||
|
|
||||||
# Real time monitoring with FAM
|
# Real time monitoring with FAM
|
||||||
AC_ARG_WITH(fam,
|
AC_ARG_WITH(fam,
|
||||||
AC_HELP_STRING([--with-fam],
|
AC_HELP_STRING([--with-fam],
|
||||||
[Use File Alteration Monitor for almost real time indexing of modified files. Give the fam/gamin library as argument (ie: /usr/lib/libfam.so) if configure does not find the right one.]),
|
[Use File Alteration Monitor for almost real time indexing of modified files. Give the fam/gamin library as argument (ie: /usr/lib/libfam.so) if configure does not find the right one.]),
|
||||||
withFam=$withval, withFam=no)
|
withFam=$withval, withFam=no)
|
||||||
|
if test X$withFam != Xno -a X$withInotify != Xno ; then
|
||||||
|
AC_MSG_NOTICE([FAM support enabled but inotify support also enabled. Disabling FAM support and using inotify])
|
||||||
|
withFam=no
|
||||||
|
fi
|
||||||
|
|
||||||
case $withFam in
|
case $withFam in
|
||||||
no);;
|
no);;
|
||||||
yes)
|
yes)
|
||||||
@ -116,26 +141,6 @@ if test X$withFam != Xno ; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test -f /usr/include/sys/inotify.h -a X$withFam = Xno ; then
|
|
||||||
inot_default=yes
|
|
||||||
else
|
|
||||||
inot_default=no
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Real time monitoring with inotify
|
|
||||||
AC_ARG_WITH(inotify,
|
|
||||||
AC_HELP_STRING([--with-inotify],
|
|
||||||
[Use inotify for almost real time indexing of modified files.]),
|
|
||||||
withInotify=$withval, withInotify=$inot_default)
|
|
||||||
|
|
||||||
if test X$withInotify != Xno ; then
|
|
||||||
AC_MSG_NOTICE([enabled support for inotify monitoring])
|
|
||||||
AC_DEFINE(RCL_MONITOR, 1, [Real time monitoring option])
|
|
||||||
AC_DEFINE(RCL_USE_INOTIFY, 1, [Compile the inotify interface])
|
|
||||||
else
|
|
||||||
AC_MSG_NOTICE([inotify monitoring disabled])
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Enable use of file extended attributes.
|
# Enable use of file extended attributes.
|
||||||
# Not by default as these are little used for now.
|
# Not by default as these are little used for now.
|
||||||
AC_ARG_ENABLE(xattr,
|
AC_ARG_ENABLE(xattr,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user