xref: /linux/tools/perf/arch/powerpc/Makefile (revision 4e0ae876f77bc01a7e77724dea57b4b82bd53244)
1# SPDX-License-Identifier: GPL-2.0
2ifndef NO_DWARF
3PERF_HAVE_DWARF_REGS := 1
4endif
5
6HAVE_KVM_STAT_SUPPORT := 1
7PERF_HAVE_ARCH_REGS_QUERY_REGISTER_OFFSET := 1
8PERF_HAVE_JITDUMP := 1
9
10#
11# Syscall table generation for perf
12#
13
14out    := $(OUTPUT)arch/powerpc/include/generated/asm
15header32 := $(out)/syscalls_32.c
16header64 := $(out)/syscalls_64.c
17syskrn := $(srctree)/arch/powerpc/kernel/syscalls/syscall.tbl
18sysprf := $(srctree)/tools/perf/arch/powerpc/entry/syscalls
19sysdef := $(sysprf)/syscall.tbl
20systbl := $(sysprf)/mksyscalltbl
21
22# Create output directory if not already present
23_dummy := $(shell [ -d '$(out)' ] || mkdir -p '$(out)')
24
25$(header64): $(sysdef) $(systbl)
26	@(test -d ../../kernel -a -d ../../tools -a -d ../perf && ( \
27	(diff -B $(sysdef) $(syskrn) >/dev/null) \
28	|| echo "Warning: Kernel ABI header at '$(sysdef)' differs from latest version at '$(syskrn)'" >&2 )) || true
29	$(Q)$(SHELL) '$(systbl)' '64' $(sysdef) > $@
30
31$(header32): $(sysdef) $(systbl)
32	@(test -d ../../kernel -a -d ../../tools -a -d ../perf && ( \
33	(diff -B $(sysdef) $(syskrn) >/dev/null) \
34	|| echo "Warning: Kernel ABI header at '$(sysdef)' differs from latest version at '$(syskrn)'" >&2 )) || true
35	$(Q)$(SHELL) '$(systbl)' '32' $(sysdef) > $@
36
37clean::
38	$(call QUIET_CLEAN, powerpc) $(RM) $(header32) $(header64)
39
40archheaders: $(header32) $(header64)
41