--- zzzz-none-000/linux-4.4.271/scripts/setlocalversion 2021-06-03 06:22:09.000000000 +0000 +++ dakota-7530ac-750/linux-4.4.271/scripts/setlocalversion 2023-01-11 09:25:44.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 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. @@ -184,7 +183,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