libstdc++6-*-dbg doesn't contain gdb Python hook

Bug #883269 reported by Evan Broder
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gcc-4.4 (Ubuntu)
Invalid
Undecided
Unassigned
gcc-4.5 (Ubuntu)
Fix Released
Undecided
Unassigned
gcc-4.6 (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

libstdc++6-4.6-dbg and other -dbg packages for libstdc++ include the new Python pretty printers for debugging STL classes under gdb. However, they don't get loaded automatically, and require manually modifying gdb's python's sys.path.

The gcc-snapshot package contains /usr/lib/gcc-snapshot/lib/libstdc++.so.6.0.17-gdb.py, which causes the pretty printers to get autoloaded whenever gdb attaches to a process that links /usr/lib/gcc-snapshot/lib/libstdc++.so.6.0.17.

libstdc++6-4.6-dbg appears to lack this file (which can go either next to the original library or next to the debug symbols under /usr/lib/debug), as do the -dbg packages for libstdc++ in other gcc versions available.

In the gcc source packages, the gdb autoload file is generated in src/libstdc++-v3/python. The Makefile installs it next to the library, but I can't follow the gcc packaging well enough to suggest a patch for non-snapshot builds.

The pretty printers make a huge difference in debugging C++ code that uses STL containers. It would be very helpful if these were loaded by default for non-snapshot builds of gcc.

For other examples of auto-loaded debugging code, see python2.7-dbg (/usr/lib/debug/usr/lib/libpython2.7.so.1.0-gdb.py) and libglib2.0-dev (/usr/share/gdb/gdb/auto-load/libglib-2.0.so.0.3000.0-gdb.py and libgobject-2.0.so.0.3000.0-gdb.py)

ProblemType: Bug
DistroRelease: Ubuntu 11.10
Package: libstdc++6-4.6-dbg 4.6.1-9ubuntu3
ProcVersionSignature: Ubuntu 3.0.0-12.20-generic 3.0.4
Uname: Linux 3.0.0-12-generic x86_64
ApportVersion: 1.23-0ubuntu3
Architecture: amd64
CheckboxSubmission: d27dbc9ce66475289526ca4b283ec487
CheckboxSystem: bb422ca46d02494cdbc459927a98bc2f
Date: Fri Oct 28 13:39:36 2011
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release amd64 (20110427.1)
SourcePackage: gcc-4.6
UpgradeStatus: Upgraded to oneiric on 2011-09-18 (40 days ago)

Revision history for this message
Evan Broder (broder) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gcc-4.5 - 4.5.3-10ubuntu1

---------------
gcc-4.5 (4.5.3-10ubuntu1) precise; urgency=low

  * Merge with Debian.

gcc-4.5 (4.5.3-10) unstable; urgency=low

  * Update to SVN 20111206 (r182040) from the gcc-4_5-branch.
    - Fix PR c/50565, PR target/49965, PR target/50464, PR target/50091,
      PR c++/44473, PR fortran/50659, PR fortran/50273, PR target/51393,
      PR debug/48190, PR rtl-optimization/51187, PR target/30282,
      PR target/50979, PR target/50875, R target/50691, PR target/50788,
      PR target/50737, PR c++/50793, PR c++/50618, PR bootstrap/50888,
      PR target/50737.
  * For ARM hard float, set the dynamic linker to
    /lib/arm-linux-gnueabihf/ld-linux.so.3.
  * Install the libstdc++.so-gdb.py file. LP: #883269.
  * Update the Linaro support to the 4.5-2011.12 release.
 -- Matthias Klose <email address hidden> Tue, 06 Dec 2011 13:05:02 +0100

Changed in gcc-4.5 (Ubuntu):
status: New → Fix Released
Revision history for this message
Matthias Klose (doko) wrote :

not in gcc-4.4

Changed in gcc-4.4 (Ubuntu):
status: New → Invalid
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gcc-4.6 - 4.6.2-6ubuntu1

---------------
gcc-4.6 (4.6.2-6ubuntu1) precise; urgency=low

  * Merge with Debian.
  * Linaro GCC 4.6 2011-12 changes not yet in Ubuntu:
    - Generic tuning support for Big-endian platforms.
    - SLP support for operations with arbitrary numbers of operands.
    - SLP support for conditions.
    - Pattern recognition support in basic-block SLP.
    - Enhancements to mixed-size condition pattern recognition.
    - Unaligned block-move support for ARMv7.
    - Added Cortex-A15 integer pipeline tuning.

gcc-4.6 (4.6.2-6) unstable; urgency=low

  * Update to SVN 20111208 (r182120) from the gcc-4_6-branch.
    - Fix PR c++/51265, PR bootstrap/50888, PR target/51393 (ix86),
      PR target/51002 (AVR), PR target/51345 (AVR), PR debug/48190,
      PR fortran/50684, PR fortran/51218, PR target/50906 (closes: #650318),
      PR tree-optimization/51315 (closes: #635126), PR tree-optimization/50622,
      PR fortran/51435, PR debug/51410, PR c/51339, PR rtl-optimization/48721,
      PR middle-end/51323 (LP: #897583), PR middle-end/50074,
      PR middle-end/50074.

  [ Matthias Klose ]
  * Run the libstdc++ testsuite on all architectures again. Closes: #622699.
  * Apply proposed patch for PR target/50906 (powerpcspe only). Closes: #650318.
  * Fix PR target/49030 (ARM), taken from Linaro. Closes: #633479.
  * Fix PR target/50193 (ARM), taken from Linaro. Closes: #642127.
  * Install the libstdc++.so-gdb.py file. LP: #883269.
  * Fix PR c++/50114, backport from trunk. LP: #827806.
  * Merge changes to allow gcc-snapshot cross builds, taken from Linaro.
  * Update the Linaro support to the 4.6 branch.

  [ Marcin Juszkiewicz ]
  * Fix issues with gcc-snapshot cross builds.
  * Allow building Linaro binary packages in a single package.
  * Apply hardening patches for cross builds when enabled for native builds.
 -- Matthias Klose <email address hidden> Thu, 08 Dec 2011 17:17:30 +0100

Changed in gcc-4.6 (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.