blob: 41936c9fe3a4ffa58b4830a071017ef1b84e2ca8 [file] [log] [blame]
Andrew Geisslerac970dd2021-02-12 15:32:45 -06001--- a/scripts/Kbuild.klibc
2+++ b/scripts/Kbuild.klibc
3@@ -113,10 +113,8 @@ KLIBCCPPFLAGS := -nostdinc -iwithpref
4 -I$(KLIBCINC)/arch/$(KLIBCARCHDIR) \
5 -I$(KLIBCINC)/bits$(KLIBCBITSIZE) \
6 -I$(KLIBCOBJ)/../include \
7- -I$(KLIBCINC)
8-ifeq ($(cc-name),clang)
Patrick Williams92b42cb2022-09-03 06:53:57 -05009-KLIBCCPPFLAGS += -isystem $(shell $(KLIBCCC) $(KLIBCCFLAGS) --print-file-name=include)
Andrew Geisslerac970dd2021-02-12 15:32:45 -060010-endif
11+ -I$(KLIBCINC) \
12+ -I$(shell $(KLIBCCC) $(KLIBCCFLAGS) --print-file-name=include)
13
14 # kernel include paths
15 KLIBCKERNELSRC ?= $(srctree)
16@@ -137,7 +135,7 @@ KLIBCCFLAGS += $(KLIBCCPPFLAGS) $(K
17 KLIBCAFLAGS += -D__ASSEMBLY__ $(KLIBCCFLAGS)
18 KLIBCSTRIPFLAGS += --strip-all -R .comment -R .note
19
20-KLIBCLIBGCC_DEF := $(shell $(KLIBCCC) $(KLIBCCFLAGS) $(if $(filter gcc,$(cc-name)),--print-libgcc,--print-libgcc-file-name))
21+KLIBCLIBGCC_DEF := $(shell $(KLIBCCC) $(KLIBCCFLAGS) --print-libgcc-file-name)
22 KLIBCLIBGCC ?= $(KLIBCLIBGCC_DEF)
23 KLIBCCRT0 := $(KLIBCOBJ)/arch/$(KLIBCARCHDIR)/crt0.o
24 KLIBCLIBC := $(KLIBCOBJ)/libc.a