make-initrd: fix #132059

This commit is contained in:
Linus Heckemann 2021-08-02 23:11:25 +02:00
parent 439b160522
commit b0fc6e8ff9
2 changed files with 3 additions and 3 deletions

View File

@ -78,7 +78,7 @@ let
in stdenvNoCC.mkDerivation rec {
inherit name makeUInitrd extension uInitrdArch prepend;
${if makeUInitrd then "uinitrdCompression" else null} = uInitrdCompression;
${if makeUInitrd then "uInitrdCompression" else null} = uInitrdCompression;
builder = ./make-initrd.sh;

View File

@ -43,9 +43,9 @@ done
(cd root && find * .[^.*] -print0 | sort -z | cpio -o -H newc -R +0:+0 --reproducible --null | eval -- $compress >> "$out/initrd")
if [ -n "$makeUInitrd" ]; then
mkimage -A $uInitrdArch -O linux -T ramdisk -C "$uInitrdCompression" -d $out/initrd"$extension" $out/initrd.img
mkimage -A "$uInitrdArch" -O linux -T ramdisk -C "$uInitrdCompression" -d "$out/initrd" $out/initrd.img
# Compatibility symlink
ln -s "initrd.img" "$out/initrd"
ln -sf "initrd.img" "$out/initrd"
else
ln -s "initrd" "$out/initrd$extension"
fi