* [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4
@ 2025-09-18 13:01 Tudor Ambarus
2025-09-23 12:29 ` [OE-core] " Quentin Schulz
0 siblings, 1 reply; 4+ messages in thread
From: Tudor Ambarus @ 2025-09-18 13:01 UTC (permalink / raw)
To: richard.purdie, openembedded-core
Cc: peter.griffin, willmcvicker, André Draszik, Tudor Ambarus
The pixel6 kernel build fails with "lz4: command not found"
when KERNEL_IMAGETYPE is set to `Image.lz4`.
Upstream commit 0c7dc5bae1 ("bitbake.conf: Drop lz4 from HOSTTOOLS")
dropped lz4 from the global `HOSTTOOLS` variable. This meant that
the lz4 binary was no longer automatically provided to build tasks,
causing the compilation to fail.
Add a conditional dependency on `lz4-native` directly to
`kernel.bbclass`. It ties the dependency directly to the image type
that requires it, making the build more robust.
Suggested-by: André Draszik <andre.draszik@linaro.org>
Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
---
meta/classes-recipe/kernel.bbclass | 1 +
1 file changed, 1 insertion(+)
diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass
index eb03424dfc3e023842f7b67ef47468210af72cd1..003a155e794388efd3fa29c2c946b18542f4cef8 100644
--- a/meta/classes-recipe/kernel.bbclass
+++ b/meta/classes-recipe/kernel.bbclass
@@ -20,6 +20,7 @@ DEPENDS += "virtual/cross-binutils virtual/cross-cc kmod-native bc-native bison-
DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lzo", "lzop-native", "", d)}"
DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lz4", "lz4-native", "", d)}"
DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.zst", "zstd-native", "", d)}"
+DEPENDS += "${@bb.utils.contains("KERNEL_IMAGETYPES", "Image.lz4", "lz4-native", "", d)}"
PACKAGE_WRITE_DEPS += "depmodwrapper-cross"
do_deploy[depends] += "depmodwrapper-cross:do_populate_sysroot gzip-native:do_populate_sysroot"
---
base-commit: cfbb00657ab961a3c3a8e6619fc08a2a3f4255c7
change-id: 20250918-kernel-lz4-248b9bfff0ed
Best regards,
--
Tudor Ambarus <tudor.ambarus@linaro.org>
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [OE-core] [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4
2025-09-18 13:01 [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4 Tudor Ambarus
@ 2025-09-23 12:29 ` Quentin Schulz
2025-09-23 12:36 ` Tudor Ambarus
0 siblings, 1 reply; 4+ messages in thread
From: Quentin Schulz @ 2025-09-23 12:29 UTC (permalink / raw)
To: tudor.ambarus, richard.purdie, openembedded-core
Cc: peter.griffin, willmcvicker, André Draszik
Hi Tudor,
On 9/18/25 3:01 PM, Tudor Ambarus via lists.openembedded.org wrote:
> [You don't often get email from tudor.ambarus=linaro.org@lists.openembedded.org. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>
> The pixel6 kernel build fails with "lz4: command not found"
> when KERNEL_IMAGETYPE is set to `Image.lz4`.
>
> Upstream commit 0c7dc5bae1 ("bitbake.conf: Drop lz4 from HOSTTOOLS")
> dropped lz4 from the global `HOSTTOOLS` variable. This meant that
> the lz4 binary was no longer automatically provided to build tasks,
> causing the compilation to fail.
>
> Add a conditional dependency on `lz4-native` directly to
> `kernel.bbclass`. It ties the dependency directly to the image type
> that requires it, making the build more robust.
>
> Suggested-by: André Draszik <andre.draszik@linaro.org>
> Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
> ---
> meta/classes-recipe/kernel.bbclass | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass
> index eb03424dfc3e023842f7b67ef47468210af72cd1..003a155e794388efd3fa29c2c946b18542f4cef8 100644
> --- a/meta/classes-recipe/kernel.bbclass
> +++ b/meta/classes-recipe/kernel.bbclass
> @@ -20,6 +20,7 @@ DEPENDS += "virtual/cross-binutils virtual/cross-cc kmod-native bc-native bison-
> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lzo", "lzop-native", "", d)}"
> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lz4", "lz4-native", "", d)}"
> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.zst", "zstd-native", "", d)}"
> +DEPENDS += "${@bb.utils.contains("KERNEL_IMAGETYPES", "Image.lz4", "lz4-native", "", d)}"
There's also gzip, lzo, lzma and xz support for aarch32 per
arch/arm/boot/compressed/Makefile.
Additionally also bz2, zst and fit for Aarch64 per arch/arm64/boot/Makefile.
What about adding those as well so we cover everything?
Cheers,
Quentin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [OE-core] [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4
2025-09-23 12:29 ` [OE-core] " Quentin Schulz
@ 2025-09-23 12:36 ` Tudor Ambarus
2025-09-23 13:06 ` Quentin Schulz
0 siblings, 1 reply; 4+ messages in thread
From: Tudor Ambarus @ 2025-09-23 12:36 UTC (permalink / raw)
To: Quentin Schulz, richard.purdie, openembedded-core
Cc: peter.griffin, willmcvicker, André Draszik
On 9/23/25 1:29 PM, Quentin Schulz wrote:
> Hi Tudor,
Hi!
>
> On 9/18/25 3:01 PM, Tudor Ambarus via lists.openembedded.org wrote:
>> [You don't often get email from tudor.ambarus=linaro.org@lists.openembedded.org. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>>
>> The pixel6 kernel build fails with "lz4: command not found"
>> when KERNEL_IMAGETYPE is set to `Image.lz4`.
>>
>> Upstream commit 0c7dc5bae1 ("bitbake.conf: Drop lz4 from HOSTTOOLS")
>> dropped lz4 from the global `HOSTTOOLS` variable. This meant that
>> the lz4 binary was no longer automatically provided to build tasks,
>> causing the compilation to fail.
>>
>> Add a conditional dependency on `lz4-native` directly to
>> `kernel.bbclass`. It ties the dependency directly to the image type
>> that requires it, making the build more robust.
>>
>> Suggested-by: André Draszik <andre.draszik@linaro.org>
>> Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
>> ---
>> meta/classes-recipe/kernel.bbclass | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass
>> index eb03424dfc3e023842f7b67ef47468210af72cd1..003a155e794388efd3fa29c2c946b18542f4cef8 100644
>> --- a/meta/classes-recipe/kernel.bbclass
>> +++ b/meta/classes-recipe/kernel.bbclass
>> @@ -20,6 +20,7 @@ DEPENDS += "virtual/cross-binutils virtual/cross-cc kmod-native bc-native bison-
>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lzo", "lzop-native", "", d)}"
>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lz4", "lz4-native", "", d)}"
>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.zst", "zstd-native", "", d)}"
>> +DEPENDS += "${@bb.utils.contains("KERNEL_IMAGETYPES", "Image.lz4", "lz4-native", "", d)}"
>
> There's also gzip, lzo, lzma and xz support for aarch32 per arch/arm/boot/compressed/Makefile.
>
> Additionally also bz2, zst and fit for Aarch64 per arch/arm64/boot/Makefile.
>
> What about adding those as well so we cover everything?
>
I guess that would be alright, but maybe in a different patch? This one
adds back something that worked before, but no longer works, the others
are an extension maybe?
Thanks,
ta
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [OE-core] [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4
2025-09-23 12:36 ` Tudor Ambarus
@ 2025-09-23 13:06 ` Quentin Schulz
0 siblings, 0 replies; 4+ messages in thread
From: Quentin Schulz @ 2025-09-23 13:06 UTC (permalink / raw)
To: Tudor Ambarus, richard.purdie, openembedded-core
Cc: peter.griffin, willmcvicker, André Draszik
On 9/23/25 2:36 PM, Tudor Ambarus wrote:
>
>
> On 9/23/25 1:29 PM, Quentin Schulz wrote:
>> Hi Tudor,
>
> Hi!
>
>>
>> On 9/18/25 3:01 PM, Tudor Ambarus via lists.openembedded.org wrote:
>>> [You don't often get email from tudor.ambarus=linaro.org@lists.openembedded.org. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
>>>
>>> The pixel6 kernel build fails with "lz4: command not found"
>>> when KERNEL_IMAGETYPE is set to `Image.lz4`.
>>>
>>> Upstream commit 0c7dc5bae1 ("bitbake.conf: Drop lz4 from HOSTTOOLS")
>>> dropped lz4 from the global `HOSTTOOLS` variable. This meant that
>>> the lz4 binary was no longer automatically provided to build tasks,
>>> causing the compilation to fail.
>>>
>>> Add a conditional dependency on `lz4-native` directly to
>>> `kernel.bbclass`. It ties the dependency directly to the image type
>>> that requires it, making the build more robust.
>>>
>>> Suggested-by: André Draszik <andre.draszik@linaro.org>
>>> Signed-off-by: Tudor Ambarus <tudor.ambarus@linaro.org>
>>> ---
>>> meta/classes-recipe/kernel.bbclass | 1 +
>>> 1 file changed, 1 insertion(+)
>>>
>>> diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass
>>> index eb03424dfc3e023842f7b67ef47468210af72cd1..003a155e794388efd3fa29c2c946b18542f4cef8 100644
>>> --- a/meta/classes-recipe/kernel.bbclass
>>> +++ b/meta/classes-recipe/kernel.bbclass
>>> @@ -20,6 +20,7 @@ DEPENDS += "virtual/cross-binutils virtual/cross-cc kmod-native bc-native bison-
>>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lzo", "lzop-native", "", d)}"
>>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.lz4", "lz4-native", "", d)}"
>>> DEPENDS += "${@bb.utils.contains("INITRAMFS_FSTYPES", "cpio.zst", "zstd-native", "", d)}"
>>> +DEPENDS += "${@bb.utils.contains("KERNEL_IMAGETYPES", "Image.lz4", "lz4-native", "", d)}"
>>
>> There's also gzip, lzo, lzma and xz support for aarch32 per arch/arm/boot/compressed/Makefile.
>>
>> Additionally also bz2, zst and fit for Aarch64 per arch/arm64/boot/Makefile.
>>
>> What about adding those as well so we cover everything?
>>
>
> I guess that would be alright, but maybe in a different patch? This one
> adds back something that worked before, but no longer works, the others
> are an extension maybe?
>
Indeed, I read a bit too fast the commit log :)
In any case, the patch is already merged so it's necessarily in a new
patch :)
Cheers,
Quentin
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-09-23 15:42 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-18 13:01 [PATCH] kernel.bbclass: add lz4-native dependency for Image.lz4 Tudor Ambarus
2025-09-23 12:29 ` [OE-core] " Quentin Schulz
2025-09-23 12:36 ` Tudor Ambarus
2025-09-23 13:06 ` Quentin Schulz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox