build.gradle(app)
buildscript {
repositories {
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.28.0'
}
}
import java.text.SimpleDateFormat
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
repositories {
maven { url 'https://maven.fabric.io/public' }
}
apply plugin: 'com.google.gms.google-services'
android {
dexOptions {
jumboMode true
}
def versionMajor = 1 // 1 - 20000
def versionMinor = 2 // 0 - 9
def versionPatch = 1 // 0 - 99
def buildNumber = 0 // 0 - 999 used for testing builds, excluded from release versionName
def appName = "Smupp"
compileSdkVersion 28
defaultConfig {
applicationId "com.smupp"
minSdkVersion 16
targetSdkVersion 28
versionCode 1201001
versionName "1.2.2"
renderscriptTargetApi 19
renderscriptSupportModeEnabled true
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
//android.defaultConfig.javaCompileOptions.annotationProcessorOptions.includeCompileClasspath = true
resConfigs "en"
/*javaCompileOptions {
annotationProcessorOptions {
includeCompileClasspath false
}
}*/
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
buildTypes {
release {
minifyEnabled false
shrinkResources false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
lintOptions {
abortOnError false
}
dexOptions {
javaMaxHeapSize "4g"
}
buildToolsVersion '28.0.3'
}
dependencies {
def supportLibVersion = '1.0.0-beta01'
implementation fileTree(include: ['*.jar'], dir: 'libs')
androidTestImplementation('androidx.test.espresso:espresso-core:3.1.0-alpha4', {
exclude group: 'com.android.support', module: 'support-annotations'
})
implementation "androidx.appcompat:appcompat:1.0.2"
implementation "androidx.legacy:legacy-support-v4:1.0.0"
implementation "androidx.cardview:cardview:1.0.0"
implementation "com.google.android.material:material:1.1.0-alpha04"
implementation "androidx.recyclerview:recyclerview:1.1.0-alpha03"
implementation "androidx.percentlayout:percentlayout:1.0.0"
implementation 'com.google.android.material:material:1.0.0'
implementation 'com.google.firebase:firebase-messaging:17.4.0'
implementation 'com.google.android.gms:play-services-location:16.0.0'
//implementation "com.google.android.gms:play-services-gcm:16.1.0"
testImplementation 'junit:junit:4.12'
implementation 'com.google.code.gson:gson:2.8.5'
implementation 'com.squareup.picasso:picasso:2.71828'
implementation 'com.squareup.okhttp:okhttp:2.7.5'
implementation 'com.jakewharton:butterknife:10.1.0'
implementation 'com.github.johnkil.android-robototextview:robototextview:2.4.3'
implementation 'com.squareup.retrofit:retrofit:1.9.0'
implementation 'com.facebook.android:facebook-android-sdk:4.40.0'
implementation 'com.google.android.exoplayer:exoplayer:r1.5.8'
implementation 'com.google.android.gms:play-services-maps:16.1.0'
implementation 'com.googlecode.mp4parser:isoparser:1.1.20'
implementation('com.twitter.sdk.android:twitter:2.2.0@aar') {
transitive = true;
}
}
看见
values\values.xml:5397:error:资源先前在这里定义。
尝试从values.xml
重命名fontfamily
名称。
我使用的是android studion 3.4.1(最新版本)。我已经导入了一个项目,它需要:Android SDK v23 Android构建工具v23.0.2 Android Support Repository v23.3.0 我已经完成了所有需要的更新,但现在运行程序时,我面临着这个问题。
我运行我的项目,显示: 错误:配置为“”的资源“attr/content”的值重复。消息{kind=error,text=error:资源'attr/content'的值与配置为''重复。sources=[/users/bobzheng/.gradle/caches/transforms-1/files-1.1/appcompat-v7-26.1.0.aar/805CD07C22A7F63B737
我正在移植我当前的android apk,以满足最近的playstore指令-“targetSdkVersion 26” 这是我的年级档案。我从CompilesDKVersion26开始,到28。所以对于28个,我不得不使用AndroidX依赖项。我在主题行中贴出的错误处卡住了。任何帮助都将不胜感激。 错误消息为
/users/hyun/desktop/laftel-android/app/build/immeditiates/increment/mergedbugresources/merged.dir/values/values.xml重复资源'attr/font'与config“.resource的值。 executionException:com.android.tools.appt2.aapt2E
我已经无法构建可以成功构建的android项目。 构建:同步 ../../.../..gradle/caches/transforms-1/files-1.1/appcompat-v7-27.1.0.aar/079f027781f9663d188d9dd5f4f897cd/res/values/values.xml 错误:配置为“”的资源“attr/tint”的值重复。错误:资源以前定义在这里。
com.Android.builder.internal.aapt.v2.aapt2exception:Android资源编译失败/users/username/.gradle/caches/transforms-2/files-2.1/94 a628954aabd306de764f6ff2843371/res/values/values.xml:8:5-35:25:aapt:error:资源'a