From patchwork Tue Nov 11 04:31:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 74133 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7104DCCF9E3 for ; Tue, 11 Nov 2025 04:31:35 +0000 (UTC) Received: from mail-pg1-f172.google.com (mail-pg1-f172.google.com [209.85.215.172]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.10090.1762835492742988663 for ; Mon, 10 Nov 2025 20:31:32 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=hw4qs0e1; spf=pass (domain: gmail.com, ip: 209.85.215.172, mailfrom: raj.khem@gmail.com) Received: by mail-pg1-f172.google.com with SMTP id 41be03b00d2f7-b5a631b9c82so3115926a12.1 for ; Mon, 10 Nov 2025 20:31:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1762835492; x=1763440292; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=GHVvd7qeejxsZeJtYgCdhXofqXjmYmCmKDnfm4pqF8I=; b=hw4qs0e1p3qmRRiYnqAo2wNF3c3iuDDxrnnhHO8jvndyBiC2Wo5VUBdMUnI26Tl7PU 8kCHPw0up3ws4yqF1IvUqZheE5NpXPz4p/d6GNOReQsG4rc0Bz2k1TajePC85kfimVkm KJ2QO/pd4AB+AtA53y4DetV+2ePDSP3xKq+9c+4U/4evCN90GNyc5YUhWkHK5cLT34XC Pa3n9uBSi/HdW5FFnZ3ggzT0Hp3DQTmV7arBCVJQ+XFE9+4K/HNDQEJ8t8/EqUN6oFSx 1YwX7KDHloOAHiuXyDZQyj0JfOK1lQstwDYdMyd0U9BVjVs/7A0L2Q0tPx7nnRUURoIB tv6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1762835492; x=1763440292; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=GHVvd7qeejxsZeJtYgCdhXofqXjmYmCmKDnfm4pqF8I=; b=P0UqKz8EIMzbSGClE2KJ0Xz3EOsIS6FA7EDibnZvlwa9vOBVn9XoEz8VPmc/5r5yYN Zb8idRdq+hgOheHw0RtZGKo39YlajxbBigW/B2jck/07MnOHYZTDvwfegrhPUPZ5wPWA LPm+VA9HbfOW0O1EvEXryfweTgZgpViCvynSdPBpAnBrx797S/3QXuT1aEvV1Vjiogak PpVS5JjN0VDl6WTCnrenR1B9k/VsP+vA0cahr9gwoxcDSvNbbqSfvsSCdhlgKpeKEV4y 97mKxTFoICWGG+V5PMzZ9W1Q8YyI4EveC0wugb/s3nkvUwvBjtlPc3E667wsLj1PQI7N sC0g== X-Gm-Message-State: AOJu0YxFOz4sbnMZweUgYrPXoxPmSkOTJIHLwRo9oWXpQ+8f5vsgSrpv uRpeZ8UXGH0x7yXw4XFruV5jVoRj4DaBTzrXRNVOoyza+Rf0PH7vxtVQbm79LMOCMgk= X-Gm-Gg: ASbGncsywfzHhKjlmDWV0KtIjjRyEKrG9qa4ujLQhFFErm57Y21K/Ongmh5WbCAmc7V ScY+mXo5vGIc716mjv0bKDBb5wvbRWmnB1iv1NhKlZHkrTaR3Tqv5kATGY0KOswk/syrbTrJt6Y s6I0RCwOodax75JXFLTawWI1T4IiQamE9ty+0Cn+BjffsCjv5EDDiWs03q38UwR0cX8z82AUYWY hKM7MGwMVUG7B20uQugLqItuk5eFb8+PWBT2uxztsQwmSKGaXMNtnl8pRYAgfXpfEp6GCTF0Mvr L9HFYeQDukmzdaiRmPmS25d8s+eRSY4Z7NRJdkQC038i/+mj1DGPEWJ0LFgxjzE4cvX9MSW9AnK PF3hy5wuupFdkBIXy8D8WYUUPxf1GBLScaW57xQTZ1131G/f35hijQ0BaDqr21/7od8/5pfpv7B tCbm6xlBAGDyQ1bYrACyxFuQc369ZRHDOmlbGMRa3kEfY0snlsxYto5E8Gmhs8pq2On4SZOEsO X-Google-Smtp-Source: AGHT+IFndfviYgSZNxF0RfeBnBxgxvOXMaurw23nisEBEOZTHFT0GPqH2G3iUd0kTi4ZC7PjCaeQ+A== X-Received: by 2002:a17:902:e88f:b0:295:592e:7633 with SMTP id d9443c01a7336-297e56be211mr149769265ad.29.1762835491552; Mon, 10 Nov 2025 20:31:31 -0800 (PST) Received: from apollo.tail3ccdd3.ts.net ([2601:646:8201:fd20::888a]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-29651ca1b8csm167771415ad.85.2025.11.10.20.31.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Nov 2025 20:31:30 -0800 (PST) From: Khem Raj To: openembedded-devel@lists.openembedded.org Cc: Khem Raj Subject: [meta-oe][PATCH 1/4] heaptrack: Update to latest tip of trunk Date: Mon, 10 Nov 2025 20:31:24 -0800 Message-ID: <20251111043128.3063095-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.51.2 MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 11 Nov 2025 04:31:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121474 * It has cmake 4 fixes * Drop all patches, they are no more needed * Fix build with glibc-2.43/c23 * Enabled on riscv64, since libunwind now supports it Signed-off-by: Khem Raj --- .../0001-libheaptrack-Fix-build-on-c23.patch | 47 +++++++ ...heaptrack-Replace-__pid_t-with-pid_t.patch | 26 ---- ...-unw_set_caching_policy-before-using.patch | 41 ------ ...t-Include-dlfcn.h-for-dlopen-dlclose.patch | 38 ------ ...d-Make-noexcept-attribute-conditiona.patch | 118 ------------------ ...04-backtrace-Always-include-stdint.h.patch | 42 ------- .../heaptrack/heaptrack_1.2.0.bb | 63 ---------- .../heaptrack/heaptrack_1.5.0.bb | 33 +++++ 8 files changed, 80 insertions(+), 328 deletions(-) create mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Fix-build-on-c23.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Replace-__pid_t-with-pid_t.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0001-track-Check-for-unw_set_caching_policy-before-using.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0002-heaptrack_inject-Include-dlfcn.h-for-dlopen-dlclose.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0003-heaptrack_preload-Make-noexcept-attribute-conditiona.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack/0004-backtrace-Always-include-stdint.h.patch delete mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack_1.2.0.bb create mode 100644 meta-oe/recipes-devtools/heaptrack/heaptrack_1.5.0.bb diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Fix-build-on-c23.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Fix-build-on-c23.patch new file mode 100644 index 0000000000..67669e2811 --- /dev/null +++ b/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Fix-build-on-c23.patch @@ -0,0 +1,47 @@ +From 5afb9b9267b59f60b53978858e21ec2369659de7 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Mon, 10 Nov 2025 18:53:38 -0800 +Subject: [PATCH] libheaptrack: Fix build on c23 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +C23/glibc is now including once_init in stdlib.h + +https://patchwork.sourceware.org/project/glibc/patch/78061085-f04a-0c45-107b-5a8a15521083@redhat.com/#213088 + +This is a name collision with the new C once_flag/call_once that +glibc exposes (via ) and C++’s std::once_flag/std::call_once + +Fixes +../sources/heaptrack-1.5.0+git/src/track/libheaptrack.cpp:301:16: error: reference to 'once_flag' is ambiguous + 301 | static once_flag once; + | ^ +../recipe-sysroot/usr/include/bits/types/once_flag.h:24:21: note: candidate found by name lookup is 'once_flag' + 24 | typedef __once_flag once_flag; + | ^ +../recipe-sysroot/usr/lib/aarch64-yoe-linux/15.2.0/../../../include/c++/15.2.0/mutex:809:10: note: candidate found by name lookup is 'std::once_flag' + 809 | struct once_flag + | ^ + +Upstream-Status: Submitted [https://invent.kde.org/sdk/heaptrack/-/merge_requests/56] +Signed-off-by: Khem Raj +--- + src/track/libheaptrack.cpp | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/track/libheaptrack.cpp b/src/track/libheaptrack.cpp +index 4be3dcd..f7576a2 100644 +--- a/src/track/libheaptrack.cpp ++++ b/src/track/libheaptrack.cpp +@@ -298,8 +298,8 @@ public: + } + + // do some once-only initializations +- static once_flag once; +- call_once(once, [] { ++ static std::once_flag once; ++ std::call_once(once, [] { + debugLog("%s", "doing once-only initialization"); + + Trace::setup(); diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Replace-__pid_t-with-pid_t.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Replace-__pid_t-with-pid_t.patch deleted file mode 100644 index 9681086a52..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-libheaptrack-Replace-__pid_t-with-pid_t.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 18671cd6028f996c138c6eb4282caf313f3fc605 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 23 Nov 2020 15:25:18 -0800 -Subject: [PATCH] libheaptrack: Replace __pid_t with pid_t - -__pid_t is for internal libc use - -Upstream-Status: Pending -Signed-off-by: Khem Raj ---- - src/track/libheaptrack.cpp | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/track/libheaptrack.cpp b/src/track/libheaptrack.cpp -index e138bce..4120ecd 100644 ---- a/src/track/libheaptrack.cpp -+++ b/src/track/libheaptrack.cpp -@@ -79,7 +79,7 @@ chrono::milliseconds elapsedTime() - return chrono::duration_cast(clock::now() - startTime()); - } - --__pid_t gettid() -+pid_t gettid() - { - return syscall(SYS_gettid); - } diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-track-Check-for-unw_set_caching_policy-before-using.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-track-Check-for-unw_set_caching_policy-before-using.patch deleted file mode 100644 index a6547eded8..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack/0001-track-Check-for-unw_set_caching_policy-before-using.patch +++ /dev/null @@ -1,41 +0,0 @@ -From bcfc4c8d7dc70bd81367c183a68cc9ee02ab4744 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Fri, 28 May 2021 17:52:57 -0700 -Subject: [PATCH] track: Check for unw_set_caching_policy before using - -llvm libunwind does not implement unw_cache_* functions yet -Include inttypes.h got PRI* macros - -Upstream-Status: Submitted [https://github.com/KDE/heaptrack/pull/33] -Signed-off-by: Khem Raj ---- - src/track/trace_libunwind.cpp | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/src/track/trace_libunwind.cpp b/src/track/trace_libunwind.cpp -index c76337c..96b2176 100644 ---- a/src/track/trace_libunwind.cpp -+++ b/src/track/trace_libunwind.cpp -@@ -26,6 +26,7 @@ - - #define UNW_LOCAL_ONLY - #include -+#include - - #include - -@@ -60,9 +61,11 @@ void Trace::print() - void Trace::setup() - { - // configure libunwind for better speed -+#if UNW_CACHE_PER_THREAD - if (unw_set_caching_policy(unw_local_addr_space, UNW_CACHE_PER_THREAD)) { - fprintf(stderr, "WARNING: Failed to enable per-thread libunwind caching.\n"); - } -+#endif - #if LIBUNWIND_HAS_UNW_SET_CACHE_SIZE - if (unw_set_cache_size(unw_local_addr_space, 1024, 0)) { - fprintf(stderr, "WARNING: Failed to set libunwind cache size.\n"); --- -2.31.1 - diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0002-heaptrack_inject-Include-dlfcn.h-for-dlopen-dlclose.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0002-heaptrack_inject-Include-dlfcn.h-for-dlopen-dlclose.patch deleted file mode 100644 index 5fa802cb38..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack/0002-heaptrack_inject-Include-dlfcn.h-for-dlopen-dlclose.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 8ebcf5f2dd27dbeb6c81e9c40a5d17916cb243e6 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 23 Nov 2020 15:26:31 -0800 -Subject: [PATCH] heaptrack_inject: Include dlfcn.h for dlopen/dlclose - -Do not use __WORDSIZE which is for libc internal use - -Upstream-Status: Pending -Signed-off-by: Khem Raj ---- - src/track/heaptrack_inject.cpp | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/src/track/heaptrack_inject.cpp b/src/track/heaptrack_inject.cpp -index 325d87e..fb1c154 100644 ---- a/src/track/heaptrack_inject.cpp -+++ b/src/track/heaptrack_inject.cpp -@@ -28,6 +28,7 @@ - #include - #include - #include -+#include - - #include - -@@ -39,9 +40,10 @@ - * @brief Experimental support for symbol overloading after runtime injection. - */ - --#if __WORDSIZE == 64 -+#include -+#if ULONG_MAX == 0xffffffffffffffff - #define ELF_R_SYM(i) ELF64_R_SYM(i) --#elif __WORDSIZE == 32 -+#elif ULONG_MAX == 0xffffffff - #define ELF_R_SYM(i) ELF32_R_SYM(i) - #else - #error unsupported word size diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0003-heaptrack_preload-Make-noexcept-attribute-conditiona.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0003-heaptrack_preload-Make-noexcept-attribute-conditiona.patch deleted file mode 100644 index c3c852e39e..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack/0003-heaptrack_preload-Make-noexcept-attribute-conditiona.patch +++ /dev/null @@ -1,118 +0,0 @@ -From b8435c6523d9377f04d5e21629f3dc68b8865016 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 23 Nov 2020 15:31:45 -0800 -Subject: [PATCH] heaptrack_preload: Make noexcept attribute conditional - -musl does not define these functions with noexcept and hence compiler -complains about them - -Upstream-Status: Pending -Signed-off-by: Khem Raj ---- - src/track/heaptrack_preload.cpp | 26 ++++++++++++++++---------- - 1 file changed, 16 insertions(+), 10 deletions(-) - -diff --git a/src/track/heaptrack_preload.cpp b/src/track/heaptrack_preload.cpp -index 63110ce..ee85331 100644 ---- a/src/track/heaptrack_preload.cpp -+++ b/src/track/heaptrack_preload.cpp -@@ -171,11 +171,17 @@ void init() - } - } - -+#ifdef __GLIBC__ -+#define NOEXECPT noexcept -+#else -+#define NOEXECPT -+#endif -+ - extern "C" { - - /// TODO: memalign, pvalloc, ...? - --void* malloc(size_t size) noexcept -+void* malloc(size_t size) NOEXECPT - { - if (!hooks::malloc) { - hooks::init(); -@@ -186,7 +192,7 @@ void* malloc(size_t size) noexcept - return ptr; - } - --void free(void* ptr) noexcept -+void free(void* ptr) NOEXECPT - { - if (!hooks::free) { - hooks::init(); -@@ -204,7 +210,7 @@ void free(void* ptr) noexcept - hooks::free(ptr); - } - --void* realloc(void* ptr, size_t size) noexcept -+void* realloc(void* ptr, size_t size) NOEXECPT - { - if (!hooks::realloc) { - hooks::init(); -@@ -219,7 +225,7 @@ void* realloc(void* ptr, size_t size) noexcept - return ret; - } - --void* calloc(size_t num, size_t size) noexcept -+void* calloc(size_t num, size_t size) NOEXECPT - { - if (!hooks::calloc) { - hooks::init(); -@@ -235,7 +241,7 @@ void* calloc(size_t num, size_t size) noexcept - } - - #if HAVE_CFREE --void cfree(void* ptr) noexcept -+void cfree(void* ptr) NOEXECPT - { - if (!hooks::cfree) { - hooks::init(); -@@ -252,7 +258,7 @@ void cfree(void* ptr) noexcept - } - #endif - --int posix_memalign(void** memptr, size_t alignment, size_t size) noexcept -+int posix_memalign(void** memptr, size_t alignment, size_t size) NOEXECPT - { - if (!hooks::posix_memalign) { - hooks::init(); -@@ -268,7 +274,7 @@ int posix_memalign(void** memptr, size_t alignment, size_t size) noexcept - } - - #if HAVE_ALIGNED_ALLOC --void* aligned_alloc(size_t alignment, size_t size) noexcept -+void* aligned_alloc(size_t alignment, size_t size) NOEXECPT - { - if (!hooks::aligned_alloc) { - hooks::init(); -@@ -285,7 +291,7 @@ void* aligned_alloc(size_t alignment, size_t size) noexcept - #endif - - #if HAVE_VALLOC --void* valloc(size_t size) noexcept -+void* valloc(size_t size) NOEXECPT - { - if (!hooks::valloc) { - hooks::init(); -@@ -301,7 +307,7 @@ void* valloc(size_t size) noexcept - } - #endif - --void* dlopen(const char* filename, int flag) noexcept -+void* dlopen(const char* filename, int flag) NOEXECPT - { - if (!hooks::dlopen) { - hooks::init(); -@@ -316,7 +322,7 @@ void* dlopen(const char* filename, int flag) noexcept - return ret; - } - --int dlclose(void* handle) noexcept -+int dlclose(void* handle) NOEXECPT - { - if (!hooks::dlclose) { - hooks::init(); diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack/0004-backtrace-Always-include-stdint.h.patch b/meta-oe/recipes-devtools/heaptrack/heaptrack/0004-backtrace-Always-include-stdint.h.patch deleted file mode 100644 index 3db03cf85d..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack/0004-backtrace-Always-include-stdint.h.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 200f71ea8c0756594ac7e079ccc686d9a20cea5c Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 23 Nov 2020 15:32:58 -0800 -Subject: [PATCH] backtrace: Always include stdint.h - -in OE we will always have system headers which supports C99/stdint.h - -Upstream-Status: Inappropriate [Unless upstream drops legacy] -Signed-off-by: Khem Raj ---- - 3rdparty/libbacktrace/backtrace.h | 16 ---------------- - 1 file changed, 16 deletions(-) - -diff --git a/3rdparty/libbacktrace/backtrace.h b/3rdparty/libbacktrace/backtrace.h -index 14863cf..d0ac38f 100644 ---- a/3rdparty/libbacktrace/backtrace.h -+++ b/3rdparty/libbacktrace/backtrace.h -@@ -36,24 +36,8 @@ POSSIBILITY OF SUCH DAMAGE. */ - #include - #include - --/* We want to get a definition for uintptr_t, but we still care about -- systems that don't have . */ --#if defined(__GLIBC__) && __GLIBC__ >= 2 -- --#include -- --#elif defined(HAVE_STDINT_H) -- - #include - --#else -- --/* Systems that don't have must provide gstdint.h, e.g., -- from GCC_HEADER_STDINT in configure.ac. */ --#include "gstdint.h" -- --#endif -- - #ifdef __cplusplus - extern "C" { - #endif diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack_1.2.0.bb b/meta-oe/recipes-devtools/heaptrack/heaptrack_1.2.0.bb deleted file mode 100644 index 6896daf836..0000000000 --- a/meta-oe/recipes-devtools/heaptrack/heaptrack_1.2.0.bb +++ /dev/null @@ -1,63 +0,0 @@ -SUMMARY = "Heap memory profiler for Linux" -DESCRIPTION = "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 to reduce memory, leaks, allocation \ -hotspots and temporary allocations" -HOMEPAGE = "https://phabricator.kde.org/source/heaptrack/" -LICENSE = "LGPL-2.1-only" -LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c" - -DEPENDS = "zlib boost libunwind elfutils" - -SRC_URI = "git://github.com/KDE/heaptrack.git;protocol=https;branch=master \ - file://0001-libheaptrack-Replace-__pid_t-with-pid_t.patch \ - file://0002-heaptrack_inject-Include-dlfcn.h-for-dlopen-dlclose.patch \ - file://0003-heaptrack_preload-Make-noexcept-attribute-conditiona.patch \ - file://0004-backtrace-Always-include-stdint.h.patch \ - file://0001-track-Check-for-unw_set_caching_policy-before-using.patch \ - " - -SRCREV = "bc9e3744bcc47de978673d1e382f4125a1ab5fa8" - - -inherit cmake - -EXTRA_OECMAKE += "-DHEAPTRACK_BUILD_GUI=OFF \ - -DCMAKE_POLICY_VERSION_MINIMUM=3.5 \ -" - -# libunwind is not yet ported to RISCV -COMPATIBLE_HOST:riscv32 = "null" -COMPATIBLE_HOST:riscv64 = "null" - -BBCLASSEXTEND = "native" - -# http://errors.yoctoproject.org/Errors/Details/766879/ -# buildResult: -# variable: "LIBUNWIND_HAS_UNW_BACKTRACE" -# cached: true -# stdout: | -# Change Dir: '/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build/CMakeFiles/CMakeScratch/TryCompile-kguYrO' -# -# Run Build Command(s): ninja -v cmTC_51d86 -# [1/2] ccache /OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot-native/usr/bin/aarch64-webos-linux/aarch64-webos-linux-gcc --sysroot=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot -DLIBUNWIND_HAS_UNW_BACKTRACE -mcpu=cortex-a72+crc -mbranch-protection=standard -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security -Werror=return-type --sysroot=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot -O2 -pipe -g -feliminate-unused-debug-types -fcanon-prefix-map -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/git=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/git=/usr/src/debug/heaptrack/1.2.0 -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot= -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot= -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot-native= -o CMakeFiles/cmTC_51d86.dir/src.c.o -c /OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build/CMakeFiles/CMakeScratch/TryCompile-kguYrO/src.c -# FAILED: CMakeFiles/cmTC_51d86.dir/src.c.o -# ccache /OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot-native/usr/bin/aarch64-webos-linux/aarch64-webos-linux-gcc --sysroot=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot -DLIBUNWIND_HAS_UNW_BACKTRACE -mcpu=cortex-a72+crc -mbranch-protection=standard -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security -Werror=return-type --sysroot=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot -O2 -pipe -g -feliminate-unused-debug-types -fcanon-prefix-map -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/git=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/git=/usr/src/debug/heaptrack/1.2.0 -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build=/usr/src/debug/heaptrack/1.2.0 -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot= -fmacro-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot= -fdebug-prefix-map=/OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/recipe-sysroot-native= -o CMakeFiles/cmTC_51d86.dir/src.c.o -c /OE/lge/build/webos/styhead/BUILD/work/raspberrypi4_64-webos-linux/heaptrack/1.2.0/build/CMakeFiles/CMakeScratch/TryCompile-kguYrO/src.c -# src.c: In function 'main': -# src.c:3:43: error: passing argument 1 of 'unw_backtrace' from incompatible pointer type [-Wincompatible-pointer-types] -# 3 | int main() { void* buf[10]; unw_backtrace(&buf, 10); return 0; } -# | ^~~~ -# | | -# | void * (*)[10] -# In file included from ../../../../recipe-sysroot/usr/include/libunwind-aarch64.h:232, -# from ../../../../recipe-sysroot/usr/include/libunwind-64.h:7, -# from ../../../../recipe-sysroot/usr/include/libunwind.h:27, -# from src.c:2: -# ../../../../recipe-sysroot/usr/include/libunwind-common.h:290:27: note: expected 'void **' but argument is of type 'void * (*)[10]' -# 290 | extern int unw_backtrace (void **, int); -# | ^~~~~~~ -# ninja: build stopped: subcommand failed. -# -# exitCode: 1 -# -CFLAGS += "-Wno-error=incompatible-pointer-types" diff --git a/meta-oe/recipes-devtools/heaptrack/heaptrack_1.5.0.bb b/meta-oe/recipes-devtools/heaptrack/heaptrack_1.5.0.bb new file mode 100644 index 0000000000..172a74fa6a --- /dev/null +++ b/meta-oe/recipes-devtools/heaptrack/heaptrack_1.5.0.bb @@ -0,0 +1,33 @@ +SUMMARY = "Heap memory profiler for Linux" +DESCRIPTION = "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 to reduce memory, leaks, allocation \ +hotspots and temporary allocations" +HOMEPAGE = "https://phabricator.kde.org/source/heaptrack/" +LICENSE = "LGPL-2.1-only" +LIC_FILES_CHKSUM = "file://LICENSES/Apache-2.0.txt;md5=c846ebb396f8b174b10ded4771514fcc \ + file://LICENSES/BSD-3-Clause.txt;md5=f225922a2c12dfa5218fb70c49db3ea6 \ + file://LICENSES/BSL-1.0.txt;md5=4c66a2bad475d1a8f152667a4d0ada34 \ + file://LICENSES/GPL-2.0-or-later.txt;md5=3d26203303a722dedc6bf909d95ba815 \ + file://LICENSES/LGPL-2.1-only.txt;md5=41890f71f740302b785c27661123bff5 \ + file://LICENSES/LGPL-2.1-or-later.txt;md5=147a320ed8b16b036829a0c71d424153 \ + file://LICENSES/MIT.txt;md5=7dda4e90ded66ab88b86f76169f28663" + +DEPENDS = "zlib boost libunwind elfutils" + +SRC_URI = "git://github.com/KDE/heaptrack.git;protocol=https;branch=master \ + file://0001-libheaptrack-Fix-build-on-c23.patch \ + " +SRCREV = "0a15d643791e9829ef3f754ac10e3bed966152c5" +PV .= "+git" + +inherit cmake + +EXTRA_OECMAKE += "-DHEAPTRACK_BUILD_GUI=OFF" + +# libunwind is not yet ported to RISCV32 +COMPATIBLE_HOST:riscv32 = "null" + +BBCLASSEXTEND = "native" + +TOOLCHAIN = "gcc" From patchwork Tue Nov 11 04:31:25 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 74132 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 653F5CCFA18 for ; Tue, 11 Nov 2025 04:31:35 +0000 (UTC) Received: from mail-pl1-f179.google.com (mail-pl1-f179.google.com [209.85.214.179]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.10237.1762835493276791688 for ; Mon, 10 Nov 2025 20:31:33 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=mVxvRUq5; spf=pass (domain: gmail.com, ip: 209.85.214.179, mailfrom: raj.khem@gmail.com) Received: by mail-pl1-f179.google.com with SMTP id d9443c01a7336-2980d9b7df5so18081875ad.3 for ; Mon, 10 Nov 2025 20:31:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1762835492; x=1763440292; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=X7TsDK2dJQ+FDS4HTKGVeDzd4T3lq3yW0aViulRBaHY=; b=mVxvRUq5dMg2Jaq4uQirsTreJ+ddKQ++Y7fKJOf7nlnvyrfEHPs/35qoDAko5DUZss SOZnJ5mKRwyG8dwxgUuSQLu5EiOINSfHc4Nuvn+D6wRr+6LdmxdhGd3O3dPDYGfKG8nX VTP1N8XVORL0kjSRcr68NqsIVfK+JUpcsbal3fMJOkFK84QCxTp7m+7vKdhV/zRaKYO8 UJSpN0GiqjYAgwv1C3Lv09fgF90GP0hUbWtRyBYM/qhRIKJ+27+hf6UkZHPb8ZoA9xGX R8c42evWn2Rt5655QN7u1eN3JMSnDhnJh+vUPYfCnWM8H4ZfyvnkngNIOZKbPkM6bDZc Gmww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1762835492; x=1763440292; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=X7TsDK2dJQ+FDS4HTKGVeDzd4T3lq3yW0aViulRBaHY=; b=jq2u56Lht6NjZ7nzpUa7lBITrJk5oUTJckOSTvzxT0Ym+DuW+VQXLvhTEhF1BS9b0z eOeY11lUdiTdm+yGCL7VulOPz/hRTPf8akvcGyUg3i7lrknp937l6Xb0+hs/aAGqZRRb A1WKbC4AkYlOlZkhYfHmYfxpX5hdCNHj2AMXT07y4TK3jVIwGdaBxiPcIMd8hMqSB9c1 VPV24J6O7S/0YgTl2ApeNcWTTKJHE/hTmKT39FEKdqShVI5thQ6d1bZQwrqSzxL3uoa0 th6hTEXtMiG5INAlykmfA56TIHx341G8XzSZXULInga6IqfSHHDoR+m07MZwkJPU5V+c +nsw== X-Gm-Message-State: AOJu0Yyb2k3ovlB7e/VhRBmOrhdiPIMnm+qR+GV44PNzENLCLUUrQqiM PT5DDEkySS2xeg7DmKgRNiCaJztCAIXtx1iDIQvgjrz1qh0Uw6CptLGUSUOTMIbr2v4= X-Gm-Gg: ASbGncsJjuksRbFuTiSqJSb79B/i86Xw8jsTvGsdL7jVfWejXSykBfC0msYHalateqP OUoFoVNqpQZWtHeccBP9edi8wZIt3jmvkM7fKOIdmb9eg7evbOLDe/jZjb22UqFt/UiJUuj5swV oa2fW/baxv0y3ouyVgDU2o3Hqbms1f2PJ5DiHgB9HlnQZJv4fWgWNb9l3/L1OQ1eZZfNrp159o+ yA9Q4UPbIMZAXEr5CRjZ+BlVxo/k0TkmM6B2ONdx3obV3xZPaLP9Ne4d+pT7hKGo/3+cM9xjT42 iM3IIfpEPo5nzom5nPvXWR2jXLIf8w0LLWT/ohs47p7tO0m3yW+O5GLxoNVt6q2Zh5Zg8W+CWfu SxlcUZ3rtaD37AJCHGhsfBcf7sVD8Gu7yMjq5UAwL17V7r4dxQVxQS6sybL2p3/T0Ls8zLCd+O2 kbTamaCv//kxpMRxrzDDiuIqafuxLWgzWhdkdOLtzRxfa6gVszUUz9YH4dI16P3w== X-Google-Smtp-Source: AGHT+IF1qq8ITE7JtiF8qOmRab9Vy4hos1i2OAb1dg9GA7p16PLNdUjd02kuiflULkEs4iX3wNd6Rg== X-Received: by 2002:a17:903:19c8:b0:295:6a9:cb62 with SMTP id d9443c01a7336-297e56be1b5mr152389505ad.35.1762835492366; Mon, 10 Nov 2025 20:31:32 -0800 (PST) Received: from apollo.tail3ccdd3.ts.net ([2601:646:8201:fd20::888a]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-29651ca1b8csm167771415ad.85.2025.11.10.20.31.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Nov 2025 20:31:31 -0800 (PST) From: Khem Raj To: openembedded-devel@lists.openembedded.org Cc: Khem Raj Subject: [meta-oe][PATCH 2/4] packagegroup-meta-oe: Enable heaptrack on riscv64 Date: Mon, 10 Nov 2025 20:31:25 -0800 Message-ID: <20251111043128.3063095-2-raj.khem@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251111043128.3063095-1-raj.khem@gmail.com> References: <20251111043128.3063095-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 11 Nov 2025 04:31:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121475 Signed-off-by: Khem Raj --- meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb b/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb index 0458662f97..d7d6c08693 100644 --- a/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb +++ b/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb @@ -311,7 +311,7 @@ RDEPENDS:packagegroup-meta-oe-devtools:remove:mips64el = "luajit nodejs" RDEPENDS:packagegroup-meta-oe-devtools:remove:powerpc = "android-tools breakpad lshw luajit uftrace" RDEPENDS:packagegroup-meta-oe-devtools:remove:powerpc64 = "android-tools breakpad lshw luajit ply uftrace" RDEPENDS:packagegroup-meta-oe-devtools:remove:powerpc64le = "android-tools breakpad lshw luajit ply uftrace" -RDEPENDS:packagegroup-meta-oe-devtools:remove:riscv64 = "breakpad concurrencykit heaptrack lshw ltrace luajit nodejs ply" +RDEPENDS:packagegroup-meta-oe-devtools:remove:riscv64 = "breakpad concurrencykit lshw ltrace luajit nodejs ply" RDEPENDS:packagegroup-meta-oe-devtools:remove:riscv32 = "breakpad concurrencykit heaptrack lshw ltrace luajit nodejs ply uftrace" RDEPENDS:packagegroup-meta-oe-devtools:remove:libc-musl:riscv32 = "php" RDEPENDS:packagegroup-meta-oe-devtools:remove:aarch64 = "concurrencykit" From patchwork Tue Nov 11 04:31:26 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 74134 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 65FC2CCFA1E for ; Tue, 11 Nov 2025 04:31:35 +0000 (UTC) Received: from mail-pl1-f177.google.com (mail-pl1-f177.google.com [209.85.214.177]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.10091.1762835494357748431 for ; Mon, 10 Nov 2025 20:31:34 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=lpbqkuiK; spf=pass (domain: gmail.com, ip: 209.85.214.177, mailfrom: raj.khem@gmail.com) Received: by mail-pl1-f177.google.com with SMTP id d9443c01a7336-295ceaf8dacso38823105ad.0 for ; Mon, 10 Nov 2025 20:31:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1762835493; x=1763440293; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qgaISQU6anN6Ruwunmnt6Hnp2Pj/PKdDwyNMvsZ4D8s=; b=lpbqkuiKkNCGppqvciG9wnjE90pIOn939E3nmdG7R6Sr7Jgyfpi6UNf6aCkPiDTaZ1 V+kxZ9Yh07IhXa9ZANIHAvE/9cuQBrPtShVwOMoBT/ai+R13fZVuwqaHrtSxLEbc2Drl KkL4/fON2nUjoSoWSY8yzZWYwxgcJqnAw2n8pQYGB6Ecehwh6h4f3stqRleY/fRc9RHb WymM7mgrFm5YA6/6/of+lLv1Wd5H/NqKbBQodCaozaUVgD2hII/QpkxDHVlBsJx8Q6SR YOdVH979rFViIdH+03WSRs4wdrHxv+am5B5S7RRYrZGfCFKYkgB76uhU12Kj4Ls2xP3j LWMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1762835493; x=1763440293; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=qgaISQU6anN6Ruwunmnt6Hnp2Pj/PKdDwyNMvsZ4D8s=; b=BQx1I8Nf06wROhAwpCLWi5LlkSkxjNEanSVbbyYyb0IDPuWlcegYS/adncHbN5cG/T 6TSfylazmo0R9aC8Gne8SnU3Sxt1QkoEC80ZZmYDOtIdkk/WNP5t+wp+x3FsttBGGP9a L9Pzx4rcypPbzHV8N2utbTPa7bYiXIk6BW6ReZTMoV1gC9DYxiiZe6skRIbzt2Pojy2a eam2DWlMJp2G7d+JmLKR/+VRln5edW/U9M4QZJ0WEtQHcBWxvtHugmFZ5xqY0OF265XJ Qe44FTFuJ6VE/F3w1+3qRuYmmKITrE76k3xjyL1zCEb7NfGv7czMGVYAHglFQbilsfN8 prZg== X-Gm-Message-State: AOJu0YynDSnoQ1qC1a/be23rymYejE5L75eG+U3pQDQVVeIdEFjfbhK7 aRTRUKMkqMz8pj/hERc7JcrPnb4cr9QX0sK8m21ytkZx1lYpwZz2p1h/6QSu5T6AHmc= X-Gm-Gg: ASbGnctNAcn5MN1AP3HR4CCtahPxs5PJI9WNYRDuX+P3hSL+JO9Dq+OLZPtwjXcs3gL 05PJRvnAxeaw/YaDB0cH968B46knUswN8MIc242pvL2Pev0ZQudLpq6vEsJjOk1C3C/JpLhzltj 4sgWxY+yg9ybfnxeFbuDfEQhchfT8H27LdwsC190KFX1wA2YhTdZse1ND6p2TTSJfRIUv4o993k UTa70yTuePXhg+FcmifymOjxxaoEM84eL5laoNTjx5BQVEcu33/25FEYmYqAmLn0DYEXq4IA4d/ RtDusz7UXNzwjSZEfGh0GjxUCRBSzO8j4Jd/4iqGLU/aExYEXKIl7pz2YcquGcFfE/0KLoCMT2B wpjsyO6eO00gwqqipjYH6Jekj+ttZIwo4bbNLFXHJoqCv6mt+dF7cOA4IjzCAbI91FkegjbKaEH sIsWNPs9RhaMMJq7tXQYD3kl3N9Itw8xEO8AgsctlY960G1ngWyziDdNMzRl4+2I1TBHAoEbGO X-Google-Smtp-Source: AGHT+IGt1eWC/gr3TKTnnotkl9JTD3Frr2m94JQlierWascSWMFZu+kcB5jhwk35vREQUaugvQh8pw== X-Received: by 2002:a17:902:d491:b0:295:5668:2f27 with SMTP id d9443c01a7336-297e54131d2mr123934465ad.9.1762835493430; Mon, 10 Nov 2025 20:31:33 -0800 (PST) Received: from apollo.tail3ccdd3.ts.net ([2601:646:8201:fd20::888a]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-29651ca1b8csm167771415ad.85.2025.11.10.20.31.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Nov 2025 20:31:32 -0800 (PST) From: Khem Raj To: openembedded-devel@lists.openembedded.org Cc: Khem Raj Subject: [meta-networking][PATCH 3/4] snort3: Upgrade to 3.9.7.0 Date: Mon, 10 Nov 2025 20:31:26 -0800 Message-ID: <20251111043128.3063095-3-raj.khem@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251111043128.3063095-1-raj.khem@gmail.com> References: <20251111043128.3063095-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 11 Nov 2025 04:31:35 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121476 Fix build with C23 glibc while here Signed-off-by: Khem Raj --- .../snort/snort3/0001-Fix-build-on-c23.patch | 43 +++++++++++++++++++ .../{snort3_3.9.1.0.bb => snort3_3.9.7.0.bb} | 8 ++-- 2 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 meta-networking/recipes-connectivity/snort/snort3/0001-Fix-build-on-c23.patch rename meta-networking/recipes-connectivity/snort/{snort3_3.9.1.0.bb => snort3_3.9.7.0.bb} (85%) diff --git a/meta-networking/recipes-connectivity/snort/snort3/0001-Fix-build-on-c23.patch b/meta-networking/recipes-connectivity/snort/snort3/0001-Fix-build-on-c23.patch new file mode 100644 index 0000000000..884a4b8fe6 --- /dev/null +++ b/meta-networking/recipes-connectivity/snort/snort3/0001-Fix-build-on-c23.patch @@ -0,0 +1,43 @@ +From ae5566a7df4851bd47081ef0e00e2a0513b7f331 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Mon, 10 Nov 2025 19:41:16 -0800 +Subject: [PATCH] Fix build on c23 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +C23/glibc is now including once_init in stdlib.h + +https://patchwork.sourceware.org/project/glibc/patch/78061085-f04a-0c45-107b-5a8a15521083@redhat.com/#213088 + +This is a name collision with the new C once_flag/call_once that +glibc exposes (via ) and C++’s std::once_flag/std::call_once + +Upstream-Status: Submitted [https://github.com/snort3/snort3/pull/431] +Signed-off-by: Khem Raj +--- + src/loggers/alert_fast.cc | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/loggers/alert_fast.cc b/src/loggers/alert_fast.cc +index 7b5deab2..3f88bff6 100644 +--- a/src/loggers/alert_fast.cc ++++ b/src/loggers/alert_fast.cc +@@ -53,7 +53,7 @@ using namespace std; + #define FAST_BUF (4*K_BYTES) + + static THREAD_LOCAL TextLog* fast_log = nullptr; +-static once_flag init_flag; ++static std::once_flag init_flag; + + #define S_NAME "alert_fast" + #define F_NAME S_NAME ".txt" +@@ -319,7 +319,7 @@ void FastLogger::set_buffer_ids(Inspector* gadget) + const BufferIds& FastLogger::get_buffer_ids(Inspector* gadget, Packet* p) + { + // lazy init required because loggers don't have a configure (yet) +- call_once(init_flag, set_buffer_ids, gadget); ++ std::call_once(init_flag, set_buffer_ids, gadget); + + InspectionBuffer buf; + const std::vector& idv = diff --git a/meta-networking/recipes-connectivity/snort/snort3_3.9.1.0.bb b/meta-networking/recipes-connectivity/snort/snort3_3.9.7.0.bb similarity index 85% rename from meta-networking/recipes-connectivity/snort/snort3_3.9.1.0.bb rename to meta-networking/recipes-connectivity/snort/snort3_3.9.7.0.bb index 598b1f4dfb..64a63ce918 100644 --- a/meta-networking/recipes-connectivity/snort/snort3_3.9.1.0.bb +++ b/meta-networking/recipes-connectivity/snort/snort3_3.9.7.0.bb @@ -7,11 +7,13 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=78fa8ef966b48fbf9095e13cc92377c5" DEPENDS = "flex-native hwloc libdaq libdnet libpcap libpcre libtirpc libunwind luajit zlib" -SRC_URI = "git://github.com/snort3/snort3.git;protocol=https;branch=master \ +SRC_URI = "git://github.com/snort3/snort3.git;protocol=https;branch=master;tag=${PV} \ file://0001-cmake-Check-for-HP-libunwind.patch \ - file://0001-cmake-Pass-noline-flag-to-flex.patch" + file://0001-cmake-Pass-noline-flag-to-flex.patch \ + file://0001-Fix-build-on-c23.patch \ + " -SRCREV = "6730d53f99f3714654804d07203f33e6b1b8a107" +SRCREV = "892f9f3b04d604797851d60e89d6cfe640a047cd" PACKAGES =+ "${PN}-scripts" From patchwork Tue Nov 11 04:31:27 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 74135 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5E1A1CCF9E3 for ; Tue, 11 Nov 2025 04:31:45 +0000 (UTC) Received: from mail-pf1-f178.google.com (mail-pf1-f178.google.com [209.85.210.178]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.10238.1762835495469788121 for ; Mon, 10 Nov 2025 20:31:35 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=FU/o1jZR; spf=pass (domain: gmail.com, ip: 209.85.210.178, mailfrom: raj.khem@gmail.com) Received: by mail-pf1-f178.google.com with SMTP id d2e1a72fcca58-7aa9be9f03aso3287550b3a.2 for ; Mon, 10 Nov 2025 20:31:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1762835495; x=1763440295; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=2S6ON5jfyk1Lz2B0D+WIiy6B/Ri578mpHXAsFfWBtP0=; b=FU/o1jZRMl/MOdCGkWgiXqBc9xF6GPIFTDHZC+Ee5InZvOVdZDoQL7n5PU/NI4mL2/ G11V80Al8PYnTdod57xEOSCqC5uk/qFLSXDL4aHJMG5XP7Kkcs1j/h04LtADMmuj3tAl A5dac5Sm663sJiryQHrXddKpBo/PM3A6a/GpRQ19LnSsWAsd7ECbwiGhGFh7/zddwq3x f410BkNaFNZ6OBc7wnmMtUZ/k+U1vO8f7UI2e+7kw0uO0a1YwSViV06qz+5uM0I0EpLe 3cqDMG4LaodgaC0kB3EVD7cY7tV3wTBKs37g7glN29IPHW6W7eUN03IL5OqWXzuB0QEH eZjA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1762835495; x=1763440295; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=2S6ON5jfyk1Lz2B0D+WIiy6B/Ri578mpHXAsFfWBtP0=; b=gw3YtonMCY6CBuCjcNfvFVl45/moXmHbK3QfJXFWHyt3DyCzXNX3acETjfTw5J/4eY 5lG4F61BgLf2pMCycBkf4b02Q4XW/yWsahiOB1222Th4xs/VhzyjwLKgJ33UTkj+aWCm k5kBFtrjPkImu/a8Ce7zy9iMOk76lDMKAHEqX30RnWwL1Cm/3DPIa98hVkhI2V+YHOwz rkl3S2Iq+MQTovs6kzTiyphHHRNSkGy3Pcs192/mFY3J4ouJxhOyJmBi7+buUbyvZkGD 33/bqXrMp8ejZvQYaR7YSS+w7vPNYno0Kya8y2JwL/LpEg6kghNaXk73qmxZh9Ow4/Ii TrNQ== X-Gm-Message-State: AOJu0Yx22N4BgU0fkYS39oM1aODWxGN13lHbxD3PINANiWu8kE7gtoUw Yra/AmhQS+1clplwSoHqRpDKwzJjbOJVv2cGu0R3EDfYRHuH2ufElj/bMhHSvvza1J0= X-Gm-Gg: ASbGncvLBihHX1dfQEZ2tj60Gdy0CLW3QIVKmmDSNXSo1eqlvxEwvCoYZA+z2QZIi7Z PVX8gBVg4aljNr720USctRpgRUdKknDyXUUbhuz5HlUgow07U77dgvJkKhSfCHW2uuu9eFpaqM0 vyZHMscMWKwgEXuf0mqaTvVIFpuaC3nshlTNfBueaKGWJx4dxPjOd2tt0tZTQnbuTHI+fC+B3Px PqE/N6s/YT1cOcbFxxOcmsnagCL7HZSJalfIzCffJliPuXH/1LrC3jhSaKIU+jKPj1aYEY+YY8z mEmaFLcSvHtXcMk13IYilbIy53UEHQblmcFIhyOZJSsjpv9nytvdxVBMvvLnmjEqIxmsWyx/3Se UCWLzB7ssUiR1cvCfSAuZoE2vI+t0IjiylOP9eYJUCBzaH9kSF0E5+uuJPsfPfCogpInoyYChAZ /huqn7ChRwY3x8dcd5pVVe+DSMhlgyoCmnjY9A1AXOTW++6i/Kk7MH6+OR2IHzbWGR1x6Gf72E X-Google-Smtp-Source: AGHT+IEjG9mCO4a1Kh83cprKCeJRER+VgQU+eWcAt3ZD9LO+TrJJOW6o/F8vYu+RKVVlhWFVS31MyQ== X-Received: by 2002:a17:902:e847:b0:297:db6a:a82f with SMTP id d9443c01a7336-297e5666d10mr131724245ad.24.1762835494527; Mon, 10 Nov 2025 20:31:34 -0800 (PST) Received: from apollo.tail3ccdd3.ts.net ([2601:646:8201:fd20::888a]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-29651ca1b8csm167771415ad.85.2025.11.10.20.31.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Nov 2025 20:31:33 -0800 (PST) From: Khem Raj To: openembedded-devel@lists.openembedded.org Cc: Khem Raj Subject: [meta-networking][PATCH 4/4] libldb: Fix build with glibc 2.43 Date: Mon, 10 Nov 2025 20:31:27 -0800 Message-ID: <20251111043128.3063095-4-raj.khem@gmail.com> X-Mailer: git-send-email 2.51.2 In-Reply-To: <20251111043128.3063095-1-raj.khem@gmail.com> References: <20251111043128.3063095-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 11 Nov 2025 04:31:45 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/121477 Signed-off-by: Khem Raj --- .../libldb/libldb/c23_memset_explicit.patch | 248 ++++++++++++++++++ .../recipes-support/libldb/libldb_2.8.2.bb | 1 + 2 files changed, 249 insertions(+) create mode 100644 meta-networking/recipes-support/libldb/libldb/c23_memset_explicit.patch diff --git a/meta-networking/recipes-support/libldb/libldb/c23_memset_explicit.patch b/meta-networking/recipes-support/libldb/libldb/c23_memset_explicit.patch new file mode 100644 index 0000000000..bd817d8cf5 --- /dev/null +++ b/meta-networking/recipes-support/libldb/libldb/c23_memset_explicit.patch @@ -0,0 +1,248 @@ +C23 introduced memset_explicit with the same parameters as +memset (3 args). New glibc implements it, so the symbol now +exists in the global namespace with that prototype, causing +“too many arguments” when your code passes 4 args. + +Provide a compatibility macro to address the problem + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- a/lib/replace/replace.c ++++ b/lib/replace/replace.c +@@ -1,4 +1,4 @@ +-/* ++/* + Unix SMB/CIFS implementation. + replacement routines for broken systems + Copyright (C) Andrew Tridgell 1992-1998 +@@ -8,7 +8,7 @@ + ** NOTE! The following LGPL license applies to the replace + ** library. This does NOT imply that all of Samba is released + ** under the LGPL +- ++ + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either +@@ -44,6 +44,18 @@ + void replace_dummy(void); + void replace_dummy(void) {} + ++#if defined(HAVE_MEMSET_EXPLICIT) ++# define LDB_MEMSET_EXPLICIT(dest, destsz, ch, n) memset_explicit((dest),(ch),(n)) ++#elif defined(HAVE_MEMSET_S) ++# define LDB_MEMSET_EXPLICIT(dest, destsz, ch, n) memset_s((dest),(destsz),(ch),(n)) ++#else ++# define LDB_MEMSET_EXPLICIT(dest, destsz, ch, n) do { \ ++ volatile unsigned char *p = (volatile unsigned char*)(dest); \ ++ size_t _N = (n); unsigned char _CH = (unsigned char)(ch); \ ++ for (size_t _i = 0; _i < _N; ++_i) p[_i] = _CH; \ ++ } while (0) ++#endif ++ + #ifndef HAVE_FTRUNCATE + /******************************************************************* + ftruncate for operating systems that don't have it +@@ -91,7 +103,7 @@ size_t rep_strlcpy(char *d, const char * + #endif + + #ifndef HAVE_STRLCAT +-/* like strncat but does not 0 fill the buffer and always null ++/* like strncat but does not 0 fill the buffer and always null + terminates. bufsize is the length of the buffer, which should + be one more than the maximum resulting string length */ + size_t rep_strlcat(char *d, const char *s, size_t bufsize) +@@ -116,7 +128,7 @@ size_t rep_strlcat(char *d, const char * + + #ifndef HAVE_MKTIME + /******************************************************************* +-a mktime() replacement for those who don't have it - contributed by ++a mktime() replacement for those who don't have it - contributed by + C.A. Lademann + Corrections by richard.kettlewell@kewill.com + ********************************************************************/ +@@ -137,7 +149,7 @@ time_t rep_mktime(struct tm *t) + return((time_t)-1); + + n = t->tm_year + 1900 - 1; +- epoch = (t->tm_year - 70) * YEAR + ++ epoch = (t->tm_year - 70) * YEAR + + ((n / 4 - n / 100 + n / 400) - (1969 / 4 - 1969 / 100 + 1969 / 400)) * DAY; + + y = t->tm_year + 1900; +@@ -147,7 +159,7 @@ time_t rep_mktime(struct tm *t) + epoch += mon [m] * DAY; + if(m == 1 && y % 4 == 0 && (y % 100 != 0 || y % 400 == 0)) + epoch += DAY; +- ++ + if(++m > 11) { + m = 0; + y++; +@@ -156,7 +168,7 @@ time_t rep_mktime(struct tm *t) + + epoch += (t->tm_mday - 1) * DAY; + epoch += t->tm_hour * HOUR + t->tm_min * MINUTE + t->tm_sec; +- ++ + if((u = localtime(&epoch)) != NULL) { + t->tm_sec = u->tm_sec; + t->tm_min = u->tm_min; +@@ -176,7 +188,7 @@ time_t rep_mktime(struct tm *t) + + #ifndef HAVE_INITGROUPS + /**************************************************************************** +- some systems don't have an initgroups call ++ some systems don't have an initgroups call + ****************************************************************************/ + int rep_initgroups(char *name, gid_t id) + { +@@ -194,7 +206,7 @@ int rep_initgroups(char *name, gid_t id) + int i,j; + struct group *g; + char *gr; +- ++ + if((grouplst = malloc(sizeof(gid_t) * max_gr)) == NULL) { + errno = ENOMEM; + return -1; +@@ -250,9 +262,9 @@ void *rep_memmove(void *dest,const void + + if (d < s) { + /* we can forward copy */ +- if (s-d >= sizeof(int) && +- !(s%sizeof(int)) && +- !(d%sizeof(int)) && ++ if (s-d >= sizeof(int) && ++ !(s%sizeof(int)) && ++ !(d%sizeof(int)) && + !(size%sizeof(int))) { + /* do it all as words */ + int *idest = (int *)dest; +@@ -267,9 +279,9 @@ void *rep_memmove(void *dest,const void + } + } else { + /* must backward copy */ +- if (d-s >= sizeof(int) && +- !(s%sizeof(int)) && +- !(d%sizeof(int)) && ++ if (d-s >= sizeof(int) && ++ !(s%sizeof(int)) && ++ !(d%sizeof(int)) && + !(size%sizeof(int))) { + /* do it all as words */ + int *idest = (int *)dest; +@@ -281,7 +293,7 @@ void *rep_memmove(void *dest,const void + char *cdest = (char *)dest; + char *csrc = (char *)src; + for (i=size-1;i>=0;i--) cdest[i] = csrc[i]; +- } ++ } + } + return(dest); + } +@@ -334,16 +346,16 @@ void rep_vsyslog (int facility_priority, + size_t rep_strnlen(const char *s, size_t max) + { + size_t len; +- ++ + for (len = 0; len < max; len++) { + if (s[len] == '\0') { + break; + } + } +- return len; ++ return len; + } + #endif +- ++ + #ifndef HAVE_STRNDUP + /** + Some platforms don't have strndup. +@@ -351,7 +363,7 @@ void rep_vsyslog (int facility_priority, + char *rep_strndup(const char *s, size_t n) + { + char *ret; +- ++ + n = strnlen(s, n); + ret = malloc(n+1); + if (!ret) +@@ -407,7 +419,7 @@ int rep_chroot(const char *dname) + + /***************************************************************** + Possibly replace mkstemp if it is broken. +-*****************************************************************/ ++*****************************************************************/ + + #ifndef HAVE_SECURE_MKSTEMP + int rep_mkstemp(char *template) +@@ -425,7 +437,7 @@ int rep_mkstemp(char *template) + char *rep_mkdtemp(char *template) + { + char *dname; +- ++ + if ((dname = mktemp(template))) { + if (mkdir(dname, 0700) >= 0) { + return dname; +@@ -532,7 +544,7 @@ long long int rep_strtoll(const char *st + { + #ifdef HAVE_STRTOQ + return strtoq(str, endptr, base); +-#elif defined(HAVE___STRTOLL) ++#elif defined(HAVE___STRTOLL) + return __strtoll(str, endptr, base); + #elif SIZEOF_LONG == SIZEOF_LONG_LONG + return (long long int) strtol(str, endptr, base); +@@ -568,7 +580,7 @@ unsigned long long int rep_strtoull(cons + { + #ifdef HAVE_STRTOUQ + return strtouq(str, endptr, base); +-#elif defined(HAVE___STRTOULL) ++#elif defined(HAVE___STRTOULL) + return __strtoull(str, endptr, base); + #elif SIZEOF_LONG == SIZEOF_LONG_LONG + return (unsigned long long int) strtoul(str, endptr, base); +@@ -599,7 +611,7 @@ unsigned long long int rep_strtoull(cons + #endif /* HAVE_STRTOULL */ + + #ifndef HAVE_SETENV +-int rep_setenv(const char *name, const char *value, int overwrite) ++int rep_setenv(const char *name, const char *value, int overwrite) + { + char *p; + size_t l1, l2; +@@ -644,10 +656,10 @@ int rep_unsetenv(const char *name) + for (i=0;environ[i];i++) /* noop */ ; + + count=i; +- ++ + for (i=0;i