Project

General

Profile

Bug #43

Make packages with split debug symbols

mtjm - about 12 years ago - . Updated almost 6 years ago.

Status:
fixed
Priority:
bug
Assignee:
% Done:

100%


Description

Currently we have packages without debug symbols, making debugging impossible without separately building the affected packages without stripping debug symbols. Although fixing bugs requires doing another build of the package being fixed, it's not always the package where a segfault occurs (e.g. if a program wrongly calls a function in glibc) and getting bug reports from users with useful backtraces would make fixing them easier.

Proposed change:
  • add -ggdb to the default CFLAGS in /etc/pacman.conf
  • replace strip in default /etc/makepkg.conf by another option, maybe name it split-debug
  • make makepkg make another file with debug symbols from a binary when it's enabled and put it into a package with -debug added to its name (strip's info documentation explains how the first part can be done; use objcopy's --add-gnu-debuglink option, put the debug file in $libdir/debug/${path_to_the_file})
  • document how to install these packages and how to report bugs with backtraces
Possible problems:
  • needs maintaining or upstreaming a makepkg patch
  • slower builds
  • more space will be used on repo
  • linking huge libraries like in libwebkit will fail without special ld options (or doing a cross build, or using n64 ld on a machine with more memory)
  • packages not respecting user's CFLAGS will need fixing (although they already do)
Benefits:
  • more useful bug reports
  • debugging segfaults will be less boring
  • maybe someone will fix segfaults in WebKit-based browsers
  • users will be able to more easily debug their programs using system libraries
  • maybe profilers will show more useful information

(Using the "bug" priority, since it can help fixing real bugs.)

History

#2

Updated by Anonymous almost 8 years ago

  • Project changed from 3 to Ports
#3

Updated by lukeshu about 6 years ago

  • % Done changed from 0 to 90
  • Assignee set to lukeshu
  • Status changed from open to in progress

libre/pacman 5.0.2-2.parabola2 should produce split debug packages by default

I'm leaving this at 90% for a few days, to make sure everything goes ok.

#4

Updated by lukeshu almost 6 years ago

  • % Done changed from 90 to 100

This lead too me hitting https://bugs.archlinux.org/task/59060

libre/pacman-5.1.0-2.parabola2 applies the patch that I linked to in the Arch bug.

#5

Updated by lukeshu almost 6 years ago

  • Status changed from in progress to fixed

Also available in: Atom PDF