From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.bugs Subject: bug#21241: 25.0.50; gfilenotify doesn't indicate when limits are reached Date: Fri, 14 Aug 2015 18:27:39 -0700 Organization: UCLA Computer Science Department Message-ID: <55CE958B.1000006@cs.ucla.edu> References: <878u9gly4p.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------070602040900090903000506" X-Trace: ger.gmane.org 1439602105 6576 80.91.229.3 (15 Aug 2015 01:28:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 15 Aug 2015 01:28:25 +0000 (UTC) Cc: 21241@debbugs.gnu.org, Tassilo Horn To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Aug 15 03:28:14 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZQQGY-0008KI-NC for geb-bug-gnu-emacs@m.gmane.org; Sat, 15 Aug 2015 03:28:10 +0200 Original-Received: from localhost ([::1]:48813 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZQQGX-0000HM-Rh for geb-bug-gnu-emacs@m.gmane.org; Fri, 14 Aug 2015 21:28:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49836) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZQQGT-0000EC-Jp for bug-gnu-emacs@gnu.org; Fri, 14 Aug 2015 21:28:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZQQGQ-0006UQ-EB for bug-gnu-emacs@gnu.org; Fri, 14 Aug 2015 21:28:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:35706) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZQQGQ-0006UH-Ba for bug-gnu-emacs@gnu.org; Fri, 14 Aug 2015 21:28:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZQQGP-0006Ix-WF for bug-gnu-emacs@gnu.org; Fri, 14 Aug 2015 21:28:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <878u9gly4p.fsf@gnu.org> Resent-From: Paul Eggert Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 15 Aug 2015 01:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 21241 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 21241-submit@debbugs.gnu.org id=B21241.143960206624210 (code B ref 21241); Sat, 15 Aug 2015 01:28:01 +0000 Original-Received: (at 21241) by debbugs.gnu.org; 15 Aug 2015 01:27:46 +0000 Original-Received: from localhost ([127.0.0.1]:56149 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZQQGA-0006IP-26 for submit@debbugs.gnu.org; Fri, 14 Aug 2015 21:27:46 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:34441) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZQQG7-0006IH-J2 for 21241@debbugs.gnu.org; Fri, 14 Aug 2015 21:27:44 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id F40F3160D55; Fri, 14 Aug 2015 18:27:42 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id pIwCc4jSAYqb; Fri, 14 Aug 2015 18:27:40 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 02A98160D56; Fri, 14 Aug 2015 18:27:40 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id uCS5QDe9YMXf; Fri, 14 Aug 2015 18:27:39 -0700 (PDT) Original-Received: from [192.168.1.9] (pool-100-32-155-148.lsanca.fios.verizon.net [100.32.155.148]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id CB27B160D3C; Fri, 14 Aug 2015 18:27:39 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.8.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:105484 Archived-At: This is a multi-part message in MIME format. --------------070602040900090903000506 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Michael Albinus writes: > I would also agree to favor inotify when available. Let's give that a try, then. I installed the attached patch as master commit 200c2b10faf298bf65e8b6dbd0cb9ef00b2f95d6. > On OS X (better: on systems which have defined HAVE_NS), we should > disable gfilenotify, because the Glib main loop won't be used (ns_select > is used rather than xg_select). configure.ac was trying to do that, but there was a typo. Should also be fixed in the attached patch. --------------070602040900090903000506 Content-Type: text/x-diff; name="0001-Default-to-inotify-instead-of-gfile.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-Default-to-inotify-instead-of-gfile.patch" >From 3f9999c2c0b0eb96c7e7e83fd5dd97da4ca301d1 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Fri, 14 Aug 2015 18:20:35 -0700 Subject: [PATCH] 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. -- 2.1.0 --------------070602040900090903000506--