|
|
|
@ -29,7 +29,7 @@ KERNEL_DIR=${DEFAULT_KERNEL_DIRECTORY}
|
|
|
|
|
CREATE_BASE=1
|
|
|
|
|
# create config by template
|
|
|
|
|
CREATE_NEW=1
|
|
|
|
|
BUILD_KERNEL=
|
|
|
|
|
BUILD_KERNEL=1
|
|
|
|
|
|
|
|
|
|
: >$DEBUG_LOG
|
|
|
|
|
set -e
|
|
|
|
@ -257,6 +257,11 @@ do
|
|
|
|
|
check_kernel_sources ${check_dir} || eerror "Kernel directory ${check_dir} has not full sources"
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
if [[ -z $KVER ]]
|
|
|
|
|
then
|
|
|
|
|
KVER=$(basename "$(readlink $KERNEL_DIR)" | sed 's/linux-//')
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
if ! [[ -d $LOCAL_TEMPLATES_DIR ]]
|
|
|
|
|
then
|
|
|
|
|
(mkdir -p $LOCAL_TEMPLATES_DIR ;
|
|
|
|
@ -348,7 +353,16 @@ rm -f $BASE_CONFIG
|
|
|
|
|
|
|
|
|
|
if [[ -n ${BUILD_KERNEL} ]]
|
|
|
|
|
then
|
|
|
|
|
einfo $KVER
|
|
|
|
|
cd $KERNEL_DIR
|
|
|
|
|
einfo "make && make modules && make install && make modules_install"
|
|
|
|
|
grep -q "CONFIG_BLK_DEV_INITRD=y" ${NEW_CONFIG} && einfo "dracut -fH --kver $KVER /boot/initramfs-${KVER}.img"
|
|
|
|
|
if [[ $KVER =~ calculate ]]
|
|
|
|
|
then
|
|
|
|
|
|
|
|
|
|
grep -q "CONFIG_BLK_DEV_INITRD=y" ${NEW_CONFIG} && einfo "dracut -f --kver $KVER /boot/initramfs-${KVER/-calculate/-SafeMode-calculate}.img"
|
|
|
|
|
fi
|
|
|
|
|
einfo "cl-setup-boot"
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
einfo "All done!"
|
|
|
|
|