Debug

Matt Zimmerman mdz at ubuntu.com
Tue Mar 15 12:29:13 CST 2005


On Tue, Mar 15, 2005 at 11:09:56AM -0500, dave walker wrote:

> Why is it that debugging symbols are not compiled into the packages?  I 
> have had in recent times I have been working on a project and I want to 
> see the backtrace of what was running, however all I get is (no symbol 
> defined) errors spewing from GDB.  Would it be possible to turn them on, 
> or will I just have to live in the dark?

The reason is that debug symbols consume a _huge_ amount of space (Ubuntu
would not even come close to fitting on a CD with debug symbols).

For some packages, a "-dbg" package is shipped which includes the debug
symbols so that they can be installed if desired.  However, doing this for
every package would create a huge excess of packages in the archive, and
lead to other problems.

There are various ways that we could approach the idea of providing
readily-available debug symbols:

- "Debug packs" following the same design as language packs
- On-demand debug data retrieval over the network
- Build more -dbg packages, and store them in a separate package archive

we'll discuss these ideas at UbuntuDownUnder in Sydney.  Meanwhile, the
easiest way to get debug symbols is to rebuild the package from source:

sudo apt-get build-dep <package>
DEB_BUILD_OPTIONS=nostrip fakeroot apt-get source -b <package>

-- 
 - mdz



More information about the ubuntu-devel mailing list