0

This is my gradle,

apply plugin: 'com.android.application'

android {
    compileSdkVersion 24
    buildToolsVersion "25.0.1"

    defaultConfig {
        applicationId "com.example.sakhi.live_scoure"
        minSdkVersion 12
        targetSdkVersion 24
        versionCode 1
        versionName "1.0"
        multiDexEnabled = true

    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    dexOptions {
        preDexLibraries = false
        javaMaxHeapSize "4g"
    }
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:24.2.1'
    compile 'com.android.support:design:24.2.1'
    compile 'com.android.support:recyclerview-v7:24.0.+'
    compile 'com.android.volley:volley:1.0.0'
    compile 'com.google.android.gms:play-services:10.0.1'
    compile 'com.jakewharton:butterknife:7.0.1'
    compile 'com.squareup.picasso:picasso:2.5.0'
    compile files('libs/awais.jar')
    compile 'com.android.support:support-vector-drawable:24.2.1'
    compile 'com.android.support:multidex:1.0.1'
    // compile project(':dBPullToRefresh')
}

While building I am getting this error..

Process 'command 'C:\Users\Tejas\AppData\Local\Android\Sdk\build-tools\25.0.1\aapt.exe'' finished with non-zero exit value 1


Can anyone help me out to resolve this error?

Thanks Tejas

Phantômaxx
  • 37,901
  • 21
  • 84
  • 115

1 Answers1

0
buildTypes {
        release {
            minifyEnabled true
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            shrinkResources true
        }
        debug {
            minifyEnabled false=
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            shrinkResources false
        }
    }
    dexOptions {
        javaMaxHeapSize "4g"
    }
Amit Ranjan
  • 567
  • 2
  • 11
  • same issue brother :( seems like buildToolsVersion "25.0.1" not supporting or needs to installed somehow this.. do you know how to? – Tejas Shyani Jun 06 '18 at 10:44
  • compileSdkVersion 27 buildToolsVersion "26.0.2"... below your android written in gradle replace these lines and in dependencies change ll to 26.0.2 – Amit Ranjan Jun 06 '18 at 10:54
  • I did it..but then it's giving this next error: Process 'command 'C:\Users\Tejas\AppData\Local\Android\Sdk\build-tools\26.0.2\aapt.exe'' finished with non-zero exit value 1 – Tejas Shyani Jun 06 '18 at 12:20
  • in the defaultConfig block can you add this line : aaptOptions { additionalParameters "--no-version-vectors" } – Amit Ranjan Jun 06 '18 at 12:45
  • if it's not working , then i think you have put duplicate resources : You can follow this link and see the nightFurry answer to find the duplicate resources : https://stackoverflow.com/questions/30899963/how-to-fix-22-0-1-aapt-exe-finished-with-non-zero-exit-value-1 – Amit Ranjan Jun 06 '18 at 12:50