xref: /linux/tools/perf/arch/loongarch/Makefile (revision 7f71507851fc7764b36a3221839607d3a45c2025)
1# SPDX-License-Identifier: GPL-2.0
2PERF_HAVE_JITDUMP := 1
3HAVE_KVM_STAT_SUPPORT := 1
4
5#
6# Syscall table generation for perf
7#
8
9out    := $(OUTPUT)arch/loongarch/include/generated/asm
10header := $(out)/syscalls.c
11incpath := $(srctree)/tools
12sysdef := $(srctree)/tools/arch/loongarch/include/uapi/asm/unistd.h
13sysprf := $(srctree)/tools/perf/arch/loongarch/entry/syscalls/
14systbl := $(sysprf)/mksyscalltbl
15
16# Create output directory if not already present
17$(shell [ -d '$(out)' ] || mkdir -p '$(out)')
18
19$(header): $(sysdef) $(systbl)
20	$(Q)$(SHELL) '$(systbl)' '$(CC)' '$(HOSTCC)' $(incpath) $(sysdef) > $@
21
22clean::
23	$(call QUIET_CLEAN, loongarch) $(RM) $(header)
24
25archheaders: $(header)
26