【发布时间】:2016-03-29 11:46:06
【问题描述】:
我在执行我的 Android 应用程序时遇到了这个错误(我清理它然后构建它,但错误仍然存在)
同步:好的
制作项目:错误
清理:错误
运行:错误
错误:任务 ':app:dexDebug' .com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/Users/Jude/Library/Android 执行失败/sdk/build-tools/23.0.2/aapt' 以非零退出值 1 结束
我使用 'multiDexEnabled true' 启用了 multidex 支持,但错误不断出现。
我的 gradle 文件:
应用插件:'com.android.application' 安卓 { compileSdkVersion 23 buildToolsVersion '23.0.2'
defaultConfig {
applicationId 'com.kakao.inhouseagit'
minSdkVersion 16
targetSdkVersion 23
multiDexEnabled true
buildConfigField "String", "DEPLOY_PHASE", "\"PreRelease\""
buildConfigField "boolean", "DEBUG_TRACE", "true"
buildConfigField "boolean", "inhouse", "true"
}
signingConfigs {
debug {
storeFile file('keystore/debug.keystore')
}
release {
storeFile file('keystore/kakao.keystore')
storePassword 'sksmswjstjfdlek'
keyAlias 'kakao'
keyPassword 'sksmswjstjfdlek'
}
}
buildTypes {
alpha {
debuggable true
signingConfig signingConfigs.debug
buildConfigField "String", "DEPLOY_PHASE", "\"Alpha\""
}
beta {
debuggable true
signingConfig signingConfigs.debug
buildConfigField "String", "DEPLOY_PHASE", "\"Beta\""
}
preRelease {
debuggable true
signingConfig signingConfigs.debug
buildConfigField "String", "DEPLOY_PHASE", "\"PreRelease\""
}
release {
minifyEnabled true
shrinkResources true
debuggable false
buildConfigField "boolean", "DEBUG_TRACE", "false"
buildConfigField "String", "DEPLOY_PHASE", "\"Release\""
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt', 'proguard_clearlog.cfg'
signingConfig signingConfigs.release
}
}
lintOptions {
checkReleaseBuilds true
abortOnError false
checkAllWarnings true
xmlReport true
htmlReport true
disable "InvalidPackage", "MissingTranslation"
}
packagingOptions {
exclude 'META-INF/DEPEDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/LICENSE'
exclude 'META-INF/NOTICE'
}
productFlavors {
inhouse {
applicationId 'com.kakao.inhouseagit'
testApplicationId 'com.kakao.inhouseagit-test'
versionCode 82
versionName '2.7.1.1'
buildConfigField "boolean", "inhouse", "true"
}
io {
applicationId 'io.agit'
testApplicationId 'io.agit-test'
versionCode 10
versionName '1.0.2'
buildConfigField "boolean", "inhouse", "false"
}
}
task wrapper(type: Wrapper) {
gradleVersion = '2.4'
}
repositories {
maven { url 'http://maven.daumcorp.com/content/groups/daum-ma-group' }
maven { url 'http://maven.daumcorp.com/content/groups/daum-public' }
}
dependencies {
compile(group: 'com.kakao.sdk', name: 'kakaolink', version: '1.0.52') {
exclude group: 'com.google.android', module: 'support-v4'
}
compile 'com.android.support:support-annotations:23.0.1'
compile 'com.google.android.gms:play-services-gcm:8.1.0'
compile 'com.android.support:appcompat-v7:23.1.0'
compile 'com.android.support:design:23.1.1'
compile 'com.google.guava:guava:18.0'
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.4'
compile 'de.greenrobot:eventbus:2.4.0'
compile 'commons-io:commons-io:2.4'
compile 'org.apache.commons:commons-lang3:3.4'
compile 'pl.droidsonroids.gif:android-gif-drawable:1.1.9'
compile 'com.fasterxml.jackson.core:jackson-core:2.6.2'
compile 'com.fasterxml.jackson.core:jackson-annotations:2.6.2'
compile 'com.fasterxml.jackson.core:jackson-databind:2.6.2'
compile 'com.melnykov:floatingactionbutton:1.3.0'
compile 'com.mcxiaoke.volley:library:1.0.19'
compile 'de.hdodenhof:circleimageview:2.0.0'
compile('org.apache.httpcomponents:httpmime:4.2.2') {
exclude group: 'org.apache.httpcomponents', module: 'httpcore'
exclude group: 'commons-logging', module: 'commons-logging'
}
// for multi dex
compile 'com.android.support:multidex:1.0.1'
// for Emoticon SDK
// emoticon sdk를 사용하기 위해 필요.
compile(group: project.KAKAO_SDK_GROUP, name: 'kakaolink', version: project.KAKAO_SDK_VERSION)
compile project(':emoticon')
testCompile 'junit:junit:4.12'
testCompile "org.mockito:mockito-core:1.10.19"
compile "com.davemorrissey.labs:subsampling-scale-image-view:3.3.0"
debugCompile 'com.squareup.leakcanary:leakcanary-android:1.3.1'
alphaCompile 'com.squareup.leakcanary:leakcanary-android:1.3.1'
betaCompile 'com.squareup.leakcanary:leakcanary-android:1.3.1'
preReleaseCompile 'com.squareup.leakcanary:leakcanary-android:1.3.1'
releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.3.1'
}
// TODO remove legacy package
useLibrary 'org.apache.http.legacy'
}
放之前还好
编译'com.android.support:design:23.1.1'
我用 Navigationview 更改了布局,所以我输入了 'com.android.support"desing:23.1.1' 然后错误不断出现。 现在,当我按下“运行”时,“Gradle Buid Running”大约需要 10 到 15 分钟,最终出现同样的错误。
我的项目 gradle 使用类路径 'com.android.tools.build:gradle:1.3.1' 如果有人可以请给我一些关于我哪里出错的指示,我将不胜感激。这可要了我的命。
谢谢。
【问题讨论】:
标签: android android-gradle-plugin