@@ -81,7 +81,7 @@ command results in a shift count error.'
else
ONLINE=0
if [ "$KBUILD_EXTMOD" = "" ] ; then
- OPTIONS="--dir $srctree $COCCIINCLUDE"
+ OPTIONS="--dir ${srctree}. $COCCIINCLUDE"
else
OPTIONS="--dir $KBUILD_EXTMOD $COCCIINCLUDE"
fi
@@ -210,7 +210,7 @@ coccinelle () {
if [ $VERBOSE -ne 0 -a $ONLINE -eq 0 ] ; then
- FILE=${COCCI#${srctree%/}/}
+ FILE=${COCCI#$srctree}
echo "Processing `basename $COCCI`"
echo "with option(s) \"$OPT\""
@@ -273,7 +273,7 @@ else
fi
if [ "$COCCI" = "" ] ; then
- for f in `find $srctree/scripts/coccinelle/ -name '*.cocci' -type f | sort`; do
+ for f in `find ${srctree}scripts/coccinelle/ -name '*.cocci' -type f | sort`; do
coccinelle $f
done
else
With the modifcation now done, remove compatibility with ${srctree} not having the trailing slash. Signed-off-by: Elliott Mitchell <ehem+linux@m5p.com> --- --- scripts/coccicheck | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)