Android Studio2.3.2でアプリを作成しているのですがとあるエラーに困っています
layoutで[card view]を追加するときに自動で依存関係の追加をしてくれるのですが、下記のようなエラーが出てしまいます。
調べたところマニフェストの合併エラーのようなのですが直し方がわかりません!
力を貸してください!お願いします!
発生している問題・エラーメッセージ
Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed : Attribute meta-data#android.support.VERSION@value value=(26.0.0-alpha1) from [com.android.support:design:26.0.0-alpha1] AndroidManifest.xml:27:9-38 is also present at [com.android.support:cardview-v7:25.3.1] AndroidManifest.xml:24:9-31 value=(25.3.1). Suggestion: add 'tools:replace="android:value"' to <meta-data> element at AndroidManifest.xml:25:5-27:41 to override.
Manifests
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.onosereo.myapplication" xmlns:tools="http://schemas.android.com/tools"> <application android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme" tools:replace="android:icon" > <activity android:name=".MainActivity" android:label="@string/app_name" android:theme="@style/AppTheme.NoActionBar"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> </application> <meta-data android:name="xxx.color" android:value="#FFFFFFFF" tools:replace="android:value" /> </manifest>
Build Gradle
apply plugin: 'com.android.application' android { compileSdkVersion 26 buildToolsVersion "27.0.3" defaultConfig { applicationId "com.example.onosereo.myapplication" minSdkVersion 16 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 { compile fileTree(dir: 'libs', include: ['*.jar']) 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.+' compile 'com.android.support.constraint:constraint-layout:1.0.2' compile 'com.android.support:design:26.+' testCompile 'junit:junit:4.12' compile 'com.android.support:cardview-v7:25.3.1' }
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。