2
我一直在使用AS 1.4很長一段時間,新的本機調試功能特別有用。Android Studio 1.4無法啓動調試服務器
但是,本機調試不適用於我的Samsung Galaxy Note 10.1 2014(Android 4.4)。當我嘗試啓動本機調試會話我看到以下消息:
Starting LLDB server: run-as com.example.hellojni /data/data/com.example.hellojni/lldb/bin/start_lldb_server.sh /data/data/com.example.hellojni/lldb /data/data/com.example.hellojni/lldb/tmp/platform.port1445003703353 "lldb process:gdb-remote packets"
Error while launching debug server on device: com.android.tools.ndk.run.DebuggerContext$StartServerException: java.lang.IllegalStateException:
Failed to read platform port /data/data/com.example.hellojni/lldb/tmp/platform.port1445003703353
有沒有辦法解決這個問題的方法嗎?
我試過了,它沒有幫助。我設法改變run-as的權限:'-rwsr-x --- root shell 9500 2015-03-25 21:42 run-as',但我現在收到完全相同的錯誤信息。 –
我應該嘗試你建議的第二種方法。你知道在哪裏可以找到關於'Runtime.exec()'方法的更多細節嗎? –
本文非常好,並深入介紹了該過程:http://ian-ni-lewis.blogspot.co.il/2011/05/ndk-debugging-without-root-access.htm。它有點老,講的是gdb,但它今天仍然非常有用。 –