Android的安装调试器处理与Eclipse项目我没有自己建 [英] Attach Android debugger to process built with Eclipse project I don't own
问题描述
我想调试对此我没有那个用来构建它原来的Eclipse项目的Android应用程序的一部分。
I would like to debug a portion of an Android application for which I do not have the original Eclipse project that was used to build it.
我已经建立了一个实现一个Android活动的.jar
文件。我使用Eclipse开发和调试它,的javac /瓶
与适当的类构建的.jar
。在的.jar
被运到一个客户,那么谁是建立在他们的应用。
I have built a .jar
file that implements an Android Activity. I use Eclipse to develop and debug it, and javac/jar
to build the .jar
with the appropriate classes. The .jar
is shipped off to a client, who then builds it into their application.
现在,他们希望我调试的东西,并已提供我自己的应用程序的apk调用 android.os.Debug.waitForDebugger()
。我没有它们的源$ C $ C或项目。我安装并运行应用程序,并在击中打电话时,我看到这个过程在Eclipse DDMS标签等待附件(它有红色的错误图标)。当我尝试在Eclipse中,单击调试所选进程按钮,附加到这个过程中,我得到这个错误信息:
Now they would like me to debug something, and have provided me a .apk for their application that calls android.os.Debug.waitForDebugger()
. I do not have their source code or project. I install and run the application, and when it hits that call, I see the process in the Eclipse DDMS tab waiting on attachment (it has the red bug icon). When I try to attach to the process in Eclipse, by clicking the "Debug the selected process" button, I get this error message:
的没有打开的项目中找到了LT&;他们的应用包名称取代。调试会话失败!的
有没有办法对我来说,附加到这个过程中,没有原始应用程序项目?如果没有,我将诉诸 android.util.Log
语句,但我宁愿没有,原因显而易见。
Is there a way for me to attach to this process, without the original application project? If not, I will resort to android.util.Log
statements, but I would rather not, for obvious reasons.
正如我上面写的,我有我自己的项目,所有的源$ C $ C用于构建的.jar
被纳入到这个应用程序。我试图在我的测试项目清单更改包名,但是这似乎并没有就改变什么像Eclipse关注。
As I wrote above, I have my own project with all the source code used to build the .jar
that was incorporated into this application. I have tried changing the package name in my test project manifest, but that does not appear to change anything as far as Eclipse is concerned.
感谢您的帮助!
推荐答案
回答我的问题 - 我创建类型的调试配置远程Java应用程序,并指定的端口显示在DDMS窗口。我想我可以使用任何兼容JDWP调试器来做到这一点。
Answering my own question -- I created a debug configuration of type Remote Java Application, and specified the port displayed in the DDMS window. I assume I could use any JDWP compliant debugger to do this.
这篇关于Android的安装调试器处理与Eclipse项目我没有自己建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!