--- zzzz-none-000/linux-4.4.60/scripts/setlocalversion 2017-04-08 07:53:53.000000000 +0000 +++ scorpion-7490-727/linux-4.4.60/scripts/setlocalversion 2021-02-04 17:41:59.000000000 +0000 @@ -43,8 +43,7 @@ fi # Check for git and a git repo. - if test -z "$(git rev-parse --show-cdup 2>/dev/null)" && - head=`git rev-parse --verify --short HEAD 2>/dev/null`; then + if test -d .git && head=`git rev-parse --verify --short HEAD 2>/dev/null`; then # If we are at a tagged commit (like "v2.6.30-rc6"), we ignore # it, because this version is defined in the top level Makefile. @@ -165,7 +164,7 @@ # annotated or signed tagged state (as git describe only # looks at signed or annotated tags - git tag -a/-s) and # LOCALVERSION= is not specified - if test "${LOCALVERSION+set}" != "set"; then + if test "${CONFIG_LOCALVERSION+set}" != "set"; then scm=$(scm_version --short) res="$res${scm:++}" fi