diff options
author | Jiri Olsa <[email protected]> | 2019-08-20 14:46:24 +0200 |
---|---|---|
committer | Arnaldo Carvalho de Melo <[email protected]> | 2019-08-20 12:29:36 -0300 |
commit | b81d39c7a1efb83caa3f4419939a46e96191abb6 (patch) | |
tree | 633dafebde3b4893e95ad8103d0d6ab750726966 | |
parent | 42fc2e9ef9603a7948aaa4ffd8dfb94b30294ad8 (diff) |
libperf: Fix arch include paths
Guenter Roeck reported problem with compilation when the ARCH is
specified:
$ make ARCH=x86_64
In file included from tools/include/asm/atomic.h:6:0,
from include/linux/atomic.h:5,
from tools/include/linux/refcount.h:41,
from cpumap.c:4: tools/include/asm/../../arch/x86/include/asm/atomic.h:11:10:
fatal error: asm/cmpxchg.h: No such file or directory
The problem is that we don't use SRCARCH (the sanitized ARCH version)
and we don't get the proper include path.
Reported-by: Guenter Roeck <[email protected]>
Signed-off-by: Jiri Olsa <[email protected]>
Tested-by: Guenter Roeck <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Alexey Budankov <[email protected]>
Cc: Andi Kleen <[email protected]>
Cc: Michael Petlan <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Fixes: 314350491810 ("libperf: Make libperf.a part of the perf build")
Link: http://lkml.kernel.org/r/20190820124624.GG24105@krava
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
-rw-r--r-- | tools/perf/lib/Makefile | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/lib/Makefile b/tools/perf/lib/Makefile index 8a9ae50818e4..a67efb8d9d39 100644 --- a/tools/perf/lib/Makefile +++ b/tools/perf/lib/Makefile @@ -59,7 +59,7 @@ else CFLAGS := -g -Wall endif -INCLUDES = -I$(srctree)/tools/perf/lib/include -I$(srctree)/tools/include -I$(srctree)/tools/arch/$(ARCH)/include/ -I$(srctree)/tools/arch/$(ARCH)/include/uapi -I$(srctree)/tools/include/uapi +INCLUDES = -I$(srctree)/tools/perf/lib/include -I$(srctree)/tools/include -I$(srctree)/tools/arch/$(SRCARCH)/include/ -I$(srctree)/tools/arch/$(SRCARCH)/include/uapi -I$(srctree)/tools/include/uapi # Append required CFLAGS override CFLAGS += $(EXTRA_WARNINGS) |