包android.support.v7.internal.widget不存在,包AdapterViewCompat不存在

时间:2016-09-06 19:04:58

标签: java android android-studio gradle android-gradle

切换到API-24,并更新了几个Gradle依赖项后,我遇到了几个错误。我不知道会发生什么。有任何想法吗?  这是我的Build.Gradle文件:

apply plugin: 'com.android.application'
apply plugin: 'me.tatarka.retrolambda'
apply plugin: 'io.fabric'

repositories {
mavenCentral()
jcenter()
maven { url 'https://maven.fabric.io/public' }
maven { url 'https://clojars.org/repo/' }
}

android {
flavorDimensions "analytics"
useLibrary 'org.apache.http.legacy'

productFlavors {
    withAnalytics {
        dimension "analytics"
    }
    noAnalytics {
        dimension "analytics"
    }
}

lintOptions {
    checkReleaseBuilds false
    abortOnError false
    disable 'InvalidPackage'
}

compileSdkVersion 24
buildToolsVersion '23.0.3'

defaultConfig {
    applicationId "com.marlonjones.Ravynproject"
    versionCode 1
    versionName "0.1 Internal Testing"
    minSdkVersion 15
    targetSdkVersion 24
    multiDexEnabled true
}

buildTypes {
    release {
        minifyEnabled true
        shrinkResources true
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'qksms-proguard.pro'
    }
    debug {
        minifyEnabled true
        shrinkResources true
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'qksms-proguard.pro'
    }
}

compileOptions {
    // Use Java 1.7, requires minSdk 8
    sourceCompatibility JavaVersion.VERSION_1_8
    targetCompatibility JavaVersion.VERSION_1_8
}

lintOptions {
    checkReleaseBuilds false
    abortOnError false

    // Translations are crowd-sourced
    disable 'MissingTranslation'
}

}

buildscript {
repositories {
    mavenCentral()
    maven { url 'https://maven.fabric.io/public' }
}

dependencies {
    classpath 'me.tatarka:gradle-retrolambda:3.2.2'
    classpath 'io.fabric.tools:gradle:1.21.5'
    classpath 'com.android.tools.build:gradle:2.1.2'
}

}

String leakCanaryVersion = '1.4-beta2'

dependencies {
// Open source libraries
compile 'com.mcxiaoke.volley:library:1.0.19'
compile 'com.melnykov:floatingactionbutton:1.3.0'
compile 'com.pushbullet:android-extensions:1.0.4'
compile 'com.jakewharton:butterknife:7.0.1'
compile 'com.klinkerapps:android-chips:1.0.0'
compile 'com.googlecode.libphonenumber:libphonenumber:6.2'
compile 'com.nispok:snackbar:2.10.6'
compile 'com.github.lzyzsd:circleprogress:1.1.0'
debugCompile "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
releaseCompile "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
compile 'com.vdurmont:emoji-java:3.1.3'
compile 'me.leolin:ShortcutBadger:1.1.1'
compile 'com.googlecode.ez-vcard:ez-vcard:0.9.6'
compile 'com.google.code.gson:gson:2.4'
compile 'com.koushikdutta.ion:ion:1.1.7'
compile 'org.ligi:snackengage:0.4'
compile 'frankiesardo:icepick:3.2.0'
provided 'frankiesardo:icepick-processor:3.2.0'

// Google libraries
compile 'com.android.support:multidex:1.0.1'
compile 'com.android.support:appcompat-v7:24.2.0'
compile 'com.android.support:support-v13:24.2.0'
compile 'com.android.support:recyclerview-v7:24.2.0'
withAnalyticsCompile 'com.google.android.gms:play-services-analytics:9.4.0'

// External services
withAnalyticsCompile('com.crashlytics.sdk.android:crashlytics:2.5.5@aar') {
    transitive = true;
}

}

错误:包android.support.v7.internal.widget不存在且包AdapterViewCompat不存在

1 个答案:

答案 0 :(得分:0)

由于appcompat v.23.2.0 android.support.v7.internal包已被删除。

这是一个内部包,你不应该使用它。