Hi Jim, ----- Original Message ----- > From: "Jim Chen" <[email protected]> > To: [email protected] > Sent: Monday, June 10, 2013 2:05:39 PM > Subject: [b2g] Extending Fennec GDB (JimDB) to cover B2G > > Hi all, > > I help maintain JimDB, the fork of GDB used by the Fennec team, and > I'd > like some feedback on extending JimDB to support debugging B2G. > > As a GDB fork, JimDB includes additional bug fixes and improvements > over > the GDB included in the Android toolchain (which is the GDB included > in > B2G). It also incorporates a set of Python scripts that automates > most > of the setup. For example, you can start debugging a Mochitest in one > step, by simply specifying which test and optionally what environment > variables to use. > > Here are some more information on JimDB's capabilities, > https://wiki.mozilla.org/Android/GDB and > http://www.jnchen.com/blog/2013/03/updated-jimdb > > I think a lot of JimDB's features are applicable to B2G as well, and > through Python scripts, it can potentially do more than what the > current > shell script setup is capable of. For example, the script can look > for > apps running on your device, ask which app to debug, and automate the > rest. > > However I'm not a B2G developer, so I'd like some feedback on whether > it's worthwhile to work on this project. Do you use GDB in your > workflow? Is the current GDB setup good enough? What would you like > to > be easier when debugging? Thanks for any comments! :)
We (the guys that work on platform stuff on b2g) definitely use gdb. B2G has a script, run-gdb.sh (which can be symlinked to run-ddd.sh to use the ddd debugger as a front-end UI). https://github.com/mozilla-b2g/B2G/blob/master/run-gdb.sh This happens to be written in bash, but I don't think that anybody is averse to using python. There are a few things that I think B2G probably does differently from android. We use electrolysis, so each app runs in a separate child process. We currently use a script called b2g-ps (run on the phone) to determine the pid associated with each app. We have the ability to attach to a running process. I think that most people use this technique (launch the app, determine the pid, run-gdb.sh attach PID). If we need to debug app startup, there are a couple of other techniques that can be used. So, yeah anything that can improve this is most welcome. The ability to debug tests sounds really cool. Dave Hylands _______________________________________________ dev-b2g mailing list [email protected] https://lists.mozilla.org/listinfo/dev-b2g
