From f2ccab43aa6595ecda563a59852a6ef23fef4261 Mon Sep 17 00:00:00 2001 From: Sandon Van Ness Date: Mon, 13 Oct 2014 10:27:50 -0700 Subject: [PATCH] Use uname string for /version file on rpm kernel gitbuilders. Signed-off-by: Sandon Van Ness --- build-kernel-rpm.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/build-kernel-rpm.sh b/build-kernel-rpm.sh index 337f696..8f654b4 100755 --- a/build-kernel-rpm.sh +++ b/build-kernel-rpm.sh @@ -1,4 +1,4 @@ -1#!/bin/sh -x +#!/bin/sh -x set -e git clean -fdx && git reset --hard @@ -81,13 +81,14 @@ echo "$0: building..." NCPU=$(grep -c processor /proc/cpuinfo) ionice -c3 nice -n20 make LOCALVERSION=-ceph rpm -j$NCPU "$@" || exit 4 +uname_string=$($HOME/rpmbuild/SPECS/kernel.spec | grep -i ^Provides: | grep kernel-[0-9] | awk -F 'kernel-' '{print $2}') OUTDIR="../out/output/sha1/$REV" OUTDIR_TMP="${OUTDIR}.tmp" install -d -m0755 -- "$OUTDIR_TMP" printf '%s\n' "$REV" >"$OUTDIR_TMP/sha1" -printf '%s\n' "$VER" >"$OUTDIR_TMP/version" +printf '%s\n' "$uname_string" >"$OUTDIR_TMP/version" printf '%s\n' "ceph" >"$OUTDIR_TMP/name" -- 2.39.5