[Bug 1258642] [NEW] gdb: Python 3 incompatible with libstdc++ pretty printers.

Rüdiger Sonderfeld ruediger at c-plusplus.de
Fri Dec 6 20:49:01 UTC 2013


Public bug reported:

gdb is now linked against python 3 but python 3 is incompatible with
libstdc++'s pretty printers:

Traceback (most recent call last):
  File "<string>", line 4, in <module>
  File "/usr/share/gcc-4.8/python/libstdcxx/v6/printers.py", line 54
    raise ValueError, "Cannot find type %s::%s" % (str(orig), name)
                    ^
SyntaxError: invalid syntax
/home/ruediger/.gdbinit:7: Error in sourced command file:
Error while executing Python code.

There is a proposed patch but it wasn't upstreamed yet: http://www.mail-
archive.com/gcc-patches at gcc.gnu.org/msg65185.html

I'd propose either to continue using python2 for gdb, fixing the details
to get the patch upstream, or use a patched version downstream for now.

** Affects: gdb (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to gdb in Ubuntu.
https://bugs.launchpad.net/bugs/1258642

Title:
  gdb: Python 3 incompatible with libstdc++ pretty printers.

Status in “gdb” package in Ubuntu:
  New

Bug description:
  gdb is now linked against python 3 but python 3 is incompatible with
  libstdc++'s pretty printers:

  Traceback (most recent call last):
    File "<string>", line 4, in <module>
    File "/usr/share/gcc-4.8/python/libstdcxx/v6/printers.py", line 54
      raise ValueError, "Cannot find type %s::%s" % (str(orig), name)
                      ^
  SyntaxError: invalid syntax
  /home/ruediger/.gdbinit:7: Error in sourced command file:
  Error while executing Python code.

  There is a proposed patch but it wasn't upstreamed yet: http://www
  .mail-archive.com/gcc-patches at gcc.gnu.org/msg65185.html

  I'd propose either to continue using python2 for gdb, fixing the
  details to get the patch upstream, or use a patched version downstream
  for now.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdb/+bug/1258642/+subscriptions



More information about the foundations-bugs mailing list