kernel: split patches folder up into backport, pending and hack folders
[openwrt/staging/wigyori.git] / target / linux / generic / hack-4.9 / 211-host_tools_portability.patch
1 From 7f698012384ccb1ed10cc758acfd085096fdb307 Mon Sep 17 00:00:00 2001
2 From: Felix Fietkau <nbd@nbd.name>
3 Date: Fri, 7 Jul 2017 17:02:03 +0200
4 Subject: kernel: fix linux 4.9 host tools portability issues
5
6 Signed-off-by: Felix Fietkau <nbd@nbd.name>
7 ---
8 tools/build/Build.include | 2 +-
9 tools/perf/pmu-events/jevents.c | 1 +
10 tools/perf/pmu-events/json.c | 1 -
11 3 files changed, 2 insertions(+), 2 deletions(-)
12
13 diff --git a/tools/build/Build.include b/tools/build/Build.include
14 index 1dcb95e76f70..9d6f97a7c1aa 100644
15 --- a/tools/build/Build.include
16 +++ b/tools/build/Build.include
17 @@ -95,4 +95,4 @@ cxx_flags = -Wp,-MD,$(depfile),-MT,$@ $(CXXFLAGS) -D"BUILD_STR(s)=\#s" $(CXXFLAG
18 ###
19 ## HOSTCC C flags
20
21 -host_c_flags = -Wp,-MD,$(depfile),-MT,$@ $(CHOSTFLAGS) -D"BUILD_STR(s)=\#s" $(CHOSTFLAGS_$(basetarget).o) $(CHOSTFLAGS_$(obj))
22 +host_c_flags = -MD -MF $(depfile) -MT $@ $(CHOSTFLAGS) -D"BUILD_STR(s)=\#s" $(CHOSTFLAGS_$(basetarget).o) $(CHOSTFLAGS_$(obj))
23 diff --git a/tools/perf/pmu-events/jevents.c b/tools/perf/pmu-events/jevents.c
24 index 41611d7f9873..51333bee190c 100644
25 --- a/tools/perf/pmu-events/jevents.c
26 +++ b/tools/perf/pmu-events/jevents.c
27 @@ -35,6 +35,7 @@
28 #include <stdlib.h>
29 #include <errno.h>
30 #include <string.h>
31 +#include <strings.h>
32 #include <ctype.h>
33 #include <unistd.h>
34 #include <stdarg.h>
35 diff --git a/tools/perf/pmu-events/json.c b/tools/perf/pmu-events/json.c
36 index f67bbb0aa36e..a72c70a97fab 100644
37 --- a/tools/perf/pmu-events/json.c
38 +++ b/tools/perf/pmu-events/json.c
39 @@ -38,7 +38,6 @@
40 #include <unistd.h>
41 #include "jsmn.h"
42 #include "json.h"
43 -#include <linux/kernel.h>
44
45
46 static char *mapfile(const char *fn, size_t *size)
47 --
48 2.11.0
49