Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
397 views
in Technique[技术] by (71.8m points)

android - how to fix 23.0.1aapt.exe'' finished with non-zero exit value 1

All of a sudden I cannot get Gradle to build any projects under Android Studio.

Error:Execution failed for task ':app:processDebugResources'. com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'LocalAndroidsdkuild-tools23.0.0aapt.exe'' finished with non-zero exit value 1

My Gradle is

apply plugin: 'com.android.application'

android {
    compileSdkVersion 22
    buildToolsVersion "23.0.0"

    defaultConfig {
        applicationId "com.marathon.simplelist"
        minSdkVersion 8
        targetSdkVersion 22
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:appcompat-v7:23.0.1'
}

Even if I create a new Blank Activity project I still get this error.

I have Android Studio 1.3.1 installed with

SDK Platforms: 5.X, 5.1, 5.0, 4.4, 2.3.3 SDK Tools: SDK Build Tools, SDK Tools 24.4, Platform-Tools 23.0.1

Obviously something is reconfigured locally since even a new empty project will not build. Ideas on how I can resolve this?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

First try to clean and rebuild your project from Build menu.

Step 1: go to Build -> Clean Project

Step 2: go to Build -> Rebuild Project

This should solve your problem.

Otherwise try updating Android SDK build tool from SDK manager and modify your build.gradle to use latest buildToolsVersion i.e "23.0.2" as of now


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...