大佬教程收集整理的这篇文章主要介绍了android-support-v4.jar中的意外顶级异常,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
这似乎是android-support-v4.jar的错误.
在我的项目中,我有3个库:appcompat,facebook,google_play_services.
我的毕业文件:
> AppProject / setTings.gradle
include ':libraries:google_play_services',':libraries:appcompat',':libraries:facebook',':app'
> AppProject / build.gradle:
buildscript { repositories { mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:0.5.+' } }
> AppProject / app / build.gradle:
apply plugin: 'android' dependencies { compile project(':libraries:appcompat') compile project(':libraries:facebook') compile project(':libraries:google_play_services') compile files('libs/android-async-http-1.4.3.jar') compile files('libs/gson-2.2.4.jar') compile files('libs/libGoogleAnalyticsV2.jar') compile files('libs/universal-image-loader-1.8.4.jar') compile files('libs/urbanairship-lib-3.0.0.jar') }
> AppProject / libraries / appcompat / build.gradle:
apply plugin: 'android-library' dependencies { compile files('libs/android-support-v4.jar') compile files('libs/android-support-v7-appcompat.jar') }
> AppProject / libraries / facebook / buidle.gradle:
apply plugin: 'android-library' dependencies { compile files('libs/android-support-v4.jar') }
> AppProject / libraries / google_play_services / buidle.gradle:
apply plugin: 'android-library' dependencies { compile files('libs/google-play-services.jar') }
Output: UNEXPECTED TOP-LEVEL EXCEPTION: java.lang.IllegalArgumentexception: already added: Landroid/support/v4/app/NotificationCompatIceCreamSandwich;
你可以帮我吗?
include ':libraries:facebook',':app'
AppProject /库/ Facebook的/的build.gradle
apply plugin: 'android-library' dependencies { compile 'com.android.support:support-v4:18.0.0' }
AppProject /应用/的build.gradle
apply plugin: 'android' dependencies { compile 'com.android.support:support-v4:18.0.0' compile 'com.android.support:appcompat-v7:18.0.+' compile 'com.google.android.gms:play-services:3.1.36' compile project(':libraries:facebook') compile files('libs/android-async-http-1.4.3.jar') compile files('libs/gson-2.2.4.jar') compile files('libs/libGoogleAnalyticsV2.jar') compile files('libs/universal-image-loader-1.8.4.jar') compile files('libs/urbanairship-lib-3.0.0.jar') }
以上是大佬教程为你收集整理的android-support-v4.jar中的意外顶级异常全部内容,希望文章能够帮你解决android-support-v4.jar中的意外顶级异常所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。