我的build.gradle
//dependencies {
compile project(':appRater')
compile project(':circularImageView')
compile project(':facebookSDK')
compile project(':paperSlidingTab')
compile project(':library')
compile project(':urlImageViewHelper')
compile project(':pullToRefreshLi')
compile project(':libraries:SlidingMenu:library')
compile files('libs/GoogleAdMobAdsSdk-6.4.1.jar')
compile files('libs/httpmime-4.2.5.jar')
compile files('libs/json-org.jar')
compile files('libs/universal-image-loader-1.9.1-with-sources.jar')
compile files('libs/WebSocket.jar')
compile files('libs/gcm.jar')
compile files('libs/applause-sdk-library-2.0.0.jar')
compile 'org.droidparts:droidparts:1.+'
compile 'joda-time:joda-time:2.3'
compile 'com.google.api-client:google-api-client:1.+'
compile 'com.google.api-client:google-api-client-android2:1.+'
compile 'com.google.http-client:google-http-client:1.+'
compile 'com.google.http-client:google-http-client-android2:1.+'
compile 'com.google.oauth-client:google-oauth-client:1.+'
compile 'com.google.code.gson:gson:2.+'
compile 'com.google.guava:guava:11.+'
compile 'com.google.http-client:google-http-client-jackson2:1.+'
compile 'com.google.protobuf:protobuf-java:2.+'
compile 'com.google.android.gms:play-services:3.+'
}
android {
compileSdkVersion 19
buildToolsVersion "19.1.0"
defaultConfig {
minSdkVersion 9
targetSdkVersion 17
}
signingConfigs {
release {
if (System.getenv("GRADLE_KEYSTORE")) {
storeFile = file(System.getenv("GRADLE_KEYSTORE"))
storePassword = System.getenv("GRADLE_KEYSTORE_PASSWORD")
keyAlias = System.getenv("GRADLE_KEY_ALIAS")
keyPassword = System.getenv("GRADLE_KEY_PASSWORD")
}
}
}
buildTypes.debug {
ext.enableCrashlytics = false
}
buildTypes.release {
debuggable false
zipAlignEnabled true
minifyEnabled false
signingConfig signingConfigs.release
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/license.txt'
exclude 'META-INF/NOTICE'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/notice.txt'
exclude 'META-INF/ASL2.0'
}
lintOptions {
checkReleaseBuilds false
// Or, if you prefer, you can continue to check for errors in release builds,
// but continue the build even when errors are found:
abortOnError false
}
}
我的错误信息是:
WarningDependency org.apache.httpcomponents:httpclient:4.0.1是 因为调试可能与内部版本冲突而被忽略 由Android提供。
请帮我解决这个问题
答案 0 :(得分:0)
您可以在模块的 build.gradle 文件中排除依赖项。
compile ('com.google.api-client:google-api-client-android2:1.+'){
exclude(group: 'com.google.android.gms:play-services', module: 'google-play-services')
}