Code::Blocks Forums
User forums => Using Code::Blocks => Topic started by: MyMindsAvatar on October 31, 2010, 09:29:55 am
-
Hi everyone,
I currently running C::B svn 6784 on Ubuntu Lucid Lynx with a wxWidgets GUI (v2.9.1), but I need some help configuring the default debugger (GNU gdb (GDB) 7.1-ubuntu) to display the wx objects in a more meaningful way. I'm assuming this is a configuration issue because I can find most of the information I'm after but through various class members (e.g. the value held in a wxString variable is found in _M_p in _M_dataplus in m_impl), rather than just being displayed as "text".
If anyone can offer any advice on how to get the correct display of variable information, I would be very grateful.
Many thanks,
Richard ~
-
You can try to use the wx python scripts for gdb, but you should comment the wx functions from the gdb_types.script file in the codeblocks distribution.
-
Thanks oBFusCATed. I tried editing the dgb_types.script file but it didn't appear to have the any effect. I don't know how to try the wx python scripts suggestion in favour of what I'm currently using, so anything more on that would great.
I was wondering if this is because 2.9.1 is a developmental release and the string handling has been updated with better Unicode support, cf. 2.8.11 (current stable release)? Could this be a part of it, do you think?
Many thanks,
Richard ~
-
Yes, I think they've modified the internals of wxString in 2.9+, so the scripts coming with C::B aren't working...
You should remove the functions that register wxString parsing in C::B.
Then this might help: http://wxwidgets.blogspot.com/2009/01/pretty-printing-wxstuff-in-gdb.html
-
Thanks again oBFusCATed. I've commented out the wxString section from the gdb_types.script (C::B scripts), and have found the print.py file in my wx folder (as indicated by your pretty-printing link). Only thing is, it looks like it should work (contains all the right "paths") but I'm not convinced it's being loaded...how would I check this?
Richard ~
-
Probably this could help: http://tromey.com/blog/?p=524
Or read in the gdb docs, there should be something in it...
Also you need gdb compiled with --enable-python
-
Probably this could help: http://tromey.com/blog/?p=524
Or read in the gdb docs, there should be something in it...
Also you need gdb compiled with --enable-python
http://code.google.com/p/qp-gcc/wiki/GDB
and there is a python wx script support for gdb in the package.