summaryrefslogtreecommitdiffstats
path: root/debian/patches/bugfix/all/tools-perf-fix-build-without-libbfd.patch
blob: 726bdfc47bbb66205b51953e0c98ba0c46193add (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
From: Ben Hutchings <benh@debian.org>
Date: Tue, 05 Jul 2022 18:02:28 +0200
Subject: tools/perf: Fix build without libbfd

Only include <tools/dis-asm-compat.h> if we are using libbfd.

Signed-off-by: Ben Hutchings <benh@debian.org>
---
--- a/tools/perf/util/annotate.c
+++ b/tools/perf/util/annotate.c
@@ -41,7 +41,6 @@
 #include <linux/string.h>
 #include <subcmd/parse-options.h>
 #include <subcmd/run-command.h>
-#include <tools/dis-asm-compat.h>
 
 /* FIXME: For the HE_COLORSET */
 #include "ui/browser.h"
@@ -1721,6 +1720,7 @@ fallback:
 #include <bpf/btf.h>
 #include <bpf/libbpf.h>
 #include <linux/btf.h>
+#include <tools/dis-asm-compat.h>
 
 static int symbol__disassemble_bpf(struct symbol *sym,
 				   struct annotate_args *args)