Hello Florian On 20.05.21 09:41, Florian Eckert wrote: > What is your opinion on this or how can we solve this in another way? > Or do you not have this problem? > liblzma detection is automatic - so this seems to be some hidden error before / build environment related
disabling it is possible according to configure.ac "LZMA" (liblzma -> USE_LIBLZMA, lzma.h) is used in grub util/mkimage.c looking at grub code - lzma.h/liblzma from xz means "GRUB_COMPRESSION_XZ" / compress_kernel_xz disabling it then prints "Without liblzma (no support for XZ-compressed mips images) (explicitly disabled)" - afaik we do not support grub on MIPS; but --compress=xz is also disabled by that so many cmdline defaults might not be working : (util/grub-mkimage.c) Notice that grub contains an grub-core/lib/xzembed/xz.h for some other XZ functionality (grub-core/fs/squash4.c: COMPRESSION_XZ = 4) Attached the simple patch that is build-tested with: CONFIG_TARGET_x86=y CONFIG_TARGET_x86_generic=y CONFIG_TARGET_x86_generic_DEVICE_generic=y CONFIG_DEVEL=y CONFIG_BUILD_LOG=y CONFIG_EXPERIMENTAL=y # CONFIG_FEED_luci is not set # CONFIG_FEED_packages is not set # CONFIG_FEED_routing is not set # CONFIG_FEED_telephony is not set CONFIG_LINUX_5_10=y CONFIG_PACKAGE_grub2-editenv=y CONFIG_PACKAGE_kmod-mdio-devres=y CONFIG_PACKAGE_liblzma=y CONFIG_TESTING_KERNEL=y no lzma error , lzma linkage seems fine : checked compile.log for the disable msg + @build path the config.log Feel free to add / modify etc sry for strange formatting - thunderbird update currently messes with text-only settings that worked fine before > > Best regards > > Florian > > > [1] > https://git.openwrt.org/?p=openwrt/openwrt.git;a=commit;h=e74d81ece2e2932a4f370d8e6d180061a6a2c229 > [2] https://github.com/openwrt/packages/tree/master/utils/xz Greetings, Dirk
>From aef9acf31244eff9ec7eac29e1fc9da16d4cf1fe Mon Sep 17 00:00:00 2001 From: Dirk Neukirchen <[email protected]> Date: Thu, 20 May 2021 10:39:35 +0200 Subject: [PATCH] [RFC] grub2: disable liblzma dependency LZMA is used in mkimage.c disabling it prints Without liblzma (no support for XZ-compressed mips images) (explicitly disabled) (see configure.ac) liblzma is autodetected so this issue was present but hidden somehow [unsure: grep/image generation does not use grub with that option] OpenWrt does not use that feature currently [!] some scripts and examples use --compression=xz or -C xz and those will break grub has an internal xzlib for different "lzma" functionality (ext. LIBLZMA from XZ (GRUB_COMPRESSION_XZ) vs. GRUB_COMPRESSION_LZMA) Signed-off-by: Dirk Neukirchen <[email protected]> --- package/boot/grub2/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/package/boot/grub2/Makefile b/package/boot/grub2/Makefile index b3cb5e076f..8bb2d419d9 100644 --- a/package/boot/grub2/Makefile +++ b/package/boot/grub2/Makefile @@ -65,6 +65,7 @@ CONFIGURE_ARGS += \ --disable-nls \ --disable-device-mapper \ --disable-libzfs \ + --disable-liblzma \ --disable-grub-mkfont \ --with-platform=$(BUILD_VARIANT) -- 2.31.1
_______________________________________________ openwrt-devel mailing list [email protected] https://lists.openwrt.org/mailman/listinfo/openwrt-devel
