diff options
| author | Yang Jihong <[email protected]> | 2024-03-14 06:30:00 +0000 |
|---|---|---|
| committer | Arnaldo Carvalho de Melo <[email protected]> | 2024-04-03 21:05:19 +0000 |
| commit | baa2ca59ec1e31ccbe3f24ff0368152b36f68720 (patch) | |
| tree | cb81728bdb0d560f9319bd9dc1e60aa88d31c3dd /tools/perf/util/annotate.c | |
| parent | perf beauty: Fix AT_EACCESS undeclared build error for system with kernel ver... (diff) | |
| download | kernel-baa2ca59ec1e31ccbe3f24ff0368152b36f68720.tar.gz kernel-baa2ca59ec1e31ccbe3f24ff0368152b36f68720.zip | |
perf build: Add LIBTRACEEVENT_DIR build option
Currently, when libtraceevent is not linked,
perf does not support tracepoint:
# ./perf record -e sched:sched_switch -a sleep 10
event syntax error: 'sched:sched_switch'
\___ unsupported tracepoint
libtraceevent is necessary for tracepoint support
Run 'perf list' for a list of valid events
Usage: perf record [<options>] [<command>]
or: perf record [<options>] -- <command> [<options>]
-e, --event <event> event selector. use 'perf list' to list available events
For cross-compilation scenario, library may not be installed in the default
system path. Based on the above requirements, add LIBTRACEEVENT_DIR build
option to support specifying path of libtraceevent.
Example:
1. Cross compile libtraceevent
# cd /opt/libtraceevent
# CROSS_COMPILE=aarch64-linux-gnu- make
2. Cross compile perf
# cd tool/perf
# make VF=1 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- NO_LIBELF=1 LDFLAGS=--static LIBTRACEEVENT_DIR=/opt/libtraceevent
<SNIP>
Auto-detecting system features:
<SNIP>
... LIBTRACEEVENT_DIR: /opt/libtraceevent
Reviewed-by: Ian Rogers <[email protected]>
Signed-off-by: Yang Jihong <[email protected]>
Cc: Adrian Hunter <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/util/annotate.c')
0 files changed, 0 insertions, 0 deletions
