I’ve built the gdb 7.4.1 for Android (applied Android patches from ndk-r8 and configured it for arm-linux-androideabi). It works fine on some devices, but on some other it refuses to set breakpoints reporting “cannot access memory”.
I used the original gdbserver from the NDK assuming that the protocol is compatible.
Has anyone run into similar problems? Do I need to build the gdbserver from 7.4.1 sources as well? Or am I missing some external patches?
Just solved it. Apparently, the gdbserver provided with Android NDK r8 is not fully compatible with gdb 7.4.1. Building gdbserver from sources and replacing the NDK one solves the problem completely.