mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-27 10:54:40 +00:00
Default to inotify instead of gfile
* configure.ac (with_file_notification): Fix typo that prevented suppression of file notification if HAVE_NS. (NOTIFY_OBJ): Prefer inotify to gfile if both exist and with_file_notification is 'yes' (Bug#21241). * etc/NEWS: Mention this.
This commit is contained in:
parent
0abf56df5d
commit
200c2b10fa
34
configure.ac
34
configure.ac
@ -365,7 +365,7 @@ AC_ARG_WITH([file-notification],[AS_HELP_STRING([--with-file-notification=LIB],
|
||||
* ) AC_MSG_ERROR(['--with-file-notification=$withval' is invalid;
|
||||
this option's value should be 'yes', 'no', 'gfile', 'inotify' or 'w32'.
|
||||
'yes' is a synonym for 'w32' on MS-Windows, for 'no' on Nextstep,
|
||||
otherwise for the first of 'gfile' or 'inotify' that is usable.])
|
||||
otherwise for the first of 'inotify' or 'gfile' that is usable.])
|
||||
;;
|
||||
esac
|
||||
with_file_notification=$val
|
||||
@ -2674,7 +2674,7 @@ NOTIFY_SUMMARY=no
|
||||
|
||||
dnl FIXME? Don't auto-detect on NS, but do allow someone to specify
|
||||
dnl a particular library. This doesn't make much sense?
|
||||
if test "${HAVE_ns}" = yes && test ${with_file_notification} = yes; then
|
||||
if test "${HAVE_NS}" = yes && test ${with_file_notification} = yes; then
|
||||
with_file_notification=no
|
||||
fi
|
||||
|
||||
@ -2694,22 +2694,7 @@ case $with_file_notification,$opsys in
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
dnl g_file_monitor exists since glib 2.18. G_FILE_MONITOR_EVENT_MOVED
|
||||
dnl has been added in glib 2.24. It has been tested under
|
||||
dnl GNU/Linux only. We take precedence over inotify, but this makes
|
||||
dnl only sense when glib has been compiled with inotify support. How
|
||||
dnl to check?
|
||||
case $with_file_notification,$NOTIFY_OBJ in
|
||||
gfile, | yes,)
|
||||
EMACS_CHECK_MODULES([GFILENOTIFY], [gio-2.0 >= 2.24])
|
||||
if test "$HAVE_GFILENOTIFY" = "yes"; then
|
||||
AC_DEFINE(HAVE_GFILENOTIFY, 1, [Define to 1 if using GFile.])
|
||||
NOTIFY_OBJ=gfilenotify.o
|
||||
NOTIFY_SUMMARY="yes -lgio (gfile)"
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
dnl inotify is only available on GNU/Linux.
|
||||
dnl inotify is available only on GNU/Linux.
|
||||
case $with_file_notification,$NOTIFY_OBJ in
|
||||
inotify, | yes,)
|
||||
AC_CHECK_HEADER(sys/inotify.h)
|
||||
@ -2723,6 +2708,19 @@ case $with_file_notification,$NOTIFY_OBJ in
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
dnl g_file_monitor exists since glib 2.18. G_FILE_MONITOR_EVENT_MOVED
|
||||
dnl has been added in glib 2.24. It has been tested under
|
||||
dnl GNU/Linux only.
|
||||
case $with_file_notification,$NOTIFY_OBJ in
|
||||
gfile,* | yes,)
|
||||
EMACS_CHECK_MODULES([GFILENOTIFY], [gio-2.0 >= 2.24])
|
||||
if test "$HAVE_GFILENOTIFY" = "yes"; then
|
||||
AC_DEFINE(HAVE_GFILENOTIFY, 1, [Define to 1 if using GFile.])
|
||||
NOTIFY_OBJ=gfilenotify.o
|
||||
NOTIFY_SUMMARY="yes -lgio (gfile)"
|
||||
fi ;;
|
||||
esac
|
||||
|
||||
case $with_file_notification,$NOTIFY_OBJ in
|
||||
yes,* | no,* | *,?*) ;;
|
||||
*) AC_MSG_ERROR([File notification '$with_file_notification' requested but requirements not found.]) ;;
|
||||
|
4
etc/NEWS
4
etc/NEWS
@ -42,6 +42,10 @@ or by sticking with Emacs 24.4.
|
||||
** 'configure' now prefers gnustep-config when configuring GNUstep.
|
||||
If gnustep-config is not available, the old heuristics are used.
|
||||
|
||||
---
|
||||
** 'configure' now prefers inotify to gfile for file notification,
|
||||
unless gfile is explicitly requested via --with-file-notification='gfile'.
|
||||
|
||||
---
|
||||
** The configure option '--with-pkg-config-prog' has been removed.
|
||||
Use './configure PKG_CONFIG=/full/name/of/pkg-config' if you need to.
|
||||
|
Loading…
Reference in New Issue
Block a user