From: Luca Ceresoli via buildroot <buildroot@buildroot.org>
To: buildroot@buildroot.org
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
Luca Ceresoli <luca.ceresoli@bootlin.com>
Subject: [Buildroot] [PATCH] package/heaptrack: new package
Date: Fri, 31 Jul 2026 19:25:35 +0200 [thread overview]
Message-ID: <20260731-heaptrack-v1-1-c558715cb4c3@bootlin.com> (raw)
Add heaptrack, a memory allocation tracer toolkit.
This implementation builds all the command line components, not the
heaptrack_gui graphical visualization program.
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
---
package/Config.in | 1 +
package/heaptrack/Config.in | 26 ++++++++++++++++++++++++++
package/heaptrack/heaptrack.hash | 1 +
package/heaptrack/heaptrack.mk | 25 +++++++++++++++++++++++++
4 files changed, 53 insertions(+)
diff --git a/package/Config.in b/package/Config.in
index fc1e57d30dd7..7caf56e6de6f 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -106,6 +106,7 @@ menu "Debugging, profiling and benchmark"
source "package/fwts/Config.in"
source "package/gdb/Config.in"
source "package/google-breakpad/Config.in"
+ source "package/heaptrack/Config.in"
source "package/hyperfine/Config.in"
source "package/iozone/Config.in"
source "package/k3conf/Config.in"
diff --git a/package/heaptrack/Config.in b/package/heaptrack/Config.in
new file mode 100644
index 000000000000..ea54195c9318
--- /dev/null
+++ b/package/heaptrack/Config.in
@@ -0,0 +1,26 @@
+config BR2_PACKAGE_HEAPTRACK
+ bool "heaptrack"
+ depends on BR2_INSTALL_LIBSTDCPP
+ depends on BR2_LINUX_KERNEL
+ select BR2_PACKAGE_BOOST
+ select BR2_PACKAGE_BOOST_IOSTREAMS
+ select BR2_PACKAGE_BOOST_PROGRAM_OPTIONS
+ # For heaptrack_print
+ select BR2_PACKAGE_BOOST_FILESYSTEM
+ select BR2_PACKAGE_LIBUNWIND
+ select BR2_PACKAGE_ZLIB
+ select BR2_PACKAGE_ELFUTILS
+ help
+ Heaptrack traces all memory allocations and annotates these
+ events with stack traces. Dedicated analysis tools then allow
+ you to interpret the heap memory profile to find hotspots,
+ memory leaks, allocation hotspots and temporary allocations.
+
+ Zstandard offers better (de)compression performance compared
+ with gzip/zlib, making heaptrack faster and datafiles smaller,
+ so enabling BR2_PACKAGE_ZSTD is recommended.
+
+ https://apps.kde.org/heaptrack/
+
+comment "heaptrack needs a toolchain w/ C++"
+ depends on !BR2_INSTALL_LIBSTDCPP
diff --git a/package/heaptrack/heaptrack.hash b/package/heaptrack/heaptrack.hash
new file mode 100644
index 000000000000..d9eb6010ac18
--- /dev/null
+++ b/package/heaptrack/heaptrack.hash
@@ -0,0 +1 @@
+sha256 e69de2209ab0e16c8e26c1b60feeb852b3a88e46a4f16588c08254e1bd81a183 heaptrack-3e6cce3d210a6672fe6f92de0bed567c49b7a9c5-git4.tar.gz
diff --git a/package/heaptrack/heaptrack.mk b/package/heaptrack/heaptrack.mk
new file mode 100644
index 000000000000..6349e7aeb04d
--- /dev/null
+++ b/package/heaptrack/heaptrack.mk
@@ -0,0 +1,25 @@
+################################################################################
+#
+# heaptrack
+#
+################################################################################
+
+HEAPTRACK_SITE_METHOD = git
+HEAPTRACK_SITE = https://invent.kde.org/sdk/heaptrack.git
+HEAPTRACK_VERSION = 3e6cce3d210a6672fe6f92de0bed567c49b7a9c5
+HEAPTRACK_LICENSE = LGPL-2.1-or-later, GPL-2.0-or-later (heaptrack_interpret)
+HEAPTRACK_LICENSE_FILES = LICENSES/LGPL-2.1-only.txt \
+ LICENSES/GPL-2.0-or-later.txt \
+ LICENSES/LGPL-2.1-or-later.txt \
+ LICENSES/BSL-1.0.txt \
+ LICENSES/MIT.txt \
+ LICENSES/Apache-2.0.txt \
+ LICENSES/BSD-3-Clause.txt
+HEAPTRACK_DEPENDENCIES = host-pkgconf linux boost libunwind zlib elfutils
+HEAPTRACK_CONF_OPTS += -DHEAPTRACK_BUILD_GUI=OFF -DHEAPTRACK_BUILD_PRINT=ON
+
+ifeq ($(BR2_PACKAGE_ZSTD),y)
+HEAPTRACK_DEPENDENCIES += zstd
+endif
+
+$(eval $(cmake-package))
---
base-commit: 9bc585a804b2ce7b5f82f538f6108cca27c3116a
change-id: 20260731-heaptrack-cd4f6f8fcec8
Best regards,
--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next reply other threads:[~2026-07-31 17:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-31 17:25 Luca Ceresoli via buildroot [this message]
2026-07-31 18:59 ` [Buildroot] [PATCH] package/heaptrack: new package Thomas Petazzoni via buildroot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260731-heaptrack-v1-1-c558715cb4c3@bootlin.com \
--to=buildroot@buildroot.org \
--cc=luca.ceresoli@bootlin.com \
--cc=thomas.petazzoni@bootlin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.