是否有可能在无根通常的Android设备上启用checkjni?

时间:2012-10-26 19:57:15

标签: android android-ndk java-native-interface device adb

我想在我的Android设备上启用checkjni。但是,我无法设置stackoverflow中给出的属性,因为它们使用“su”或“root”。

我无法在没有超级用户访问权限的设备上启用checkjni吗?我希望在使用设备时在logcat上看到“checkJNI ON”

更新:当我解锁我的音轨播放应用程序的屏幕时,我从设备上获得了这些。我该如何扩展细节?我想启用每个checkjni选项。这个区块什么也没告诉我,或者是什么?

10-26 20:47:16.720: A/libc(18272): Fatal signal 11 (SIGSEGV) at 0x00000078 (code=1)



10-26 20:47:17.145: W/SurfaceView(2094): CHECK surface infomation creating=false formatChanged=false sizeChanged=false visible=false visibleChanged=true surfaceChanged=true realSizeChanged=false redrawNeeded=false left=false top=false
10-26 20:47:17.145: I/SurfaceFlinger(1903): id=1615 Removed SurfaceView idx=4 Map Size=6
10-26 20:47:17.145: D/KeyguardViewMediator(2094): setHidden false
10-26 20:47:17.145: I/SurfaceFlinger(1903): id=1615 Removed SurfaceView idx=-2 Map Size=6
10-26 20:47:17.150: D/WallpaperWidget(2094): cleanUp()
10-26 20:47:17.150: I/DEBUG(17071):          #00  pc 0007831e  /system/lib/libdvm.so (_Z13dvmImplementsPK11ClassObjectS1_)
10-26 20:47:17.150: I/DEBUG(17071):          #01  pc 000783fa  /system/lib/libdvm.so
10-26 20:47:17.150: I/DEBUG(17071):          #02  pc 00078390  /system/lib/libdvm.so (dvmInstanceofNonTrivial)
10-26 20:47:17.155: D/KeyguardUpdateMonitor(2094): handleClockVisibilityChanged()
10-26 20:47:17.155: I/DEBUG(17071):          #03  pc 00026fcc  /system/lib/libdvm.so (dvmAsmSisterStart)
10-26 20:47:17.155: D/KeyguardViewMediator(2094): adjustStatusBarLocked: mShowing=false mHidden=false isSecure=true --> flags=0x0
10-26 20:47:17.155: I/DEBUG(17071):          #04  pc 000343b0  /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
10-26 20:47:17.155: I/DEBUG(17071):          #05  pc 0006c8c6  /system/lib/libdvm.so (_Z15dvmInvokeMethodP6ObjectPK6MethodP11ArrayObjectS5_P11ClassObjectb)
10-26 20:47:17.155: I/DEBUG(17071):          #06  pc 00073eba  /system/lib/libdvm.so
10-26 20:47:17.155: I/DEBUG(17071):          #07  pc 00030bcc  /system/lib/libdvm.so
10-26 20:47:17.155: I/DEBUG(17071):          #08  pc 000343b0  /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
10-26 20:47:17.155: I/DEBUG(17071):          #09  pc 0006cb96  /system/lib/libdvm.so (_Z14dvmCallMethodVP6ThreadPK6MethodP6ObjectbP6JValueSt9__va_list)
10-26 20:47:17.155: D/KeyguardViewMediator(2094): setHidden false
10-26 20:47:17.155: I/DEBUG(17071):          #10  pc 00054ff6  /system/lib/libdvm.so
10-26 20:47:17.155: D/STATUSBAR-StatusBarManagerService(2094): manageDisableList what=0x0 pkg=android
10-26 20:47:17.160: I/DEBUG(17071):          #11  pc 00049a7a  /system/lib/libandroid_runtime.so
10-26 20:47:17.160: I/DEBUG(17071):          #12  pc 0004b362  /system/lib/libandroid_runtime.so (_ZN7android14AndroidRuntime5startEPKcS2_)
10-26 20:47:17.160: I/DEBUG(17071):          #13  pc 00008f0a  /system/bin/app_process
10-26 20:47:17.160: I/DEBUG(17071):          #14  pc 0001684c  /system/lib/libc.so (__libc_init)
10-26 20:47:17.160: I/DEBUG(17071): code around pc:
10-26 20:47:17.160: I/DEBUG(17071): 409a32fc e8bd4648 f1b883fe d1050f02 f8d9e7ee  HF..............
10-26 20:47:17.160: I/DEBUG(17071): 409a330c 6ad93000 d1f32907 f8406938 e7ef9026  .0.j.)..8i@.&...
10-26 20:47:17.160: I/DEBUG(17071): 409a331c 6f82b510 e0072300 f8546fc4 428c4033  ...o.#...oT.3@.B
10-26 20:47:17.160: I/DEBUG(17071): 409a332c 2001d101 3301e003 dbf54293 bd102000  ... ...3.B... ..
10-26 20:47:17.160: I/DEBUG(17071): 409a333c e92d4b1b 447b41f3 460e681b ea864607  .K-..A{D.h.F.F..
10-26 20:47:17.160: I/DEBUG(17071): code around lr:
10-26 20:47:17.160: I/DEBUG(17071): 409a33dc 6c93e004 bf144299 20012000 bf00bd10  ...l.B... . ....
10-26 20:47:17.160: I/DEBUG(17071): 409a33ec 6a09460a 0589b510 d5034603 f7ff4611  .F.j.....F...F..
10-26 20:47:17.160: I/DEBUG(17071): 409a33fc e01cff8f 78086981 d110285b f8906990  .....i.x[(...i..
10-26 20:47:17.160: I/DEBUG(17071): 409a340c f1bcc000 d0050f5b 428a6c99 2000bf14  ....[....l.B... 
10-26 20:47:17.160: I/DEBUG(17071): 409a341c e00c2001 6c196bd8 ffc4f7ff 4293e007  . ...k.l.......B
10-26 20:47:17.160: I/DEBUG(17071): stack:
10-26 20:47:17.160: I/DEBUG(17071):     bede46f8  bede4701  [stack]
10-26 20:47:17.160: I/DEBUG(17071):     bede46fc  409a2b5f  /system/lib/libdvm.so
10-26 20:47:17.160: I/DEBUG(17071):     bede4700  40fa0b80  /dev/ashmem/dalvik-heap (deleted)
10-26 20:47:17.160: I/DEBUG(17071):     bede4704  000000c2  
10-26 20:47:17.160: I/DEBUG(17071):     bede4708  57099d68  /dev/ashmem/dalvik-LinearAlloc (deleted)
10-26 20:47:17.160: I/DEBUG(17071):     bede470c  583a91d4  /system/framework/framework.odex
10-26 20:47:17.160: I/DEBUG(17071):     bede4710  00000000  
10-26 20:47:17.160: I/DEBUG(17071):     bede4714  00000000  
10-26 20:47:17.160: I/DEBUG(17071):     bede4718  01b31468  [heap]
10-26 20:47:17.160: I/DEBUG(17071):     bede471c  01aed2e0  [heap]
10-26 20:47:17.160: I/DEBUG(17071):     bede4720  409def9c  /system/lib/libdvm.so
10-26 20:47:17.160: I/DEBUG(17071):     bede4724  586591ec  /system/framework/framework.odex
10-26 20:47:17.160: I/DEBUG(17071):     bede4728  fffffe4c  
10-26 20:47:17.160: I/DEBUG(17071):     bede472c  4095f740  /system/lib/libdvm.so
10-26 20:47:17.160: I/DEBUG(17071):     bede4730  df0027ad  
10-26 20:47:17.160: I/DEBUG(17071):     bede4734  00000000  
10-26 20:47:17.160: I/DEBUG(17071): #00 bede4738  34000000  
10-26 20:47:17.160: I/DEBUG(17071):     bede473c  409a33ff  /system/lib/libdvm.so
10-26 20:47:17.160: I/DEBUG(17071): #01 bede4740  34000000  
10-26 20:47:17.160: I/DEBUG(17071):     bede4744  409a3395  /system/lib/libdvm.so

1 个答案:

答案 0 :(得分:0)

您应该可以在无根设备上执行adb shell setprop debug.checkjni 1。它会影响该点之后启动的所有应用,并且您应该在启动应用时在日志中看到D Late-enabling CheckJNI