From f909800b048d36bf65b5f257f3d342d2153be5c2 Mon Sep 17 00:00:00 2001 From: Kairui Song Date: Sun, 15 Jan 2023 19:07:45 +0800 Subject: [PATCH] dist: fix for KDIST override Upstream: no Kernel's uname is still using old KDIST even when KDIST= is specified, fix that. Signed-off-by: Kairui Song --- dist/scripts/lib-version.sh | 2 +- dist/scripts/lib.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/scripts/lib-version.sh b/dist/scripts/lib-version.sh index 51c300b36..c13947a97 100755 --- a/dist/scripts/lib-version.sh +++ b/dist/scripts/lib-version.sh @@ -635,7 +635,7 @@ prepare_kernel_ver() { KERNEL_NAME="kernel${KDIST:+-$KDIST}" KERNEL_MAJVER="$KVERSION.$KPATCHLEVEL.$KSUBLEVEL" KERNEL_RELVER="$krelease" - KERNEL_UNAMER="$KERNEL_MAJVER-$KERNEL_RELVER${KERNEL_DIST:+.$KERNEL_DIST}" + KERNEL_UNAMER="$KERNEL_MAJVER-$KERNEL_RELVER${KDIST:+.$KDIST}" if [[ $KFORCEUNAMER ]] && [[ $KGIT_TAG_RELEASE_INFO_RAW ]]; then KERNEL_UNAMER="$KERNEL_MAJVER$KGIT_TAG_RELEASE_INFO_RAW" diff --git a/dist/scripts/lib.sh b/dist/scripts/lib.sh index f9af8f494..f2afc007d 100755 --- a/dist/scripts/lib.sh +++ b/dist/scripts/lib.sh @@ -96,7 +96,7 @@ get_dist_makefile_var() { local _repo=${3:-$TOPDIR} local _val - _val=$(cat_repo_file "dist/Makefile" | sed -nE -e "$_sedexp") + _val=$(cat_repo_file "dist/Makefile" "$_gitref" "$_repo" | sed -nE -e "$_sedexp") case $_val in *\$* ) die "Can't parse Makefile variable '$1', it references to other variables."