ANDROID 65536错误
来源:互联网 发布:bms算法模块需求 编辑:程序博客网 时间:2024/06/06 03:04
先说说我的情况吧
原来项目是用eclipse开发的,出现了65536的问题,按照大神们的帖子装gradle插件啥的,最后也没搞OK。既然goodle提供了解决方案,于是就把项目搬到android studio。
目前我的环境是android studio 2.1.3,jdk 1.8。最后我的问题解决了。如果跟各位跟我的情况差不多的,希望帮到你们吧。
android studio 构建项目OK后,
在build.gradle中需要添加依赖
compile 'com.android.support:multidex:1.0.1'
需要将自己的Application继成MultiDexApplication,并添加 multiDexEnabled true
中间碰到了一些问题
1,VM with version 1.6.0 does not have multidex support
2,VM with version 2.1.0 has multidex support, MultiDex support library is disabled.
3,FragmentTabHost的问题
4,arm64-v8a的问题
下面贴出我的最终版的build.gradle
<span style="font-size:18px;">apply plugin: 'com.android.application'android { signingConfigs { config { keyAlias 'androiddebugkey' keyPassword 'android' storeFile file('D:/debug.keystore') storePassword 'android' } } compileSdkVersion 24 buildToolsVersion '24.0.1' defaultConfig { applicationId "com.xxx.xxx" minSdkVersion 15 targetSdkVersion 24 versionCode 63 versionName "2.7.8" multiDexEnabled true ndk { abiFilters "armeabi", "armeabi-v7a", "x86" } packagingOptions { exclude "arm64-v8a" } signingConfig signingConfigs.config } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro', 'proguard.cfg' ndk { abiFilters "armeabi", "armeabi-v7a", "x86" } packagingOptions { exclude "arm64-v8a" } } debug { signingConfig signingConfigs.config } } dexOptions { preDexLibraries = false javaMaxHeapSize "2g" } compileOptions { sourceCompatibility JavaVersion.VERSION_1_7 targetCompatibility JavaVersion.VERSION_1_7 } productFlavors { }}dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') testCompile 'junit:junit:4.12' compile 'com.android.support:appcompat-v7:24.2.0' compile 'com.facebook.fresco:fresco:0.9.0+' compile 'com.android.support:support-v4:24.2.0' compile 'com.android.support:multidex:1.0.1' compile project(':OneSDK')}</span>
0 0
- ANDROID 65536错误
- Android错误transformClassesWithJarMergingForUcharDev 错误
- android错误
- Android错误
- android 错误
- android 错误
- android错误
- android错误
- android 错误
- Android错误
- Android 错误
- Android错误
- 【常见错误】android常见错误
- android 之低级错误
- Android 常见错误
- android应用常见错误
- android配置的错误
- Android常见错误
- 线程池
- CSS中各个浏览器兼容的解决办法
- web第一天:html
- 使用YCSB压测Cassandra 3.7
- 前后端解决跨域请求问题
- ANDROID 65536错误
- mac安装ffmpeg
- java集群技术
- 弹出自定义右键菜单
- Codeforces Problem 711C Coloring Trees(DP)
- 测试代码
- iOS全屏滑动返回
- js中日期格式字符串转为日期对象和日期进行格式化
- SQLServer数据库驱动包的使用