aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/tests/shell
diff options
context:
space:
mode:
authorMichael Jeanson <mjeanson@efficios.com>2026-06-04 13:17:05 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2026-06-04 17:34:52 -0300
commit536e81f07450562caba8e62022763a78fd00a0a7 (patch)
tree0670cc608eec2db349ca5c2e0985c2f77165bcb2 /tools/perf/tests/shell
parentb72ab69175157aac2f3ff1ebc0765e3899ba295b (diff)
perf data ctf: replace libbabeltrace with babeltrace2-ctf-writer
The 1.x branch of Babeltrace has been superseded by 2.x in 2020 and has been unmaintained since 2022, efforts have started to remove it from popular distributions. Babeltrace 2.x offers a very similar 'ctf-writer' library that can be used with minimal changes for the '--to-ctf' feature and has been packaged since Debian 11 and Fedora 32. This patch replaces the 'libbabeltrace' build feature with 'babeltrace2-ctf-writer' using pkgconfig detection, adjusts the naming of the public headers and applies minor API cleanups. There is no changes to the output ctf traces, the ctf-writer API still implements version 1.8 of the CTF specification that can be read by either Babeltrace 1 / 2 or any CTF compliant reader. Also remove some ifdefs in the cli option parsing to allow printing the helpful error message with '--to-ctf' when built without babeltrace2. Reviewed-by: Ian Rogers <irogers@google.com> Signed-off-by: Michael Jeanson <mjeanson@efficios.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Derek Foreman <derek.foreman@collabora.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: James Clark <james.clark@linaro.org> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/tests/shell')
-rwxr-xr-xtools/perf/tests/shell/test_perf_data_converter_ctf.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/perf/tests/shell/test_perf_data_converter_ctf.sh b/tools/perf/tests/shell/test_perf_data_converter_ctf.sh
index 334eebc9945e..bc58a8dabf4c 100755
--- a/tools/perf/tests/shell/test_perf_data_converter_ctf.sh
+++ b/tools/perf/tests/shell/test_perf_data_converter_ctf.sh
@@ -24,11 +24,11 @@ trap_cleanup()
}
trap trap_cleanup exit term int
-check_babeltrace_support()
+check_babeltrace2_support()
{
- if ! perf check feature libbabeltrace
+ if ! perf check feature babeltrace2-ctf-writer
then
- echo "perf not linked with libbabeltrace, skipping test"
+ echo "perf not linked with babeltrace2-ctf-writer, skipping test"
exit 2
fi
}
@@ -97,7 +97,7 @@ test_ctf_converter_pipe()
fi
}
-check_babeltrace_support
+check_babeltrace2_support
test_ctf_converter_file
test_ctf_converter_pipe