kernel: add linux 5.10 support
[openwrt/openwrt.git] / target / linux / generic / pending-5.10 / 240-remove-unsane-filenames-from-deps_initramfs-list.patch
1 From: Gabor Juhos <juhosg@openwrt.org>
2 Subject: usr: sanitize deps_initramfs list
3
4 If any filename in the intramfs dependency
5 list contains a colon, that causes a kernel
6 build error like this:
7
8 /devel/openwrt/build_dir/linux-ar71xx_generic/linux-3.6.6/usr/Makefile:58: *** multiple target patterns. Stop.
9 make[5]: *** [usr] Error 2
10
11 Fix it by removing such filenames from the
12 deps_initramfs list.
13
14 Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
15 Signed-off-by: Felix Fietkau <nbd@nbd.name>
16 ---
17 usr/Makefile | 8 +++++---
18 1 file changed, 5 insertions(+), 3 deletions(-)
19
20 --- a/usr/Makefile
21 +++ b/usr/Makefile
22 @@ -61,6 +61,8 @@ hostprogs := gen_init_cpio
23 # The dependency list is generated by gen_initramfs.sh -l
24 -include $(obj)/.initramfs_data.cpio.d
25
26 +deps_initramfs := $(foreach v,$(deps_initramfs),$(if $(findstring :,$(v)),,$(v)))
27 +
28 # do not try to update files included in initramfs
29 $(deps_initramfs): ;
30