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