码迷,mamicode.com
首页 > 移动开发 > 详细

Android 单独生成apk

时间:2017-08-08 19:54:59      阅读:207      评论:0      收藏:0      [点我收藏+]

标签:dir   ble   value   解决办法   hlist   error:   base   cep   image   

/*********************************************************************
 *                   Android 单独生成apk
 * 说明:
 *     之前使用的apk都是在调试模式下直接生成的,结果这次也不知道哪里出问题
 * 调试产生的apk总是报下面的错误,于是单独产生apk来解决。
 *
 *                                   2017-8-8 深圳 龙华樟坑村 曾剑锋
 ********************************************************************/

一、错误信息:
    I/InstantRun(26932): starting instant run server: is main process
    D/AndroidRuntime(26932): Shutting down VM
    E/AndroidRuntime(26932): FATAL EXCEPTION: main
    E/AndroidRuntime(26932): Process: com.android.aplex.wachendorffbringup, PID: 269 32
    E/AndroidRuntime(26932): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.android.aplex.wachendorffbringup/com.android.aplex.wachendorffbringup.MainActivity}: java.lang.ClassNotFoundException: Didnt find class "com.android.aplex.wachendorffbringup.MainActivity" on path: DexPathList[[zip file "/data/app/com.android.aplex.wachendorffbringup-1/base.apk"],nativeLibraryDirectories=[/data/app/com.android.aplex.wachendorffbringup-1/lib/arm, /vendor/lib,/system/lib]]
    E/AndroidRuntime(26932):        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2236)
    E/AndroidRuntime(26932):        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2387)
    E/AndroidRuntime(26932):        at android.app.ActivityThread.access$800(ActivityThread.java:151)
    E/AndroidRuntime(26932):        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1303)
    E/AndroidRuntime(26932):        at android.os.Handler.dispatchMessage(Handler.java:102)
    E/AndroidRuntime(26932):        at android.os.Looper.loop(Looper.java:135)
    E/AndroidRuntime(26932):        at android.app.ActivityThread.main(ActivityThread.java:5254)
    E/AndroidRuntime(26932):        at java.lang.reflect.Method.invoke(Native Method)
    E/AndroidRuntime(26932):        at java.lang.reflect.Method.invoke(Method.java:372)
    E/AndroidRuntime(26932):        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
    E/AndroidRuntime(26932):        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
    E/AndroidRuntime(26932): Caused by: java.lang.ClassNotFoundException: Didnt find class "com.android.aplex.wachendorffbringup.MainActivity" on path: DexPathList
    [[zip file "/data/app/com.android.aplex.wachendorffbringup-1/base.apk"],nativeLibraryDirectories=[/data/app/com.android.aplex.wachendorffbringup-1/lib/arm, /vendor/lib, /system/lib]]
    E/AndroidRuntime(26932):        at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    E/AndroidRuntime(26932):        at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
    E/AndroidRuntime(26932):        at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
    E/AndroidRuntime(26932):        at android.app.Instrumentation.newActivity(Instrumentation.java:1066)
    E/AndroidRuntime(26932):        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2226)
    E/AndroidRuntime(26932):        ... 10 more
    E/AndroidRuntime(26932):        Suppressed: java.lang.ClassNotFoundException: com.android.aplex.wachendorffbringup.MainActivity
    E/AndroidRuntime(26932):                at java.lang.Class.classForName(Native Method)
    E/AndroidRuntime(26932):                at java.lang.BootClassLoader.findClass(ClassLoader.java:781)
    E/AndroidRuntime(26932):                at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)
    E/AndroidRuntime(26932):                at java.lang.ClassLoader.loadClass(ClassLoader.java:504)
    E/AndroidRuntime(26932):                ... 13 more
    E/AndroidRuntime(26932):        Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack available
    W/ActivityManager(  401):   Force finishing activity 1 com.android.aplex.wachendorffbringup/.MainActivity
    I/OpenGLRenderer(  401): Initialized EGL, version 1.4
    E/BufferQueueProducer(  121): [Application Error: com.android.aplex.wachendorffbringup] dequeueBuffer: cant dequeue multiple buffers without setting the buffer
     count
    W/ActivityManager(  401): Activity pause timeout for ActivityRecord{7de90ed u0 com.android.aplex.wachendorffbringup/.MainActivity t39 f}
    I/OpenGLRenderer( 1010): Initialized EGL, version 1.4
    E/BufferQueueProducer(  121): [com.android.launcher/com.android.launcher2.Launcher] dequeueBuffer: cant dequeue multiple buffers without setting the buffer cou
    nt
    W/ResourceType(  759): No package identifier when getting value for resource number 0x00000000

二、解决办法,单独生产apk:

技术分享

Android 单独生成apk

标签:dir   ble   value   解决办法   hlist   error:   base   cep   image   

原文地址:http://www.cnblogs.com/zengjfgit/p/7308035.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!