添加Vokaturi时,清单合并错误

时间:2018-05-15 20:46:34

标签: android

我正在制作移动和磨损应用程序。但是,对于wear build.gradle,我遇到了这个错误:

错误:任务'执行失败':wear:processDebugManifest'。

  

清单合并失败:来自AndroidManifest.xml的属性应用程序@ theme value =(@ android:style / Theme.DeviceDefault):15:9-59       也出现在[:OpenVokaturi-3-0-android:] AndroidManifest.xml:17:9-40 value =(@ style / AppTheme)。       建议:在AndroidManifest.xml:10:5-36:19中添加'tools:replace =“android:theme”'来覆盖。   “

这是Mobile.gradle:

apply plugin: 'com.android.application'                               
android {
compileSdkVersion 26
defaultConfig {
    applicationId "chun.emotionsensor"
    minSdkVersion 25
    targetSdkVersion 26
    versionCode 1
    versionName "1.0"
    testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
wearApp project(':wear')
implementation 'com.google.android.gms:play-services-wearable:+'
compile(name: 'OpenVokaturi-3-0-android', ext: 'aar')
implementation 'com.android.support:support-annotations:27.1.1'
}

这是wear.gradle:

apply plugin: 'com.android.application'

android {
compileSdkVersion 26
defaultConfig {
    applicationId "chun.emotionsensor"
    minSdkVersion 25
    targetSdkVersion 26
    versionCode 1
    versionName "1.0"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
}

dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.google.android.support:wearable:2.3.0'
implementation 'com.google.android.gms:play-services-wearable:15.0.1'
implementation 'com.android.support:percent:26.1.0'
implementation 'com.android.support:support-v4:26.1.0'
implementation 'com.android.support:recyclerview-v7:26.1.0'
implementation 'com.android.support:wear:26.1.0'
compileOnly 'com.google.android.wearable:wearable:2.3.0'
compile(name: 'OpenVokaturi-3-0-android', ext: 'aar')

}

enter image description here

1 个答案:

答案 0 :(得分:0)

您在构建中包含的 OpenVokaturi 库已设置一个与应用程序主题冲突的主题值。

可以通过将以下内容添加到清单AndroidManifest.xml并再次构建应用程序来覆盖此冲突主题:

tools:replace="android:theme"