mirror of
https://salsa.debian.org/kernel-team/initramfs-tools.git
synced 2026-01-26 15:39:08 +00:00
Merge branch 'support-missing-kernel-config' into 'master'
Skip compression support check if /boot/config-${version} is missing
See merge request kernel-team/initramfs-tools!104
This commit is contained in:
commit
35711b4412
23
mkinitramfs
23
mkinitramfs
@ -196,15 +196,20 @@ lzop) kconfig_sym=CONFIG_RD_LZO ;;
|
||||
lz4) kconfig_sym=CONFIG_RD_LZ4 ;;
|
||||
zstd) kconfig_sym=CONFIG_RD_ZSTD ;;
|
||||
esac
|
||||
while ! grep -q "^$kconfig_sym=y" "${kconfig}"; do
|
||||
if [ "${compress}" = gzip ]; then
|
||||
echo "E: gzip compression ($kconfig_sym) not supported by kernel" >&2
|
||||
exit 1
|
||||
fi
|
||||
echo "W: ${compress} compression ($kconfig_sym) not supported by kernel, using gzip" >&2
|
||||
compress=gzip
|
||||
kconfig_sym=CONFIG_RD_GZIP
|
||||
done
|
||||
if [ -e "${kconfig}" ]; then
|
||||
while ! grep -q "^$kconfig_sym=y" "${kconfig}"; do
|
||||
if [ "${compress}" = gzip ]; then
|
||||
echo "E: gzip compression ($kconfig_sym) not supported by kernel" >&2
|
||||
exit 1
|
||||
fi
|
||||
echo "W: ${compress} compression ($kconfig_sym) not supported by kernel, using gzip" >&2
|
||||
compress=gzip
|
||||
kconfig_sym=CONFIG_RD_GZIP
|
||||
done
|
||||
else
|
||||
echo "W: Kernel configuration ${kconfig} is missing, ${compress} compression" \
|
||||
"support ($kconfig_sym) cannot be checked and is assumed to be available" >&2
|
||||
fi
|
||||
|
||||
if [ -z "${compresslevel:-}" ]; then
|
||||
compresslevel=${COMPRESSLEVEL:-}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user