summaryrefslogtreecommitdiff
path: root/util/lint
diff options
context:
space:
mode:
Diffstat (limited to 'util/lint')
-rwxr-xr-xutil/lint/lint-stable-002-build-dir-handling17
1 files changed, 11 insertions, 6 deletions
diff --git a/util/lint/lint-stable-002-build-dir-handling b/util/lint/lint-stable-002-build-dir-handling
index c4247b54fb..d5295d276e 100755
--- a/util/lint/lint-stable-002-build-dir-handling
+++ b/util/lint/lint-stable-002-build-dir-handling
@@ -20,7 +20,7 @@
# $1: command to test for GNU make
search_make() {
-if [ -n "`$1 --version 2>&1 |grep GNU`" ]; then MAKE=$1; fi
+if [ -n "`$1 --version 2>&1 | grep GNU`" ]; then MAKE=$1; fi
}
# if $1 and $2 differ, exit with failure
@@ -33,7 +33,12 @@ fi
# $1: object directory
run_printall() {
-$MAKE CONFIG_USE_BLOBS=n CONFIG_CCACHE=n CONFIG_SCANBUILD_ENABLE=n NOMKDIR=1 DOTCONFIG=$TMPCONFIG obj=$1 printall |sed -e "s,^ *,," -e "s,^ramstage-objs:=,," -e "s,mainboard/[^/]*/[^/]*/,.../," |tr " " "\n"|grep "/static.*\.[co]" |sort |tr '\012\015' ' ' |sed -e "s, *, ,g" -e "s, *$,,"
+$MAKE CONFIG_USE_BLOBS=n CONFIG_CCACHE=n CONFIG_SCANBUILD_ENABLE=n NOMKDIR=1 \
+ DOTCONFIG=$TMPCONFIG obj=$1 printall | \
+ sed -e "s,^ *,," -e "s,^r.mstage-objs:=,," \
+ -e "s,mainboard/[^/]*/[^/]*/,.../,g" | \
+ tr " " "\n" | grep "/static.*\.[co]" | sort | \
+ tr '\012\015' ' ' | sed -e "s, *, ,g" -e "s, *$,,"
}
# find GNU make
@@ -54,10 +59,10 @@ $MAKE DOTCONFIG=$TMPCONFIG allyesconfig >/dev/null
# look up parent directory
PARENTDIR=`dirname $PWD`
-compare_output "`run_printall build`" "build/.../static.c build/.../static.ramstage.o"
-compare_output "`run_printall ../obj`" "$PARENTDIR/obj/.../static.c $PARENTDIR/obj/.../static.ramstage.o"
-compare_output "`run_printall /tmp`" "/tmp/.../static.c /tmp/.../static.ramstage.o"
-compare_output "`run_printall /../tmp`" "/tmp/.../static.c /tmp/.../static.ramstage.o"
+compare_output "`run_printall build`" "build/.../static.c build/.../static.c build/.../static.ramstage.o build/.../static.romstage.o"
+compare_output "`run_printall ../obj`" "$PARENTDIR/obj/.../static.c $PARENTDIR/obj/.../static.c $PARENTDIR/obj/.../static.ramstage.o $PARENTDIR/obj/.../static.romstage.o"
+compare_output "`run_printall /tmp`" "/tmp/.../static.c /tmp/.../static.c /tmp/.../static.ramstage.o /tmp/.../static.romstage.o"
+compare_output "`run_printall /../tmp`" "/tmp/.../static.c /tmp/.../static.c /tmp/.../static.ramstage.o /tmp/.../static.romstage.o"
rm -f $TMPCONFIG