generate 512-byte padded xz files

This commit is contained in:
Trammell hudson 2017-09-22 15:09:57 -04:00
parent 91ef9aeefa
commit 03d21da268
Failed to extract signature

View File

@ -358,17 +358,21 @@ initrd.intermediate: initrd.cpio
#
# Compress the initrd into a xz file that can be included by coreboot.
# The extra options are necessary to let the Linux kernel decompress it.
# The extra options are necessary to let the Linux kernel decompress it
# and the extra padding is to ensure that it can be concatenated to
# other cpio files.
#
coreboot.intermediate: $(build)/$(coreboot_dir)/initrd.cpio.xz
$(build)/$(coreboot_dir)/initrd.cpio.xz: initrd.cpio
%.xz: %
$(call do,COMPRESS,$<,\
xz \
--check=crc32 \
--lzma2=dict=1MiB \
-9 \
< "$<" \
> "$@" \
| dd bs=512 conv=sync > "$@" \
)
@sha256sum "$@"