Android: Difference between revisions

40 bytes added ,  16 December 2009
make pretty
(Make setting up gdb debugging easier)
(make pretty)
Line 175: Line 175:
== Debugging with gdb ==
== Debugging with gdb ==


=== Preparation ===
The images included with the SDK for emulation are [http://www.yaffs.net/ yaffs2] images and require some work to mount and extract files from. An alternative is to just copy the necessary files from your device via adb pull. /system/bin/linker is referred to by absolute path so setting solib-absolute-prefix in gdb will be necessary for it to be found. Other files can be placed anywhere as long as they can be found in solib-search-path.
The images included with the SDK for emulation are [http://www.yaffs.net/ yaffs2] images and require some work to mount and extract files from. An alternative is to just copy the necessary files from your device via adb pull. /system/bin/linker is referred to by absolute path so setting solib-absolute-prefix in gdb will be necessary for it to be found. Other files can be placed anywhere as long as they can be found in solib-search-path.


Line 187: Line 188:


Alternately, unpack the system image of your device somewhere. (eg. signed-dream_devphone_userdebug-ota-14721.zip)
Alternately, unpack the system image of your device somewhere. (eg. signed-dream_devphone_userdebug-ota-14721.zip)
=== Attach gdb ===


* Forward a port for gdb between your device and computer using adb. Any port you can open should work. 1234 is used here.
* Forward a port for gdb between your device and computer using adb. Any port you can open should work. 1234 is used here.
134

edits