diff --git a/platform/x11/detect.py b/platform/x11/detect.py index 98e7f164a..bbe130260 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -365,8 +365,10 @@ def configure(env): if platform.system() == "Linux": env.Append(LIBS=["dl"]) - if platform.system().find("BSD") >= 0: - env["execinfo"] = True + if not env["execinfo"] and platform.libc_ver()[0] != "glibc": + # The default crash handler depends on glibc, so if the host uses + # a different libc (BSD libc, musl), fall back to libexecinfo. + print("Note: Using `execinfo=yes` for the crash handler as required on platforms where glibc is missing.") if env["execinfo"]: env.Append(LIBS=["execinfo"])