From: Angelo Compagnucci <angelo.compagnucci@gmail.com>
To: buildroot@buildroot.org
Cc: Francis Laniel <flaniel@linux.microsoft.com>,
Angelo Compagnucci <angelo.compagnucci@gmail.com>
Subject: [Buildroot] [PATCH 3/9] package/libabseil-cpp: allow building with musl
Date: Fri, 30 Oct 2026 16:24:28 +0100 [thread overview]
Message-ID: <20261030152434.3738285-3-angelo.compagnucci@gmail.com> (raw)
In-Reply-To: <20261030152434.3738285-1-angelo.compagnucci@gmail.com>
libabseil-cpp depends on BR2_TOOLCHAIN_HAS_UCONTEXT, which is not set
for musl, as it doesn't provide the {get,make,set}context functions.
However, absl/debugging/internal/examine_stack.cc only uses the ucontext
data structures, to get the program counter from the signal context,
and never calls those functions. musl provides those data structures,
so allow building with musl.
On 32-bit powerpc, examine_stack.cc assumes the glibc layout of
mcontext_t (uc_mcontext.uc_regs), which is different with musl, so keep
it disabled there.
examine_stack.cc was build-tested with the Bootlin musl toolchains for
aarch64, armv7, i686, x86-64, m68k, mips32el, powerpc64, powerpc64le,
riscv32, riscv64, s390x and sh4, and libabseil-cpp, re2, protobuf, grpc
and webrtc-audio-processing with the aarch64 and armv7 musl toolchains.
Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
package/libabseil-cpp/Config.in | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/package/libabseil-cpp/Config.in b/package/libabseil-cpp/Config.in
index aba065fca7..ea037f5de2 100644
--- a/package/libabseil-cpp/Config.in
+++ b/package/libabseil-cpp/Config.in
@@ -13,7 +13,11 @@ config BR2_PACKAGE_LIBABSEIL_CPP_ARCH_SUPPORTS
default y if BR2_sh
default y if BR2_sparc || BR2_sparc64
default y if BR2_x86_64
- depends on BR2_TOOLCHAIN_HAS_UCONTEXT
+ # Only the ucontext data structures are used, not the
+ # {get,make,set}context functions, so musl is supported, except
+ # on 32-bit powerpc, where the glibc mcontext_t layout is assumed.
+ depends on BR2_TOOLCHAIN_HAS_UCONTEXT || BR2_TOOLCHAIN_USES_MUSL
+ depends on !(BR2_powerpc && BR2_TOOLCHAIN_USES_MUSL)
# absl/base/internal/direct_mmap.h only implements DirectMmap()
# with mmap2 for the o32 ABI on MIPS, and its 64-bit fallback
# fails to build with the n32 ABI, where long is 32-bit
--
2.34.1
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2026-10-30 15:24 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-30 15:24 [Buildroot] [PATCH 1/9] package/uthash: new package Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 2/9] package/webrtc-audio-processing: fix build with musl Angelo Compagnucci
2026-10-30 15:24 ` Angelo Compagnucci [this message]
2026-10-30 15:24 ` [Buildroot] [PATCH 4/9] package/falcosecurity-libs: bump to version 0.21.0 Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 5/9] package/sysdig: bump to version 0.41.4 Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 6/9] package/falcosecurity-libs: convert to a virtual package Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 7/9] package/sysdig: " Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 8/9] package/falcosecurity-libs: add falcosecurity-libs-legacy Angelo Compagnucci
2026-10-30 15:24 ` [Buildroot] [PATCH 9/9] package/sysdig: add sysdig-legacy Angelo Compagnucci
2026-10-30 15:58 ` [Buildroot] [PATCH 1/9] package/uthash: new package Fiona Klute via buildroot
-- strict thread matches above, loose matches on Subject: below --
2026-10-30 13:59 Angelo Compagnucci
2026-10-30 13:59 ` [Buildroot] [PATCH 3/9] package/libabseil-cpp: allow building with musl Angelo Compagnucci
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=20261030152434.3738285-3-angelo.compagnucci@gmail.com \
--to=angelo.compagnucci@gmail.com \
--cc=buildroot@buildroot.org \
--cc=flaniel@linux.microsoft.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.