New commits:
commit c96f8ed433e16783c099afef15d69d0235233cc2
Author: Daniel Goller <morfic AT sourcemage.org>
Commit: Daniel Goller <morfic AT sourcemage.org>
grimoire/FUNCTIONS: add part to ifelseheimer to get version from
/usr/src/linux/.config
so we can go and compile all modules for the new kernel before we
reboot
and are this way not stuck w/o network/* and who does not setup
/usr/src/linux is
stuck with uname -r as before
diff --git a/FUNCTIONS b/FUNCTIONS
index 37ef827..f528ab1 100755
--- a/FUNCTIONS
+++ b/FUNCTIONS
@@ -295,8 +295,13 @@ function get_kernel_version()
if [[ $KVER ]] ; then
echo $KVER
else
- KVER=$(uname -r)
- echo $KVER
+ KVER=$(grep version /usr/src/linux/.config | cut -d:
-f2 | cut -d ' ' -f2)
+ if [ $KVER ] && [ -d "/lib/modules/${KVER}/build" ] ;
then
+ echo $KVER
+ else
+ KVER=$(uname -r)
+ echo $KVER
+ fi
fi
fi
}
[SM-Commit] GIT changes to master grimoire by Daniel Goller (c96f8ed433e16783c099afef15d69d0235233cc2),
Daniel Goller, 10/04/2006