From f9edaff297648cfd7577ce312cf666085cc1ae99 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Fri, 16 May 2025 19:22:58 +0200 Subject: [PATCH] fs/erofs: unbreak custom compression handling Fixes: https://autobuild.buildroot.net/results/0f856def945b9a863f45f7a58553b62f6875720b/ Commit a02e43741719 ("fs/erofs: add custom compression option with optional compress-hints file") added logic for custom compression, but in fact it did not work. BR2_TARGET_ROOTFS_EROFS_COMPRESSION_{ALGORITHMS,HINTS} are kconfig string variables, so we need to use qstrip rather than strip. Signed-off-by: Peter Korsgaard Signed-off-by: Arnout Vandecappelle (cherry picked from commit 585eeb464018f2c5865b71251df83e10a02cb8b0) Signed-off-by: Thomas Perale --- fs/erofs/erofs.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/erofs/erofs.mk b/fs/erofs/erofs.mk index 6543a364f1..881ecea053 100644 --- a/fs/erofs/erofs.mk +++ b/fs/erofs/erofs.mk @@ -11,9 +11,9 @@ ROOTFS_EROFS_ARGS += -zlz4hc,$(BR2_TARGET_ROOTFS_EROFS_LZ4HC_LEVEL) else ifeq ($(BR2_TARGET_ROOTFS_EROFS_LZMA),y) ROOTFS_EROFS_ARGS += -zlzma,$(BR2_TARGET_ROOTFS_EROFS_LZMA_LEVEL) else ifeq ($(BR2_TARGET_ROOTFS_EROFS_CUSTOM_COMPRESSION),y) -ROOTFS_EROFS_ARGS += -z$(strip $(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_ALGORITHMS)) -ifneq ($(strip $(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_HINTS)),) -ROOTFS_EROFS_ARGS += --compress-hints $(strip $(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_HINTS)) +ROOTFS_EROFS_ARGS += -z$(call qstrip,$(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_ALGORITHMS)) +ifneq ($(call qstrip,$(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_HINTS)),) +ROOTFS_EROFS_ARGS += --compress-hints $(call qstrip,$(BR2_TARGET_ROOTFS_EROFS_COMPRESSION_HINTS)) endif endif