From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Don Mullis Newsgroups: gmane.emacs.devel,gmane.linux.kbuild.devel Subject: [PATCH, RFC] etags/ctags v22.0.92 break Linux kernel `make TAGS/tags` Date: Sun, 24 Dec 2006 12:01:31 -0800 Message-ID: <1166990491.2706.205.camel@localhost.localdomain> NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1167019233 19505 80.91.229.10 (25 Dec 2006 04:00:33 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 25 Dec 2006 04:00:33 +0000 (UTC) Cc: kai@germaschewski.name, sam@ravnborg.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 25 05:00:30 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by dough.gmane.org with esmtp (Exim 4.50) id 1Gyh0i-00074j-Gj for ged-emacs-devel@m.gmane.org; Mon, 25 Dec 2006 05:00:24 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gyh0h-0006ED-OM for ged-emacs-devel@m.gmane.org; Sun, 24 Dec 2006 23:00:23 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1GyZXO-0006Uc-IU for emacs-devel@gnu.org; Sun, 24 Dec 2006 15:01:38 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1GyZXM-0006Sq-Jt for emacs-devel@gnu.org; Sun, 24 Dec 2006 15:01:37 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GyZXM-0006SU-7o for emacs-devel@gnu.org; Sun, 24 Dec 2006 15:01:36 -0500 Original-Received: from [209.157.153.23] (helo=outbound0.sv.meer.net) by monty-python.gnu.org with esmtp (Exim 4.52) id 1GyZXL-0004m4-HA for emacs-devel@gnu.org; Sun, 24 Dec 2006 15:01:35 -0500 Original-Received: from mail.meer.net (mail.meer.net [209.157.152.14]) by outbound0.sv.meer.net (8.12.10/8.12.6) with ESMTP id kBOK1Wih056687; Sun, 24 Dec 2006 12:01:32 -0800 (PST) (envelope-from dwm@meer.net) Original-Received: from [192.168.1.1] (covad-dmullis.meer.net [209.157.140.246]) by mail.meer.net (8.13.3/8.13.3/meer) with ESMTP id kBOK1VmS067256; Sun, 24 Dec 2006 12:01:32 -0800 (PST) (envelope-from dwm@meer.net) Original-To: kbuild-devel@lists.sourceforge.net, emacs-devel@gnu.org X-Mailer: Evolution 2.6.3 (2.6.3-1.fc5.5) X-Mailman-Approved-At: Sun, 24 Dec 2006 23:00:14 -0500 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:64238 gmane.linux.kbuild.devel:1310 Archived-At: `make TAGS` produces a TAGS that causes the emacs v22.0.92 command 'M-x tags-search' to repeatedly stop with complaints about missing files. Proximate cause of this is "#line" directives in Linux source files. `make tags` produces hundreds of lines of complaints about duplicate entries. The following ugly patch works around these problems. Posting to both kbuild-devel and emacs-devel in hopes something better can be worked out for the Emacs v22 release. --- Makefile | 12 ++++++++++++ 1 file changed, 12 insertions(+) Index: linux-2.6/Makefile =================================================================== --- linux-2.6.orig/Makefile +++ linux-2.6/Makefile @@ -1337,6 +1337,18 @@ define xtags --langdef=dotconfig \ --language-force=dotconfig \ --regex-dotconfig='/^#?[[:blank:]]*(CONFIG_[[:alnum:]_]+)/\1/'; \ + elif $1 --version 2>&1 | grep -iq 'ctags.* 22\.'; then \ + $(all-sources) | xargs $1 -a -w; \ + $(all-kconfigs) | xargs $1 -a -w \ + --regex='/^[ \t]*config[ \t]+\([a-zA-Z0-9_]+\)/\1/'; \ + $(all-defconfigs) | xargs -r $1 -a -w \ + --regex='/^#?[ \t]?\(CONFIG_[a-zA-Z0-9_]+\)/\1/'; \ + elif $1 --version 2>&1 | grep -iq 'etags.* 22\.'; then \ + $(all-sources) | xargs $1 -a --no-line-directive; \ + $(all-kconfigs) | xargs $1 -a --no-line-directive \ + --regex='/^[ \t]*config[ \t]+\([a-zA-Z0-9_]+\)/\1/'; \ + $(all-defconfigs) | xargs -r $1 -a --no-line-directive \ + --regex='/^#?[ \t]?\(CONFIG_[a-zA-Z0-9_]+\)/\1/'; \ elif $1 --version 2>&1 | grep -iq emacs; then \ $(all-sources) | xargs $1 -a; \ $(all-kconfigs) | xargs $1 -a \