summaryrefslogtreecommitdiffstats
path: root/install_kernel.jupiter-cs
diff options
context:
space:
mode:
authorBjoern B. Brandenburg <bbb@cs.unc.edu>2010-11-01 15:59:53 -0400
committerBjoern B. Brandenburg <bbb@cs.unc.edu>2010-11-01 15:59:53 -0400
commitac8a3c832addc68ee4ad01337a17f63bdb4138ab (patch)
treeb9ccb584dcb48b57b1cf21ffc32bbf4cf125d5be /install_kernel.jupiter-cs
parent0863fa86da554b29f7ff0b24b8c0ec09ed024792 (diff)
use the version file created by the kernel build system
This might also be interesting for other machines.
Diffstat (limited to 'install_kernel.jupiter-cs')
-rwxr-xr-xinstall_kernel.jupiter-cs19
1 files changed, 5 insertions, 14 deletions
diff --git a/install_kernel.jupiter-cs b/install_kernel.jupiter-cs
index 720fb9c..37d25ea 100755
--- a/install_kernel.jupiter-cs
+++ b/install_kernel.jupiter-cs
@@ -20,13 +20,6 @@ function silent()
20 fi 20 fi
21} 21}
22 22
23# Function to grab var from src
24function getvar() {
25 old=$(head -5 Makefile | grep "^$1")
26 echo $(echo ${old/"$1 ="/} | sed -e "s/[ ]*\(.*\)[ ]*/\1/g")
27 return 0
28}
29
30if [ ! -f "./.config" ]; then 23if [ ! -f "./.config" ]; then
31 CURDIR=`pwd` 24 CURDIR=`pwd`
32 die "No kernel .config exists in $CURDIR!" 25 die "No kernel .config exists in $CURDIR!"
@@ -36,14 +29,12 @@ if [ ! -f "./Makefile" ]; then
36 die "No Makefile present!" 29 die "No Makefile present!"
37fi 30fi
38 31
39VERSION=`getvar VERSION` 32NAME=`cat include/config/kernel.release`
40PATCHLEVEL=`getvar PATCHLEVEL`
41SUBLEVEL=`getvar SUBLEVEL`
42EXTRAVERSION=`getvar EXTRAVERSION`
43 33
44. ./.config 34if [ -z "$NAME" ]
45 35then
46NAME="$VERSION.$PATCHLEVEL.$SUBLEVEL$EXTRAVERSION$CONFIG_LOCALVERSION" 36 die "Could not determine kernel version!"
37fi
47 38
48info "Detected kernel version $NAME" 39info "Detected kernel version $NAME"
49 40