无法解决:com.android.support:support-v4:27.1.1。当我添加graphview依赖项时,会发生此错误

时间:2018-11-06 11:40:57

标签: android android-studio gradle android-gradle

我在studio中有一个gradle。它可以正常工作,但是当我尝试添加graphView的新依赖项(编译'com.jjoe64:graphview:4.2.2')时,它给我带来了无法解决错误的问题。 这是我的礼物:

 // Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.2.3'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        jcenter()
        mavenLocal()
        maven { url "https://jitpack.io" }

    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

这是模块gradle:

   apply plugin: 'com.android.application'

android {
    compileSdkVersion 26
    buildToolsVersion "28.0.1"
    defaultConfig {
        applicationId "com.example.yawarabbas.gymcoach_app"
        minSdkVersion 15
        targetSdkVersion 26
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

        multiDexEnabled true //important
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }

    dexOptions {
        javaMaxHeapSize "4g"
    }
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile 'com.android.support:appcompat-v7:26.0.0-alpha1'
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:recyclerview-v7:26.0.0-alpha1'
    compile 'com.android.support:design:26.0.0-alpha1'
    compile 'com.android.support:support-core-ui:26.0.0-alpha1'
    compile 'com.github.bumptech.glide:glide:3.7.0'
    compile 'com.romandanylyk:pageindicatorview:1.0.2'
    compile 'com.google.code.gson:gson:2.4'
    compile 'pl.droidsonroids.gif:android-gif-drawable:1.2.15'
    compile 'com.github.HotBitmapGG:RingProgressBar:V1.2.3'
    compile 'com.jjoe64:graphview:4.2.2'
}

如何解决?我已经阅读了许多解决方案,但是它不起作用。

0 个答案:

没有答案