android - Gradle code not building: aidl is missing -


i updated android studio version 1.0 1.2.1 , when started first application appears.

error:execution failed task ':app:compiledebugaidl'.

aidl missing

i have made sure sdk date. gradle build code.

apply plugin: 'com.android.application'  android {     compilesdkversion 22     buildtoolsversion "23.0.0 rc1"  defaultconfig {     applicationid "com.example.william.myapplication"     minsdkversion 17     targetsdkversion 22     versioncode 1     versionname "1.0"      compilesdkversion 21  } 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:22.2.0' } 

it seems androidstudio-1.3-preview using unexpected version of gradle plugin. (at least when create fresh new project)

similarly, if open existing project using:

  • an older version of plugin. (<1.3.0-beta1)
  • latest build tools (23.0.0-rc1)
  • compilesdk 22

---> have strange error : "aidl missing" (even in projects not using aidl !)

solution:

be sure use latest android-gradle-plugin (in root build.gradle) :

classpath 'com.android.tools.build:gradle:1.3.0-beta1' 

under buildscript-->dependencies.

example :

buildscript {     repositories {         jcenter()     }     dependencies {         classpath 'com.android.tools.build:gradle:1.3.0-beta1'          // note: not place application dependencies here; belong         // in individual module build.gradle files     } } 

and latest build tools (in module build.gradle):

android {     compilesdkversion 22     buildtoolsversion "23.0.0 rc1"     ... } 

be aware config using latest build tools -not released yet- , preview of android-m ---> things can unstable


Comments

Popular posts from this blog

node.js - Using Node without global install -

How to access a php class file from PHPFox framework into javascript code written in simple HTML file? -

java - Null response to php query in android, even though php works properly -