我想創建一個與Facebook login.But當我加入的gradle這個依賴清單合併發行它給了我一個錯誤象下面這樣:獲得同時加入Facebook的Android SDK中
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : Attribute meta-data#[email protected] value=(26.0.0-alpha1) from [com.android.support:appcompat-v7: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.
這麼多的所以答案建議增加tools:replace="android:value"
(SO問題有不同的價值問題,雖然像主題,圖標等)。所以我在我的應用程序標籤中添加了。現在,我收到此錯誤:
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed with multiple errors, see logs
我使用它與許多其他依賴我有seen.Though當我加入Facebook的Android SDK中4.0.0它並不需要增加一些版本問題,最新的Android工作室tools:replace="android:value"
和Gradle構建的很好,但舊的SDK沒有打開Google Chrome的CustomTabActivity功能。我該怎麼辦?
下面我目前的表現和的build.gradle(應用級)文件:
的build.gradle
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "com.mranuran.buyhatkeassignmentone"
minSdkVersion 21
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.facebook.android:facebook-android-sdk:[4,5)'
testCompile 'junit:junit:4.12'
}
的manifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.mranuran.buyhatkeassignmentone">
<uses-permission android:name="android.permission.INTERNET"/>
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
tools:replace="android:value"
android:theme="@style/AppTheme">
<activity android:name=".MainActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>