NDK-GDB失败消息:无效的属性名称:包 [英] ndk-gdb fails with message: Invalid attribute name: package
问题描述
连接的Nexus One到Mac运行雪豹。
从Eclipse运行调试。显示执行
Connect Nexus One to Mac running Snow Leopard. Run "debug" from Eclipse. Shows the execution of
/usr/local/android-ndk-r5b/ndk-build NDK_DEBUG=1
在Nexus One上细微负载。然后我尝试运行调试器,所以我可以向JNI层:
Loads on Nexus One fine. Then I try to run the debugger so I can get to the JNI layer:
$ $NDK_DIR/ndk-gdb
这些封邮件失败:
Fails with these msgs:
Invalid attribute name:
package
Invalid attribute name:
package
Invalid attribute name:
package
ERROR: Non-debuggable application installed on the target device.
Please re-install the debuggable version!
所以,我检查了bin中的APK,它有
So I checked the apk in bin and it has
lib/armeabi/gdbserver
在NDK-DBG脚本看,这消息意味着它的失败试图找到gdbserver的手机上。于是,我就用手工做一些LS命令:
Looked at the ndk-dbg script, and this message means it's failing trying to find gdbserver on the phone. So I tried to do some ls commands by hand :
$ adb shell ls /data
opendir failed, Permission denied
所以,我看着/数据和权限是771
So I looked at /data and the permissions are 771.
我做了什么错走到这一步?
What have I done wrong to get to this point?
推荐答案
AndroidManifest.xml文件中就有一个搞乱了NDK-GDB脚本的Windows回车控制(\\ r \\ n)的。为了解决这个问题,我编辑在vi文件,做了设置文件类型= UNIX
。
The AndroidManifest.xml file had Windows carriage control (\r\n) which was messing up the ndk-gdb script. To fix this, I edited the file in vi and did a "set filetype=unix"
.
这篇关于NDK-GDB失败消息:无效的属性名称:包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!