From: Harald Hoyer Date: Thu, 28 Oct 2010 11:35:17 +0000 (+0200) Subject: dracut-functions:inst_symlink() create target dir X-Git-Tag: 008~93 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=11adeb7c011a8f17632847dbef3441136cb422a7;p=thirdparty%2Fdracut.git dracut-functions:inst_symlink() create target dir if the target directory of the symlink didn't exist, we failed --- diff --git a/dracut-functions b/dracut-functions index 8a1f55fc8..7c41fe758 100755 --- a/dracut-functions +++ b/dracut-functions @@ -379,7 +379,8 @@ inst_symlink() { [[ -L $target ]] && return 0 realsrc=$(readlink -f "$src") [[ $realsrc = ${realsrc##*/} ]] && realsrc=${src%/*}/$realsrc - inst "$realsrc" && ln -s "$realsrc" "$target" + inst "$realsrc" && mkdir -p "${target%/*}" && \ + ln -s "$realsrc" "$target" } # find a udev rule in the usual places.