From 47dacac490705bbdc759aa6627d1f3cf1da15a8b Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Wed, 24 Feb 2016 13:40:26 +0100 Subject: Define KVER and KGEN at the proper location in the script. --- make_slackware_live.sh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'make_slackware_live.sh') diff --git a/make_slackware_live.sh b/make_slackware_live.sh index 9d94e76..3d60085 100755 --- a/make_slackware_live.sh +++ b/make_slackware_live.sh @@ -813,6 +813,10 @@ echo "-- Configuring the base system." umount ${LIVE_ROOTDIR} 2>${DBGOUT} || true mount -t overlay -o lowerdir=${RODIRS},upperdir=${INSTDIR},workdir=${LIVE_OVLDIR} overlay ${LIVE_ROOTDIR} +# Determine the kernel version in the Live OS: +KGEN=$(echo ${LIVE_ROOTDIR}/var/log/packages/kernel*modules* |head -1 |rev | cut -d- -f3 |rev) +KVER=$(ls --indicator-style=none ${LIVE_ROOTDIR}/lib/modules/ |head -1) + # Configure hostname and network: echo "${LIVE_HOSTNAME}.example.net" > ${LIVE_ROOTDIR}/etc/HOSTNAME if [ -f ${LIVE_ROOTDIR}/etc/NetworkManager/NetworkManager.conf ]; then -- cgit v1.2.3