AndroidStudio Gradle 1.8 で「Execution failed for task ':libraries:mylib:compileReleaseAidl'.」

こんなのでました。

Execution failed for task ':libraries:mylib:compileReleaseAidl'.
> Could not call IncrementalTask.taskAction() on task ':libraries:mylib:compileReleaseAidl'

調べてみると、

buildscript {
    repositories {
        mavenCentral()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:0.6.+'
    }
}

でいけるというのでやってみたらいけた。

The_Central_Repository_Search_Engine-2

The Central Repository Search Engine

Issue 60433 - android - Build fails with Gradle 1.8 when project has AIDL files. - Android Open Source Project - Issue Tracker - Google Project Hosting

けど、いいのかな、これ。。。

Version of Android Studio (available in the about box): 0.2.10
OS version: OSX 10.8
Java JRE/JDK version: 1.6

I have a project with AIDL files which was building perfectly with Gradle 1.7, but since updating to 1.8 the build fails.

I have attached a simple project which reproduces the problem. There are two things to look at:

1. The project has AIDL files
2. The project has common settings in the top level build.gradle (with allprojects script block)

Issue 60433 - android - Build fails with Gradle 1.8 when project has AIDL files. - Android Open Source Project - Issue Tracker - Google Project Hosting

Problems importing/refreshing Gradle project 'ProjectName':
Unable to find a JDK 1.6 installed. After configuring a suitable JDK in the Project Structure dialog, sync the Gradle project again.

gradle - Android Studio shows error on startup if android build tools v0.6.1 are used - Stack Overflow

Issue 60724 - android - Project sync JDK configuration broken: Requires JDK 6 - Android Open Source Project - Issue Tracker - Google Project Hosting

The bug is fixed on our side, and it didn't matter if you had AIDL files or not (I found out that after fixing the bug.)
The fix is not submitted yet because it is not clear if the change in behavior in Gradle 1.8 is intentional or just a bug. I already contacted the Gradle folks regarding this regression. Once we get word from them I'll submit the fix.

gradle 1.8 support? - Google グループ

まだまだ育ち盛りです。優しい目で見守りたいです。


関連ワード:  AndroidAndroidStudioGradleツール速報開発