4.9 backport request: perf tools: Fix build with ARCH=x86_64
Hi Greg,
Please apply the following commit from 4.10 to 4.9.y to fix perf build under certain conditions:
commit 7a759cd8e8272ee18922838ee711219c7c796a31
Author: Jiada Wang <[email protected]> Date: Sun Apr 9 20:02:37 2017 -0700
perf tools: Fix build with ARCH=x86_64
With commit: 0a943cb10ce78 (tools build: Add HOSTARCH Makefile variable) when building for ARCH=x86_64, ARCH=x86_64 is passed to perf instead of ARCH=x86, so the perf build process searchs header files from tools/arch/x86_64/include, which doesn't exist.
The following build failure is seen:
In file included from util/event.c:2:0:
tools/include/uapi/linux/mman.h:4:27: fatal error: uapi/asm/mman.h: No such file or directory compilation terminated.
Fix this issue by using SRCARCH instead of ARCH in perf, just like the main kernel Makefile and tools/objtool's.
Thanks.
Greg KH
maintainerQuoted 25 lines · Tuomas Tynkkynen
Hi Greg,
Please apply the following commit from 4.10 to 4.9.y to fix perf build under certain conditions:
commit
7a759cd8e8272ee18922838ee711219c7c796a31Author: Jiada Wang <[email protected]> Date: Sun Apr 9 20:02:37 2017 -0700perf tools: Fix build with ARCH=x86_64
With commit:
0a943cb10ce78(tools build: Add HOSTARCHMakefilevariable) when building for ARCH=x86_64, ARCH=x86_64 is passed to perf instead of ARCH=x86, so the perf build process searchs header files fromtools/arch/x86_64/include, which doesn't exist.The following build failure is seen:
In file included from
util/event.c:2:0:
tools/include/uapi/linux/mman.h:4:27: fatal error:uapi/asm/mman.h: No such file or directory compilation terminated.Fix this issue by using SRCARCH instead of ARCH in perf, just like the main kernel
Makefileand tools/objtool's.
Quoted 16 lines
Signed-off-by Jiada Wang <[email protected]>Acked-by Jiri Olsa <[email protected]>Cc Alexander Shishkin <[email protected]>Cc Andi Kleen <[email protected]>Cc Eugeniu Rosca <[email protected]>Cc Jan Stancek <[email protected]>Cc Masami Hiramatsu <[email protected]>Cc Peter Zijlstra <[email protected]>Cc Ravi Bangoria <[email protected]>Cc Rui Teng <[email protected]>Cc Sukadev Bhattiprolu <[email protected]>Cc Wang Nan <[email protected]>Fixes 0a943cb10ce7 ("tools build: Add HOSTARCH Makefile variable")Signed-off-by Arnaldo Carvalho de Melo <[email protected]>
Now queued up, thanks.
greg k-h