From: Jike Song <albcamus@gmail.com>
To: sam@ravnborg.org
Cc: linux-kbuild@vger.kernel.org, Jike Song <albcamus@gmail.com>
Subject: [PATCH] Kbuild: reintroduce ALLSOURCE_ARCHS support for tags/cscope.
Date: Wed, 31 Dec 2008 21:37:36 +0800 [thread overview]
Message-ID: <1230730656-2987-1-git-send-email-albcamus@gmail.com> (raw)
This patch reintroduce the ALLSOURCE_ARCHS support for tags/TAGS/
cscope targets. The Kbuild previously has this feature, but after
moving the targets into scripts/tags.sh, ALLSOURCE_ARCHS disappears.
It's something like this:
$ make ALLSOURCE_ARCHS="x86 mips arm" tags cscope
Signed-off-by: Jike Song <albcamus@gmail.com>
---
scripts/tags.sh | 18 +++++++++++++-----
1 files changed, 13 insertions(+), 5 deletions(-)
diff --git a/scripts/tags.sh b/scripts/tags.sh
index 4e75472..9c954d9 100755
--- a/scripts/tags.sh
+++ b/scripts/tags.sh
@@ -24,6 +24,11 @@ else
tree=${srctree}/
fi
+# Detect if ALLSOURCE_ARCHS is set. If not, we asssume SRCARCH
+if [ "${ALLSOURCE_ARCHS}" = "" ]; then
+ ALLSOURCE_ARCHS=${SRCARCH}
+fi
+
# find sources in arch/$ARCH
find_arch_sources()
{
@@ -54,26 +59,29 @@ find_other_sources()
find_sources()
{
find_arch_sources $1 "$2"
- find_include_sources "$2"
- find_other_sources "$2"
}
all_sources()
{
- find_sources $SRCARCH '*.[chS]'
+ for arch in $ALLSOURCE_ARCHS
+ do
+ find_sources $arch '*.[chS]'
+ done
if [ ! -z "$archinclude" ]; then
find_arch_include_sources $archinclude '*.[chS]'
fi
+ find_include_sources '*.[chS]'
+ find_other_sources '*.[chS]'
}
all_kconfigs()
{
- find_sources $SRCARCH 'Kconfig*'
+ find_sources $ALLSOURCE_ARCHS 'Kconfig*'
}
all_defconfigs()
{
- find_sources $SRCARCH "defconfig"
+ find_sources $ALLSOURCE_ARCHS "defconfig"
}
docscope()
--
1.6.0.2.GIT
next reply other threads:[~2008-12-31 13:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-31 13:37 Jike Song [this message]
2009-01-02 22:32 ` [PATCH] Kbuild: reintroduce ALLSOURCE_ARCHS support for tags/cscope Sam Ravnborg
2009-01-03 14:05 ` Jike Song
2009-01-02 22:34 ` Sam Ravnborg
2009-01-03 14:10 ` Jike Song
2009-01-03 20:20 ` Sam Ravnborg
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=1230730656-2987-1-git-send-email-albcamus@gmail.com \
--to=albcamus@gmail.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=sam@ravnborg.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