[Lunar-commits] <moonbase> openafs-driver: Quick fix to determine kernel module install dir

Stefan Wold ratler at lunar-linux.org
Mon Aug 2 13:30:37 CEST 2010


commit b2c1ffd9555dfbf9cd0a28228df59a54ceee35fb
Author: Stefan Wold <ratler at lunar-linux.org>
Date:   Mon Aug 2 13:30:37 2010 +0200

    openafs-driver: Quick fix to determine kernel module install dir
---
 kernel/openafs-driver/POST_INSTALL |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diff --git a/kernel/openafs-driver/POST_INSTALL b/kernel/openafs-driver/POST_INSTALL
index 46d48a6..3815603 100644
--- a/kernel/openafs-driver/POST_INSTALL
+++ b/kernel/openafs-driver/POST_INSTALL
@@ -23,13 +23,9 @@ case `arch` in
     ;;
 esac
 
-KVER=$(if [ -f /usr/src/linux/include/linux/utsrelease.h ] ; then
-  grep UTS_RELEASE /usr/src/linux/include/linux/utsrelease.h | cut -d'"' -f2
-else
-  grep UTS_RELEASE /usr/src/linux/include/linux/version.h | cut -d'"' -f2
-fi)
 
 MODDIR=$(expr $SOURCE_DIRECTORY/src/libafs/MODLOAD-*)
+KVER=$(echo ${MODDIR##*/} | awk -F- '{ print $2 }')
 
 if [ "$kv" == "26" ]; then
   [ -f ${MODDIR}/libafs.ko ] || exit -1


More information about the Lunar-commits mailing list