Skip to contentSkip to conversation

linux-tools: perf: Add dependencies for binutils and openssl

Buildroot Peter Korsgaard 1 participant 1 message Mar 27, 2020

lore
Share & tools
lore
#0 lore raw

commit: https://git.buildroot.net/buildroot/commit/?id=90e6eec1e82539db648e9df456a8b024ca2d00d6
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2020.02.x

perf auto-detects and uses the libbfd (from binutils) and openssl libraries if they are detected and happen to be built before perf is, but if they're not, or if per-package directories are enabled, it won't detect these libraries. Explicitly add dependencies on these packages if they are enabled, and disable the feature if not, so that the behavior is deterministic.

(cherry picked from commit 013cc68bf7cd92fc66dc65f7bb62592dc87123db)
---
 package/linux-tools/linux-tool-perf.mk.in | 12 ++++++++++++
 1 file changed, 12 insertions(+)
package/linux-tools/linux-tool-perf.mk.in +12 -0
index 80e00c3c56..7106b622cb 100644
@@ -82,6 +82,18 @@ else
 PERF_MAKE_FLAGS += NO_LIBELF=1 NO_DWARF=1
 endif
 
+ifeq ($(BR2_PACKAGE_BINUTILS),y)
+PERF_DEPENDENCIES += binutils
+else
+PERF_MAKE_FLAGS += NO_DEMANGLE=1
+endif
+
+ifeq ($(BR2_PACKAGE_OPENSSL),y)
+PERF_DEPENDENCIES += openssl
+else
+PERF_MAKE_FLAGS += NO_LIBCRYPTO=1
+endif
+
 ifeq ($(BR2_PACKAGE_ZLIB),y)
 PERF_DEPENDENCIES += zlib
 else