kbuild: Don't mandate gcc as the host compiler

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: 5f520875bd ("kbuild: Bump the build system to 5.1")
Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
This commit is contained in:
Mark Kettenis
2025-07-12 12:45:58 +02:00
committed by Tom Rini
parent 15d99b3bf5
commit bd0ade7d09

View File

@@ -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