jtaylor points out on IRC that fixing the syntax with 2to3 is
insufficient to make this actually work.
Test case:
$ sudo apt-get install python3-dbg gdb
$ 2to3 /usr/lib/debug/usr/bin/python3.3m-gdb.py > /tmp/python-gdb.patch
$ cd / && sudo patch -p0 < /tmp/python-gdb.patch
$ gdb --args python3-dbg /usr/bin/lsb_release
(gdb) break PyTuple_Size
(gdb) run
(gdb) bt
With gdb compiled for python3, instead of getting useful python
information in the backtrace, you get python exceptions:
(gdb) bt
#0 PyTuple_Size (
op=(None, <code at remote 0x7ffff7fe8340>,
'_make_relax_case.<locals>._relax_case', <code at remote 0x7ffff7fe8400>)) at
../Objects/tupleobject.c:127
#1 0x00000000006567c0 in PyFunction_NewWithQualName (
Python Exception <class 'AttributeError'> 'PyDictObjectPtr' object has no
attribute 'items':
code=<code at remote 0x7ffff7fe84c0>, globals=,
qualname='_make_relax_case') at ../Objects/funcobject.c:29
Python Exception <class 'TypeError'> 'gdb.Value' object cannot be interpreted
as an integer:
<snip>
so this seems to need some further help.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1241668
Title:
gdb embeds python3.3, but support scripts are not compatible
To manage notifications about this bug go to:
https://bugs.launchpad.net/python/+bug/1241668/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs