void-linux / void-linux/void-packages

[RFC] libexecinfo broken on musl

Open
#41,159 10 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Shell
Stars
3.4k
Forks
2.8k
Avg merge
2d 5h
Merged PRs (30d)
299

Description

libexecinfo has the following dependents:

  • 0ad
  • CPU-X
  • Carla
  • vosk-api
  • EternalTerminal
  • antimicrox
  • llvm15
  • cabbage
  • csound
  • ddcutil
  • faust
  • flightgear
  • fontmatrix
  • fotoxx
  • freecad
  • gnome-builder
  • libreoffice
  • gzdoom
  • julius
  • libopenshot
  • llvm12: Will be removed in the llvm15 update
  • openlierox
  • osmid
  • powerpc-utils
  • pymol
  • python3-grpcio
  • qtcreator
  • remmina
  • renderdoc
  • rott
  • rust-bootstrap
  • rust
  • siril
  • srb2
  • varnish
  • virtuoso
  • vtk
  • wayfire
  • widelands
  • xournalpp
  • xrootd
  • yaz
  • yquake2

This was something noticed by sgn and I when debugging the ldc crash on musl when testing the gcc 12 update.
When a segfault occurs, instead of printing the stack trace, libexecinfo either returns 0 or segfaults. (ultimately not really accomplishing anything)

This is something that was noticed in Alpine as well:
https://gitlab.alpinelinux.org/alpine/aports/-/issues/10896

Alpine came to a decision between either fixing libexecinfo or removing it:
https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/36722

They chose the latter as they felt it wasn't useful for the end user and there was no loss of functionality vs staying with the broken libexeinfo.
https://gitlab.alpinelinux.org/alpine/aports/-/commit/50795a14dee639ce2dcc836e2b2baca9bad4a1b1

There is also a fixed version libexecinfo using elfutils here:
https://git.ddd.rip/psykose/libexecinfo
I haven't tested it much, so I can't idk how well it works or if there are other considerations.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No repository files or tests are identified. Start by reproducing libexecinfo's behavior during a segfault on musl and review the linked Alpine discussions and the elfutils-based alternative. Done requires a decided path—fixing or removing libexecinfo—and evidence that the chosen approach addresses the broken stack-trace behavior.

Written by the indexing model from the issue text.

Assessment

Domain
operating-systems
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.