Skip to content

Commit

Permalink
scripts/tags.sh: Support subarch for ARM
Browse files Browse the repository at this point in the history
Current tags.sh doesn't handle subarch for ARM.
There are too many subarch on ARM, it is hard that we locate some
functions which are defined in every subarch with tags util family.
Therefore support subarch for removing this unconvenience.

We can use ARM subarch functionality like below.
"make cscope O=. SRCARCH=arm SUBARCH=xxx"

Signed-off-by: Joonsoo Kim <js1304@gmail.com>
Signed-off-by: Michal Marek <mmarek@suse.cz>
  • Loading branch information
Joonsoo Kim authored and Michal Marek committed Dec 11, 2012
1 parent ad99ac2 commit 5965850
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions scripts/tags.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,14 @@ find_arch_sources()
for i in $archincludedir; do
prune="$prune -wholename $i -prune -o"
done
find ${tree}arch/$1 $ignore $prune -name "$2" -print;
find ${tree}arch/$1 $ignore $subarchprune $prune -name "$2" -print;
}

# find sources in arch/$1/include
find_arch_include_sources()
{
include=$(find ${tree}arch/$1/ -name include -type d);
include=$(find ${tree}arch/$1/ $subarchprune \
-name include -type d -print);
if [ -n "$include" ]; then
archincludedir="$archincludedir $include"
find $include $ignore -name "$2" -print;
Expand Down Expand Up @@ -234,6 +235,21 @@ if [ "${ARCH}" = "um" ]; then
else
archinclude=${SUBARCH}
fi
elif [ "${SRCARCH}" = "arm" -a "${SUBARCH}" != "" ]; then
subarchdir=$(find ${tree}arch/$SRCARCH/ -name "mach-*" -type d -o \
-name "plat-*" -type d);
for i in $subarchdir; do
case "$i" in
*"mach-"${SUBARCH})
;;
*"plat-"${SUBARCH})
;;
*)
subarchprune="$subarchprune \
-wholename $i -prune -o"
;;
esac
done
fi

remove_structs=
Expand Down

0 comments on commit 5965850

Please sign in to comment.