关于Android系统的移植,系统无法正常安装与运行软件的问题
澳门第一娛乐城官网
澳门第一娛乐城官网
当前位置 : 澳门第一娛乐城官网 > 澳门银河官网网址

关于Android系统的移植,系统无法正常安装与运行软件的问题

大家好
我在一块板子上移植了一套安卓系统,主要移植部分是linux内核和android系统。板子搭载三星4412主控芯片,2G ram,16G INAND,使用VGA和HDMI输出。移植完成后测试系统发现有不少问题。

主要问题就是:
1.系统无法正常安装软件,对于同一款软件,有时候就能安装成功,有时候就安装失败,提示“应用程序未安装”。
2.在开启程序时程序会有一定几率出现闪退情况,有时候却能正常运行。

这些应用都是从网上下载的(主要是游戏)

LOGCAT如下
当安装失败时,LOGCAT有如下打印:

W/PackageParser 1574: Exception reading assets/fishes/fish_180.png in /data/app/vmdl791637266.tmp
W/PackageParser 1574: java.lang.SecurityException: META-INF/MANIFEST.MF has invalid digest for assets/fishes/fish_180.png in /data/app/vmdl791637266.tmp
W/PackageParser 1574:         at java.util.jar.JarVerifier.invalidDigestJarVerifier.java:131
W/PackageParser 1574:         at java.util.jar.JarVerifier.access$100JarVerifier.java:53
W/PackageParser 1574:         at java.util.jar.JarVerifier$VerifierEntry.verifyJarVerifier.java:123
W/PackageParser 1574:         at java.util.jar.JarFile$JarFileInputStream.readJarFile.java:119
W/PackageParser 1574:         at java.io.BufferedInputStream.readBufferedInputStream.java:304
W/PackageParser 1574:         at android.content.pm.PackageParser.loadCertificatesPackageParser.java:363
W/PackageParser 1574:         at android.content.pm.PackageParser.collectCertificatesPackageParser.java:550
W/PackageParser 1574:         at com.android.server.pm.PackageManagerService.installPackageLIPackageManagerService.java:6627
W/PackageParser 1574:         at com.android.server.pm.PackageManagerService.access$1500PackageManagerService.java:152
W/PackageParser 1574:         at com.android.server.pm.PackageManagerService$5.runPackageManagerService.java:5164
W/PackageParser 1574:         at android.os.Handler.handleCallbackHandler.java:605
W/PackageParser 1574:         at android.os.Handler.dispatchMessageHandler.java:92
W/PackageParser 1574:         at android.os.Looper.loopLooper.java:137
W/PackageParser 1574:         at android.os.HandlerThread.runHandlerThread.java:60
E/PackageParser 1574: Package com.vwoof.fishhunter has no certificates at entry assets/fishes/fish_180.png; ignoring!
D/dalvikvm 1574: GC_EXPLICIT freed 734K, 15% free 11607K/13575K, paused 2ms+15ms
D/InstallAppProgress 2798: Installation error code: -103

从logcat上看说是证书错误,可是若是真是证书错误的话我是无法安装程序的,可是我有时能安装成功,这是怎么回事呢?

开启程序闪退的logcat

