-1

程序类型已经存在:android.support.v4.app.NavUtils Message{kind=ERROR, text=程序类型已经存在:

android.support.v4.app.NavUtils,sources=[未知源文件],工具名=Optional.of(D8)}

如何解决这个问题?

如果有人对这个问题的原因有任何想法,我会很感激知识的分享。谢谢!

4

1 回答 1

0

构建 gradle 项目

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

buildscript {

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



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

allprojects {
    repositories {
        google()
        jcenter()
        flatDir {
            dirs 'libs'
        }
        maven {
            url "https://maven.google.com"
        }
    }
}

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

构建 gradle 模块

apply plugin: 'com.android.application'

android {
    compileSdkVersion 26
    defaultConfig {
        applicationId "ru.startandroid.identificationtest"
        minSdkVersion 21
        targetSdkVersion 26
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
        multiDexEnabled true
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
     implementation fileTree(dir: 'libs', include: ['*.jar'])
     implementation 'com.android.support:multidex:1.0.1'
     implementation 'com.google.android.gms:play-services-ads:15.0.0'
     implementation 'com.google.android.gms:play-services-location:15.0.0'
     implementation 'com.android.support:support-v4:26.1.0'
     implementation 'com.android.support:appcompat-v7:26.1.0'
     implementation 'com.android.support.constraint:constraint-layout:1.1.0'
     implementation 'android.arch.persistence.room:runtime:1.0.0'
     testImplementation 'junit:junit:4.12'
     androidTestImplementation 'com.android.support.test:runner:1.0.1'
     androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
     implementation  'com.google.android.gms:play-services-ads:15.0.0'
     implementation 'com.squareup.picasso:picasso:2.5.2' //for Inmobi
     implementation name: 'adcolony-sdk-3.2.1', ext: 'aar'
     implementation name: 'mmedia-6.4.0', ext: 'aar'
     implementation name: 'mobvista_alphab', ext: 'aar'
     implementation name: 'mobvista_appwall', ext: 'aar'
     implementation name: 'mobvista_appwallext', ext: 'aar'
     implementation name: 'mobvista_common', ext: 'aar'
     implementation name: 'mobvista_interstitial', ext: 'aar'
     implementation name: 'mobvista_mvdownloads', ext: 'aar'
     implementation name: 'mobvista_mvjscommon', ext: 'aar'
     implementation name: 'mobvista_mvnative', ext: 'aar'
     implementation name: 'mobvista_nativeex', ext: 'aar'
     implementation name: 'mobvista_offerwall', ext: 'aar'
     implementation name: 'mobvista_playercommon', ext: 'aar'
     implementation name: 'mobvista_reward', ext: 'aar'
     implementation name: 'mobvista_videocommon', ext: 'aar'
     implementation name: 'mobvista_videofeeds', ext: 'aar'
}
于 2018-04-22T21:26:28.010 回答