dex

Dex Loader Unable to execute Multiple dex files define

你。 提交于 2019-11-29 22:17:55
Okay, now i'm really stuck here. I don't know what to do, where to go or ANYTHING! I have been trying to uninstall, reinstall, both SDK and Eclipse-versions, trying to Google this out, but nu-uh... Nothing!!! I CAN run my app in emulator, but i cant EXPORT it... [2011-10-07 16:35:30 - Dex Loader] Unable to execute dex: Multiple dex files define Lcom/dreamhawk/kalori/DataBaseHelper; this is dataBaseHelper package com.dreamhawk.kalori; import java.io.FileOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import android.content.Context; import

Replugin借助“UI进程”来快速释放Dex

这一生的挚爱 提交于 2019-11-29 18:06:37
public static boolean preload(PluginInfo pi) { if (pi == null) { return false; } // 借助“UI进程”来快速释放Dex(见PluginFastInstallProviderProxy的说明) return PluginFastInstallProviderProxy.install(RePluginInternal.getAppContext(), pi); } PluginFastInstallProviderProxy 的java doc中提到: Android 7.0及以上,若在UI进程中优化Dex,则比非UI进程要快4~5倍(如loan插件从4800ms到900ms) 这和“JIT/AOT”和“空闲时编译”的机制有关,参见Google官方说明,不在此赘述。 我搜了一下,还没找到上面提到的 Google官方说明 。关于和 UI线程相关 的hot code JIT编译的文章,仅仅找到了一篇 简介性文章 (第9页倒数第2段). 请问是否能提供这方面的更多信息? 来源: https://my.oschina.net/u/1446823/blog/3106328

DexIndexOverflowException: Cannot merge new index 65772 into a non-jumbo instruction!: Jumbo Mode? and/or Multi-Dex? What is behind the scene?

独自空忆成欢 提交于 2019-11-29 16:46:15
问题 I have tried to set jumboMode in gradle for my project, it seems able to solve the following DexIndexOverflowException: com.android.dex.DexException: Cannot merge new index 65536 into a non-jumbo instruction! DexIndexOverflowException: Cannot merge new index 65772 into a non-jumbo instruction! 1) What is jumboMode option actually does behind the scene? android { ... dexOptions { jumboMode true } } 2) I also notice that enabling multi-dex can solve the same problem as well, what is the right

Android: Compilation error with v7 support lib 27.1.0 “Program type already present” android.support.v7.recyclerview.extensions.ListAdapter

拥有回忆 提交于 2019-11-29 09:31:44
I think there must be a bug with the 27.1.0 v7 support lib, just released . After updating my project to use it (from 26.1.0), I keep getting this compilation error: Task :app:transformDexArchiveWithDexMergerForRegularDebug FAILED D8 is used to merge dex. Program type already present: android.support.v7.recyclerview.extensions.ListAdapter FAILURE: Build failed with an exception. What went wrong: Execution failed for task ':app:transformDexArchiveWithDexMergerForRegularDebug'. com.android.build.api.transform.TransformException: com.android.tools.r8.errors.CompilationError: Program type already

Didn't find class “android.support.multidex.MultiDexApplication” on path: DexPathList

陌路散爱 提交于 2019-11-29 02:48:50
I'm trying the new MultiDex Support on my app and so far I've managed to compile my app correctly, but when running it, I get the following exception: java.lang.RuntimeException: Unable to instantiate application android.support.multidex.MultiDexApplication: java.lang.ClassNotFoundException: Didn't find class "android.support.multidex.MultiDexApplication" on path: DexPathList[[zip file "/data/app/me.myapp.main-2.apk"],nativeLibraryDirectories=[/data/app-lib/me..main-2, /vendor/lib, /system/lib]] at android.app.LoadedApk.makeApplication(LoadedApk.java:507) at android.app.ActivityThread

Android 的 dex2jar 和 jd-gui 反编译 apk 源代码

旧巷老猫 提交于 2019-11-29 02:33:30
要得到 apk 中的源文件,可以这样: 1、把dex文件反编译为jar文件的工具。(dex2jar) http://code.google.com/p/dex2jar/downloads/list 2、把jar反编译为java的工具。(JD-GUI) http://java.decompiler.free.fr/?q=jdgui 反编译步骤 1、把 class.dex 拷贝到 dex2jar.bat 所在目录,直接拖动 class.dex 到 dex2jar.bat,生成 classes.dex.dex2jar.jar。 2、用 rar 解压出 jar 文件中的 class 文件,然后 用jad 或 DJ Java Decompiler 反编译工具将 .class 文件反编译成 .java 文件 3、运行 JD-GUI工具(绿色软件),打开上面的 jar 文件,在File下有个 Save JAR Source,它可以生成 src 源代码。 如何安装这两个工具: https://blog.csdn.net/katrinawj/article/details/80016315 来源: oschina 链接: https://my.oschina.net/u/2963604/blog/2875023

ExceptionWithContext gets thrown when trying to build an Android app with Ant

拟墨画扇 提交于 2019-11-28 23:06:56
I've tried searching around both on Google and on stackoverflow for an answer to this, but I've been unable to find anyone with the exact issue I'm having. I'm attempting to set up a continuous integration server (Bamboo, specifically) to update, build, and export an APK every time someone makes a change in source control. I'm running into the same error both on my local machine when I do every step by hand and on the server when I use the job I've set up. The error happens when I reach the dex step of the build. I've gotten the same output so far with ant debug , ant release , ant clean debug

Gradle builds really slow with a multi-project structure

自古美人都是妖i 提交于 2019-11-28 20:05:03
问题 When building with gradle on a multi-project setup containing roughly 140 projects/libraries, the build time took 1 hour and 22 minutes. And i was using --parallel . And our ANT build takes less than 20 minutes without parallel building. Here is exactly what i did. ./gradlew clean ./gradlew build --parallel I did a little testing it seems like the dexing is taking the longest amount of time. Is there a way to get the gradle process to re-use the stuff it has already dexed? If the libraries

How to convert .jar or .class to .dex file?

♀尐吖头ヾ 提交于 2019-11-28 18:22:37
I'm going to edit Opera Mini v6.5 server because it is blocked in our country. Now I have unpacked the .apk file extracted classes.Dex then converted it via dex2jar.bat, now modified the server. My problem is I want to repack the .jar or .class to classes.Dex. How do I do it? Here is a solution that was helpful in my case... Suppose .jar file sits in "c:\temp\in.jar". In command prompt window cd to ..\android-sdk\platform-tools. To get .apk execute: dx --dex --output="c:\temp\app.apk" "c:\temp\in.jar" To get .dex file execute: dx --dex --output="c:\temp\dx.dex" "c:\temp\in.jar" For mac, the dx

Error while installing application (INSTALL_FAILED_DEXOPT)

我是研究僧i 提交于 2019-11-28 13:25:46
I am working with ccr4j API in Android so when I run my project its thrown an error like: Error while installing application (INSTALL_FAILED_DEXOPT) I find from net and same site also, did all trying like, 1. Uninstalled same application from device. 2. Run Emulator with Wipe User Data. But still same error comes. So anyone know why its thrown this kind of error? This most likely has to do with the size of classes.dex. On anything pre-ICS dexopt will fail on anything over 5mb. Check the size of classes.dex in your apk. It would also be good to see what your method count is as dex has a 65536