F/libc     2309: Fatal signal 11 SIGSEGV at 0x00000004 code=1
I/DEBUG    1446: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
I/DEBUG    1446: Build fingerprint: Android/full_smdk4x12/smdk4x12:4.0.4/IMM76D/20140925.171637:eng/test-keys
I/DEBUG    1446: pid: 2309, tid: 2309  >>> org.cocos2d.fishingjoy3.qihu <<<
I/DEBUG    1446: signal 11 SIGSEGV, code 1 SEGV_MAPERR, fault addr 00000004
I/DEBUG    1446:  r0 00000000  r1 bebda0f0  r2 350073df  r3 00000000
I/DEBUG    1446:  r4 5b40ff14  r5 006ff888  r6 00000004  r7 56c27c2c
I/DEBUG    1446:  r8 bebda638  r9 56c27c1c  10 56c20e70  fp bebda56c
I/DEBUG    1446:  ip 400ca108  sp bebda540  lr 5b3d0acc  pc 5b3d37d0  cpsr 60000050
I/DEBUG    1446:  d0  00000002fffffffa  d1  3ff8000000000000
I/DEBUG    1446:  d2  0000000900000fff  d3  000000003f000000
I/DEBUG    1446:  d4  00001fff00000000  d5  0006e40000000000
I/DEBUG    1446:  d6  3ce9a1b089a02752  d7  ffffffff3f4ccccd
I/DEBUG    1446:  d8  0000000000000000  d9  0000000000000000
I/DEBUG    1446:  d10 0000000000000000  d11 0000000000000000
I/DEBUG    1446:  d12 0000000000000000  d13 0000000000000000
I/DEBUG    1446:  d14 0000000000000000  d15 0000000000000000
I/DEBUG    1446:  d16 3d66000000000000  d17 3fdffffffff82d88
I/DEBUG    1446:  d18 3fe0000000000000  d19 3fe000000003e93c
I/DEBUG    1446:  d20 3f1155e54e7e8408  d21 bebbbc6c1a570a20
I/DEBUG    1446:  d22 3ff0000000000000  d23 3fede16b9c24a98f
I/DEBUG    1446:  d24 3e66376972bea4d0  d25 3fc39a09d078c69f
I/DEBUG    1446:  d26 0000000000000000  d27 0000000000000000
I/DEBUG    1446:  d28 0000000000000000  d29 0000000000000000
I/DEBUG    1446:  d30 0000000000000000  d31 0000000000000000
I/DEBUG    1446:  scr 20000012
I/DEBUG    1446:
I/DEBUG    1446:          #00  pc 0000a7d0  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:          #01  pc 00007ac8  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:          #02  pc 0001ec30  /system/lib/libdvm.so dvmPlatformInvoke
I/DEBUG    1446:          #03  pc 00058eec  /system/lib/libdvm.so _Z16dvmCallJNIMethodPKjP6JValuePK6MethodP6Thread
I/DEBUG    1446:
I/DEBUG    1446: code around pc:
I/DEBUG    1446: 5b3d37b0 e24bd004 e8bd8800 00033fb4 e92d4800  ..K......?...H-.
I/DEBUG    1446: 5b3d37c0 e28db004 e24dd028 e50b0028 e51b3028  .....M....0..
I/DEBUG    1446: 5b3d37d0 e5933004 e50b3024 e51b3024 e5933038  .0..$0..$0..80..
I/DEBUG    1446: 5b3d37e0 e1a03103 e50b3020 e51b3024 e5933040  .1.. 0..$0..@0..
I/DEBUG    1446: 5b3d37f0 e1a03103 e50b301c e51b3024 e5933058  .1...0..$0..X0..
I/DEBUG    1446:
I/DEBUG    1446: code around lr:
I/DEBUG    1446: 5b3d0aac e51b0054 e51b104c e59f3374 e08f3003  T...L...t3...0..
I/DEBUG    1446: 5b3d0abc e1a02003 eb000dda e51b0050 eb000b3b  . ......P...;...
I/DEBUG    1446: 5b3d0acc e1a03000 e50b3048 ebfffd20 e50b0044  .0..H0.. ...D...
I/DEBUG    1446: 5b3d0adc e51b004c e51b1044 e59f3348 e08f3003  L...D...H3...0..
I/DEBUG    1446: 5b3d0aec e1a02003 eb000dce e51b0050 eb001f55  . ......P...U...
I/DEBUG    1446:
I/DEBUG    1446: stack:
I/DEBUG    1446:     bebda500  ffffff98
I/DEBUG    1446:     bebda504  00000000
I/DEBUG    1446:     bebda508  0087cd90  [heap]
I/DEBUG    1446:     bebda50c  401284a8
I/DEBUG    1446:     bebda510  008c6b50  [heap]
I/DEBUG    1446:     bebda514  008c6b58  [heap]
I/DEBUG    1446:     bebda518  bebda638  [stack]
I/DEBUG    1446:     bebda51c  350073df
I/DEBUG    1446:     bebda520  56c20e70  /data/dalvik-cache/data@app@org.cocos2d.fishingjoy3.qihu-1.apk@classes.dex
I/DEBUG    1446:     bebda524  5b40ff14  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda528  006ff888  [heap]
I/DEBUG    1446:     bebda52c  00000004
I/DEBUG    1446:     bebda530  56c27c2c
I/DEBUG    1446:     bebda534  5b3d42bc  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda538  df0027ad
I/DEBUG    1446:     bebda53c  00000000
I/DEBUG    1446: #00 bebda540  5b406e28  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda544  00000000
I/DEBUG    1446:     bebda548  a80064aa
I/DEBUG    1446:     bebda54c  3f9dc6e2
I/DEBUG    1446:     bebda550  5b40ff14  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda554  5b406e28  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda558  0a76ecb7
I/DEBUG    1446:     bebda55c  0a767b20
I/DEBUG    1446:     bebda560  a80064aa
I/DEBUG    1446:     bebda564  3f9dc6e2
I/DEBUG    1446:     bebda568  bebda62c  [stack]
I/DEBUG    1446:     bebda56c  5b3d0acc  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446: #01 bebda570  5b6fa008
I/DEBUG    1446:     bebda574  00000000
I/DEBUG    1446:     bebda578  41167d78  /dev/ashmem/dalvik-heap deleted
I/DEBUG    1446:     bebda57c  41167b78  /dev/ashmem/dalvik-heap deleted
I/DEBUG    1446:     bebda580  410e20b0  /dev/ashmem/dalvik-heap deleted
I/DEBUG    1446:     bebda584  006fc300  [heap]
I/DEBUG    1446:     bebda588  006ff888  [heap]
I/DEBUG    1446:     bebda58c  002e4e18
I/DEBUG    1446:     bebda590  0a736909
I/DEBUG    1446:     bebda594  0082f3a0  [heap]
I/DEBUG    1446:     bebda598  00892a20  [heap]
I/DEBUG    1446:     bebda59c  008929a0  [heap]
I/DEBUG    1446:     bebda5a0  0a736a26
I/DEBUG    1446:     bebda5a4  5b6fa008
I/DEBUG    1446:     bebda5a8  5b6fa008
I/DEBUG    1446:     bebda5ac  0082fd10  [heap]
I/DEBUG    1446:     bebda5b0  5b6fa008
I/DEBUG    1446:     bebda5b4  5b6fa008
I/DEBUG    1446:     bebda5b8  008c6b50  [heap]
I/DEBUG    1446:     bebda5bc  5b406d90  /data/data/org.cocos2d.fishingjoy3.qihu/lib/libchaosvmp.so
I/DEBUG    1446:     bebda5c0  5b6fa008
I/DEBUG    1446:     bebda5c4  0a767ae1
I/DEBUG    1446:     bebda5c8  408bcf90  /system/lib/libdvm.so
I/DEBUG    1446:     bebda5cc  0082fe08  [heap]
I/DEBUG    1446:     bebda5d0  00892998  [heap]
I/DEBUG    1446:     bebda5d4  5b6fa008
I/DEBUG    1446:     bebda5d8  0a767b20
I/DEBUG    1446:     bebda5dc  00000000
I/DEBUG    1446:     bebda5e0  0a76ecb7
I/DEBUG    1446:     bebda5e4  00000006
I/DEBUG    1446:     bebda5e8  56c27b74
I/DEBUG    1446:     bebda5ec  400f5ac9  /system/lib/libc.so
I/DEBUG    1446:     bebda5f0  008929a0  [heap]
I/DEBUG    1446:     bebda5f4  00000000
I/DEBUG    1446:     bebda5f8  006ff898  [heap]
I/DEBUG    1446:     bebda5fc  bebda61c  [stack]
I/DEBUG    1446:     bebda600  410c77d0  /dev/ashmem/dalvik-heap deleted
I/DEBUG    1446:     bebda604  00000006
I/DEBUG    1446:     bebda608  56c27b74
I/DEBUG    1446:     bebda60c  400f612b  /system/lib/libc.so
I/DEBUG    1446:     bebda610  008929a0  [heap]
I/DEBUG    1446:     bebda614  4087cbcb  /system/lib/libdvm.so
I/DEBUG    1446:     bebda618  56c27b88
I/DEBUG    1446:     bebda61c  00000000
I/DEBUG    1446:     bebda620  410c77d0  /dev/ashmem/dalvik-heap deleted
I/DEBUG    1446:     bebda624  56f0a730  /dev/ashmem/dalvik-LinearAlloc deleted
I/DEBUG    1446:     bebda628  bebda64c  [stack]
I/DEBUG    1446:     bebda62c  40828c34  /system/lib/libdvm.so
I/BootReceiver 1555: Copying /data/tombstones/tombstone_03 to DropBox SYSTEM_TOMBSTONE
I/ActivityManager 1555: Process org.cocos2d.fishingjoy3.qihu pid 2309 has died.
D/Zygote   1448: Process 2309 terminated by signal 11
W/ActivityManager 1555: Force removing ActivityRecord{41242dd8 org.cocos2d.fishingjoy3.qihu/org.cocos2d.fishingjoy3.FishingJoy3Activity}: app died, no saved state

从网上搜到的相关资料说这是jni crash, 这样的情况也是偶尔发生,有时能打开程序,有时就一打开程序就闪退。

找了很多资料,发现他们都是从应用开始排错的。可是我安装的这些应用都是从网上下的,既然别人能正常运行,那为什么我的系统就不能正常运行呢。

我认为这是因为系统出现的内存泄露而导致的应用崩溃,但是触发错误的不是因为应用程序,而是因为我移植的系统的不稳定而导致了内存泄露。

安卓系统的代码量十分庞大,一时间我不知道从何下手。这个问题已经困扰我2个多星期了,我一直没能解决,希望大家能帮我分析一下,谢谢!

这种问题最难弄了,都不知道从哪里下手。。。

广告位

澳门第一娛乐城官网