aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xscripts/objdiff12
1 files changed, 5 insertions, 7 deletions
diff --git a/scripts/objdiff b/scripts/objdiff
index b3e4f10bfc3e..b8f7fc60563e 100755
--- a/scripts/objdiff
+++ b/scripts/objdiff
@@ -25,17 +25,15 @@
25# 25#
26# Note: 'make mrproper' will also remove .tmp_objdiff 26# Note: 'make mrproper' will also remove .tmp_objdiff
27 27
28GIT_DIR="`git rev-parse --git-dir`" 28SRCTREE=$(git rev-parse --show-toplevel 2>/dev/null)
29 29
30if [ -d "$GIT_DIR" ]; then 30if [ -z "$SRCTREE" ]; then
31 TMPD="${GIT_DIR%git}tmp_objdiff" 31 echo "ERROR: Not a git repository."
32
33 [ -d "$TMPD" ] || mkdir "$TMPD"
34else
35 echo "ERROR: git directory not found."
36 exit 1 32 exit 1
37fi 33fi
38 34
35TMPD=$SRCTREE/.tmp_objdiff
36
39usage() { 37usage() {
40 echo "Usage: $0 <command> <args>" 38 echo "Usage: $0 <command> <args>"
41 echo " record <list of object files>" 39 echo " record <list of object files>"