Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'kbuild-fixes-v5.8-3' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild into master

Pull Kbuild fixes from Masahiro Yamada:

- do not use non-portable strsep() in a host program

- fix single target builds for external modules

- change Clang's --prefix option to make it work for the latest Clang

* tag 'kbuild-fixes-v5.8-3' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
Makefile: Fix GCC_TOOLCHAIN_DIR prefix for Clang cross compilation
kbuild: fix single target builds for external modules
modpost: remove use of non-standard strsep() in HOSTCC code

+12 -4
+2 -2
Makefile
··· 567 567 ifneq ($(CROSS_COMPILE),) 568 568 CLANG_FLAGS += --target=$(notdir $(CROSS_COMPILE:%-=%)) 569 569 GCC_TOOLCHAIN_DIR := $(dir $(shell which $(CROSS_COMPILE)elfedit)) 570 - CLANG_FLAGS += --prefix=$(GCC_TOOLCHAIN_DIR) 570 + CLANG_FLAGS += --prefix=$(GCC_TOOLCHAIN_DIR)$(notdir $(CROSS_COMPILE)) 571 571 GCC_TOOLCHAIN := $(realpath $(GCC_TOOLCHAIN_DIR)/..) 572 572 endif 573 573 ifneq ($(GCC_TOOLCHAIN),) ··· 1754 1754 descend: $(build-dirs) 1755 1755 $(build-dirs): prepare 1756 1756 $(Q)$(MAKE) $(build)=$@ \ 1757 - single-build=$(if $(filter-out $@/, $(filter $@/%, $(single-no-ko))),1) \ 1757 + single-build=$(if $(filter-out $@/, $(filter $@/%, $(KBUILD_SINGLE_TARGETS))),1) \ 1758 1758 need-builtin=1 need-modorder=1 1759 1759 1760 1760 clean-dirs := $(addprefix _clean_, $(clean-dirs))
+10 -2
scripts/mod/modpost.c
··· 138 138 139 139 char *get_line(char **stringp) 140 140 { 141 + char *orig = *stringp, *next; 142 + 141 143 /* do not return the unwanted extra line at EOF */ 142 - if (*stringp && **stringp == '\0') 144 + if (!orig || *orig == '\0') 143 145 return NULL; 144 146 145 - return strsep(stringp, "\n"); 147 + next = strchr(orig, '\n'); 148 + if (next) 149 + *next++ = '\0'; 150 + 151 + *stringp = next; 152 + 153 + return orig; 146 154 } 147 155 148 156 /* A list of all modules we processed */