[PATCH] kbuild: Don't mandate gcc as the host compiler
Mark Kettenis
mark.kettenis at xs4all.nl
Sat Jul 12 20:54:52 CEST 2025
> From: Mark Kettenis <kettenis at openbsd.org>
> Date: Sat, 12 Jul 2025 12:45:58 +0200
>
> Systems that use clang may not have gcc installed. Set
> HOSTCC to cc and HOSTCXX to c++ like we did before to make those
> systems work again.
>
> Fixes: 5f520875bdf0 ("kbuild: Bump the build system to 5.1")
Just realized I forgot my Signed-of-by tag. So:
Signed-off-by: Mark Kettenis <kettenis at openbsd.org>
Or should I resend the patch with that included?
> ---
> Makefile | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index e8f12716640..121ebd5c353 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -416,8 +416,8 @@ HOST_LFS_CFLAGS := $(shell getconf LFS_CFLAGS 2>/dev/null)
> HOST_LFS_LDFLAGS := $(shell getconf LFS_LDFLAGS 2>/dev/null)
> HOST_LFS_LIBS := $(shell getconf LFS_LIBS 2>/dev/null)
>
> -HOSTCC = gcc
> -HOSTCXX = g++
> +HOSTCC = cc
> +HOSTCXX = c++
> KBUILD_HOSTCFLAGS := -Wall -Wstrict-prototypes -O2 \
> -fomit-frame-pointer -std=gnu11 $(HOST_LFS_CFLAGS) \
> $(HOSTCFLAGS) #-Wmissing-prototypes Enable it and fix warnings
> --
> 2.49.0
>
>
More information about the U-Boot
mailing list