From: mmarek <mmarek@suse.cz>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Stephen Boyd <sboyd@codeaurora.org>,
Andrew Morton <akpm@linux-foundation.org>,
Geert Uytterhoeven <geert@linux-m68k.org>,
LKML <linux-kernel@vger.kernel.org>,
linux-kbuild <linux-kbuild@vger.kernel.org>,
Yang Bai <hamo.by@gmail.com>
Subject: Re: [PATCH] scripts: Have make TAGS not include structure members
Date: Fri, 3 Jan 2014 14:24:32 +0100 [thread overview]
Message-ID: <20140103132432.GA32469@sepie.suse.cz> (raw)
In-Reply-To: <20131119193414.48912cbd@gandalf.local.home>
On Tue, Nov 19, 2013 at 07:34:14PM -0500, Steven Rostedt wrote:
> I wasn't going to use this change, but instead add this change:
[...]
> --- linux-trace.git.orig/scripts/tags.sh 2013-11-19 19:29:34.352371615 -0500
> +++ linux-trace.git/scripts/tags.sh 2013-11-19 19:32:37.821152204 -0500
> @@ -218,7 +218,7 @@ exuberant()
>
> emacs()
> {
> - all_target_sources | xargs $1 -a \
> + all_target_sources | xargs $@ -a \
> --regex='/^\(ENTRY\|_GLOBAL\)(\([^)]*\)).*/\2/' \
> --regex='/^SYSCALL_DEFINE[0-9]?(\([^,)]*\).*/sys_\1/' \
> --regex='/^TRACE_EVENT(\([^,)]*\).*/trace_\1/' \
> @@ -263,7 +263,7 @@ xtags()
> if $1 --version 2>&1 | grep -iq exuberant; then
> exuberant $1
> elif $1 --version 2>&1 | grep -iq emacs; then
> - emacs $1
> + emacs $@
> else
> all_target_sources | xargs $1 -a
> fi
> @@ -313,7 +313,7 @@ case "$1" in
>
> "TAGS")
> rm -f TAGS
> - xtags etags
> + xtags etags --no-members
> remove_structs=y
The logic looks OK, but it is not completely obvious that $@ means
'etags --no-members, iff called as etags'. How about using a more
descriptive variable like this?
diff --git a/scripts/tags.sh b/scripts/tags.sh
index 58c4559..3afc479 100755
--- a/scripts/tags.sh
+++ b/scripts/tags.sh
@@ -219,7 +219,7 @@ exuberant()
emacs()
{
- all_target_sources | xargs $1 -a \
+ all_target_sources | xargs $1 $no_members -a \
--regex='/^\(ENTRY\|_GLOBAL\)(\([^)]*\)).*/\2/' \
--regex='/^SYSCALL_DEFINE[0-9]?(\([^,)]*\).*/sys_\1/' \
--regex='/^TRACE_EVENT(\([^,)]*\).*/trace_\1/' \
@@ -308,12 +308,15 @@ case "$1" in
"tags")
rm -f tags
+ no_members=
xtags ctags
remove_structs=y
;;
"TAGS")
rm -f TAGS
+ # Do not index struct members when generating Emacs TAGS
+ no_members=--no-members
xtags etags
remove_structs=y
;;
Michal
next prev parent reply other threads:[~2014-01-03 13:37 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-15 14:36 [PATCH] scripts: Have make TAGS not include structure members Steven Rostedt
2013-11-16 1:02 ` Stephen Boyd
2013-11-16 1:20 ` Steven Rostedt
2013-11-17 9:14 ` Geert Uytterhoeven
2013-11-17 14:27 ` Steven Rostedt
2013-11-17 15:19 ` Geert Uytterhoeven
2013-11-17 17:08 ` Steven Rostedt
2013-11-20 8:29 ` Geert Uytterhoeven
2013-11-19 23:59 ` Andrew Morton
2013-11-20 0:04 ` Steven Rostedt
2013-11-20 0:08 ` Andrew Morton
2013-11-20 0:14 ` Steven Rostedt
2013-11-20 0:18 ` Stephen Boyd
2013-11-20 0:34 ` Steven Rostedt
2014-01-03 13:24 ` mmarek [this message]
2014-01-06 19:32 ` Steven Rostedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140103132432.GA32469@sepie.suse.cz \
--to=mmarek@suse.cz \
--cc=akpm@linux-foundation.org \
--cc=geert@linux-m68k.org \
--cc=hamo.by@gmail.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=sboyd@codeaurora.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox