I am getting gradle build error:
Error: Cannot get property 'dirName' on null object
I get this error with gradle version 1.3.1 or greater.
When I use gradle version 1.2.3 there is no error.
I google this error but was not able to find any solution. Please help!
My project gradle file:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
maven { url "http://dl.bintray.com/populov/maven" }
mavenCentral()
jcenter()
flatDir { dirs '/usr/local/DexGuard6.1.19/lib' }
}
dependencies {
classpath 'com.android.tools.build:gradle:1.2.3'
classpath ':dexguard:'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
maven { url "http://dl.bintray.com/populov/maven" }
maven { url "https://repo.commonsware.com.s3.amazonaws.com" }
maven { url 'https://maven.fabric.io/public' }
maven { url "https://jitpack.io" }
mavenCentral()
jcenter()
}
}
/usr/local/DexGuard6.1.19/libexists? Can you remove that section and try again?com.android.tools.build:gradle:1.5.0(perhaps you need to update your SDK first. 2. Ensure to use the latest gradle version (2.9).