From 958c166837a484e2a9515342c49e93dca734d726 Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Sat, 5 Nov 2022 22:57:18 +0100 Subject: [PATCH] package/linux-tools: perf needs threads Fix the following build failure raised (at least) since linux 4.0 and https://github.com/torvalds/linux/commit/459a3df76c99124fd222586be7f10f862547e7a9: CC /home/autobuild/autobuild/instance-2/output-1/build/linux-6.0.1/tools/perf/builtin-bench.o In file included from builtin-bench.c:22: bench/bench.h:66:10: fatal error: pthread.h: No such file or directory 66 | #include | ^~~~~~~~~~~ Fies: - http://autobuild.buildroot.org/results/b6abd641f528101e74f9af33e54ccefe0731148f Signed-off-by: Fabrice Fontaine Signed-off-by: Thomas Petazzoni --- package/linux-tools/Config.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/package/linux-tools/Config.in b/package/linux-tools/Config.in index 82e62f826e..8a0b6d5802 100644 --- a/package/linux-tools/Config.in +++ b/package/linux-tools/Config.in @@ -47,14 +47,15 @@ config BR2_PACKAGE_LINUX_TOOLS_PCI These tools are available only from kernel version 4.20. -comment "perf needs a toolchain w/ dynamic library" +comment "perf needs a toolchain w/ dynamic library, threads" depends on BR2_TOOLCHAIN_HAS_SYNC_4 - depends on BR2_STATIC_LIBS + depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS config BR2_PACKAGE_LINUX_TOOLS_PERF bool "perf" depends on BR2_TOOLCHAIN_HAS_SYNC_4 depends on !BR2_STATIC_LIBS # dlfcn.h + depends on BR2_TOOLCHAIN_HAS_THREADS select BR2_PACKAGE_LINUX_TOOLS help perf (sometimes "Perf Events" or perf tools, originally