dracut-functions.sh: create $initdir, if it does not exist

This commit is contained in:
Harald Hoyer 2012-06-30 12:46:55 +02:00
parent 1d59e3e592
commit eaa924b69e

View File

@ -28,6 +28,10 @@ if [[ $DRACUT_KERNEL_LAZY ]] && ! [[ $DRACUT_KERNEL_LAZY_HASHDIR ]]; then
DRACUT_KERNEL_LAZY_HASHDIR="$initdir/.kernelmodseen"
fi
if [[ $initdir ]] && ! [[ -d $initdir ]]; then
mkdir -p "$initdir"
fi
# Generic substring function. If $2 is in $1, return 0.
strstr() { [[ $1 = *$2* ]]; }