101
edits
MarkFinkle (talk | contribs) |
|||
| Line 175: | Line 175: | ||
Debugging with gdbserver requires root access. If you have not rooted your phone, search the web for instructions for your particular device. Or see [[User:Blassey/Notes/Android#debugging_without_rooting|notes on debugging without root access]]. | Debugging with gdbserver requires root access. If you have not rooted your phone, search the web for instructions for your particular device. Or see [[User:Blassey/Notes/Android#debugging_without_rooting|notes on debugging without root access]]. | ||
=== Using nVidia version (recommended) === | |||
Need to document here. See [[User:Blassey/Notes/Android]] for how to install. | |||
=== Using the NDK version === | |||
NOTE: Fennec might crash when attaching using the gdb binaries included in the Google NDK. nVidia's gdb binaries are better. | |||
If you do not already have gdbserver on your device (use <tt>adb shell gdbserver</tt> to check), you can push a pre-built version from the NDK. | If you do not already have gdbserver on your device (use <tt>adb shell gdbserver</tt> to check), you can push a pre-built version from the NDK. | ||
| Line 180: | Line 188: | ||
adb push /PATH/TO/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gdbserver /data/local | adb push /PATH/TO/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gdbserver /data/local | ||
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. | |||
In short, find a directory to put some libraries, make sure adb is in your path, and paste this into your terminal: | In short, find a directory to put some libraries, make sure adb is in your path, and paste this into your terminal: | ||
| Line 194: | Line 200: | ||
adb pull /system/lib/$LIB . | adb pull /system/lib/$LIB . | ||
done | done | ||
=== Attach GDB === | === Attach GDB === | ||
edits