On 11/14/24 11:49, Quentin Schulz wrote:
> Hi Jerome,
> 
> On 11/14/24 11:21 AM, Jerome Forissier wrote:
>> When CROSS_COMPILE contains multiple words, HOST_ARCH is not properly
>> detected and the build may fail. It typically happens when using
>> ccache. For example:
>>
>>   $ make qemu_arm64_defconfig
>>   $ make CROSS_COMPILE="ccache aarch64-linux-gnu-"
>>     CC      lib/efi_loader/efi_helper.o
>>   lib/efi_loader/efi_helper.c:26:15: error: operator '==' has no left operand
>>      26 | #if HOST_ARCH == HOST_ARCH_X86_64
>>         |               ^~
>>   [...]
>>
>> Fix the issue by considering only the last word in $(CROSS_COMPILE).
>>
> 
> I suggested another fix here: 
> https://lore.kernel.org/u-boot/[email protected]/

Ah, missed that, sorry.

> We just need one or the other, in in time for v2025.01 :)

Agreed. I would argue my version is a bit more flexible as
it does not assume "ccache", but yours is certainly good enough!

> Tested-by: Quentin Schulz <[email protected]>
> Reviewed-by: Quentin Schulz <[email protected]>
> 
> Thanks!
> Quentin

Thanks,
-- 
Jerome

Reply via email to