GCC Newspaper
NOVEMBER 30, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
libbacktrace

libbacktrace: zstd detection failures are nonfatal for cross-target builds

Configuration of libbacktrace for cross-target builds now tolerates missing zstd library.

GCC’s zstd configuration options were being forwarded to target libraries, causing build failures for libbacktrace when zstd was not installed on the target. This change modifies the AC_ZSTD macro to accept an optional argument that makes zstd detection failures nonfatal. This allows cross-target builds of libbacktrace to succeed even without an external libzstd installation, while preserving the requirement for host and native builds.

In Details

The AC_ZSTD macro, used in libbacktrace's configure.ac, forwards zstd detection flags to the target build. This commit adds a new FAILURE_IS_FATAL argument to AC_ZSTD. For cross-target libbacktrace builds, this argument is set to false, preventing configuration failures when the host's zstd library is unavailable on the target, as external zstd is not a hard requirement for libbacktrace itself on the target.

For Context
libbacktrace
A library used by GCC to generate stack traces, typically for debugging purposes.
cross-target build
A build process where the compiler runs on one architecture (the host) but generates code for a different architecture (the target). For example, building an ARM executable on an x86-64 machine.
zstd
A fast lossless compression algorithm. GCC may use it for host tools or forward its configuration to target libraries.
AC_ZSTD
An Autoconf macro used to detect the zstd compression library and its availability. This commit modifies it to optionally control whether a failure to find zstd is considered a fatal error.
Filed Under: libbacktracebuildcross-compilationzstd