build script: config: Use gzip instead of pigz in fs-compat-check

This commit is contained in:
ColorfulRhino
2024-03-13 20:50:02 +01:00
parent c02b9b90d8
commit 7e07ba179b

View File

@@ -147,7 +147,7 @@ function do_main_configuration() {
if ! modprobe "$ROOTFS_TYPE"; then if ! modprobe "$ROOTFS_TYPE"; then
exit_with_error "Filesystem type unsupported by build host:" "$ROOTFS_TYPE" exit_with_error "Filesystem type unsupported by build host:" "$ROOTFS_TYPE"
else else
display_alert "Sucessfully loaded kernel mopdule for filesystem" "$ROOTFS_TYPE" "" display_alert "Sucessfully loaded kernel module for filesystem" "$ROOTFS_TYPE" ""
fi fi
fi fi
@@ -158,8 +158,13 @@ function do_main_configuration() {
if [ -f "/boot/config-$(uname -r)" ]; then if [ -f "/boot/config-$(uname -r)" ]; then
build_host_kernel_config="/boot/config-$(uname -r)" build_host_kernel_config="/boot/config-$(uname -r)"
elif [ -f "/proc/config.gz" ]; then elif [ -f "/proc/config.gz" ]; then
pigz -dc /proc/config.gz > /tmp/build_host_kernel_config # use pigz since it's a host dependency listed in prepare-host.sh # Try to extract kernel config from /proc/config.gz
build_host_kernel_config="/tmp/build_host_kernel_config" if command -v gzip &> /dev/null; then
gzip -dc /proc/config.gz > /tmp/build_host_kernel_config
build_host_kernel_config="/tmp/build_host_kernel_config"
else
display_alert "Could extract kernel config from build host, please install 'gzip'." "Build might fail in case of missing kernel configs for '${ROOTFS_TYPE}'" "wrn"
fi
else else
display_alert "Could not find kernel config of build host." "Build might fail in case of missing kernel configs for '${ROOTFS_TYPE}'." "wrn" display_alert "Could not find kernel config of build host." "Build might fail in case of missing kernel configs for '${ROOTFS_TYPE}'." "wrn"
fi fi