[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 200c2b1: Default to inotify instead of gfile
From: |
Paul Eggert |
Subject: |
[Emacs-diffs] master 200c2b1: Default to inotify instead of gfile |
Date: |
Sat, 15 Aug 2015 01:22:16 +0000 |
branch: master
commit 200c2b10faf298bf65e8b6dbd0cb9ef00b2f95d6
Author: Paul Eggert <address@hidden>
Commit: Paul Eggert <address@hidden>
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.
---
configure.ac | 34 ++++++++++++++++------------------
etc/NEWS | 4 ++++
2 files changed, 20 insertions(+), 18 deletions(-)
diff --git a/configure.ac b/configure.ac
index 16d4484..9f8089f 100644
--- a/configure.ac
+++ b/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.]) ;;
diff --git a/etc/NEWS b/etc/NEWS
index f131981..bbcdc0c 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -43,6 +43,10 @@ or by sticking with Emacs 24.4.
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.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 200c2b1: Default to inotify instead of gfile,
Paul Eggert <=