80-make-initfs: fix for current make-initrd*

Thanks mithraen@ for spotting, boyarsh@ for explaining,
and legion@ for hearty support :)

The problem would manifest itself like this:

  /.host/script.sh: line 20: /usr/lib64/propagator/initfs: \
  No such file or directory
  mki-scripts: .../stage1/scripts.d/80-make-initfs: unable to run script.
This commit is contained in:
Michael Shigorin 2012-09-24 21:15:08 +04:00
parent 30d0340d56
commit 12a2fc983c

View File

@ -17,7 +17,10 @@ if [ "`rpmvercmp "$MAKE_INITRD_VER" "0.7.8"`" != "-1" ]; then
fi
if make-initrd $MAKE_INITRD_OPTS; then
gzip < /boot/initrd-$kver.img > $(getconf LIBDIR)/propagator/initfs
pdir="$(getconf LIBDIR)/propagator/initfs"
if [ -d "$pdir" ]; then # p5/t6
gzip < /boot/initrd-$kver.img > "$pdir"/initfs
fi
else
exit 1
fi