fyfcauc/gradle-android-plugin

gradle-android-plugin does not play well with Eclipse plugin in Gradle 1.0-milestone-5

Closed this issue · 2 comments

What steps will reproduce the problem?
1. Use Gradle 1.0-milestone-5
2. Use gradle-android-plugin 1.0.0
3. apply plugin: 'eclipse'
4. apply plugin: 'android'
5. gradle eclipse

What is the expected output?

I expect to see a clean output without neither deprecation warnings nor 
exceptions.

Instead I get this:

$ gradle eclipse
Android SDK Tools Revision 13
Project Target: Android 2.1-update1
API level: 7

------------------
Resolving library dependencies:
No library dependencies.

------------------

The sourceSet.classesDir method is deprecated and will be removed in the next 
version of Gradle. You should use the sourceSet.output.classesDir method 
instead.
The DomainObjectCollection.getAll() method is deprecated as 
DomainObjectCollection is now a Collection itself. Simply use the collection.
The DomainObjectCollection.findAll() method is deprecated as 
DomainObjectCollection is now a Collection itself. Use the matching(Spec) 
method.
<someIdeTask>.beforeConfigured is deprecated! Replaced by beforeMerged() method 
placed on the relevant model object of eclipse/idea.
As a starting point, refer to the dsl guide for IdeaProject or EclipseProject.
For example, ideaProject.beforeConfigured was changed to 
idea.project.ipr.beforeMerged
:app:eclipseClasspath
The eclipseClasspath.containers method is deprecated and will be removed in the 
next version of Gradle. You should use the eclipse.classpath.containers method 
instead.
The eclipseClasspath.sourceSets method is deprecated and will be removed in the 
next version of Gradle. You should use the eclipse.classpath.sourceSets method 
instead.
:app:eclipseJdt
:app:eclipseProject
The eclipseProject.natures method is deprecated and will be removed in the next 
version of Gradle. You should use the eclipse.project.natures method instead.
The eclipseProject.buildCommands method is deprecated and will be removed in 
the next version of Gradle. You should use the eclipse.project.buildCommands 
method instead.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:eclipseProject'.
Cause: Failed to notify action.
Cause: java.lang.NoClassDefFoundError: 
org.gradle.plugins.eclipse.model.BuildCommand
Cause: org.gradle.plugins.eclipse.model.BuildCommand

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug 
option to get more log output.

BUILD FAILED

Total time: 8.712 secs

What version of the product are you using? On what operating system?
Gradle 1.0-milestone-5
gradle-android-plugin 1.0.0
android-sdk-linux_x86 R13
Ubuntu 11.10

Additional info:

It works with gradle-android-plugin:0.9.9, but with the following deprecation 
warnings:

The sourceSet.classesDir method is deprecated and will be removed in the next 
version of Gradle. You should use the sourceSet.output.classesDir method 
instead.
The DomainObjectCollection.getAll() method is deprecated as 
DomainObjectCollection is now a Collection itself. Simply use the collection.
The DomainObjectCollection.findAll() method is deprecated as 
DomainObjectCollection is now a Collection itself. Use the matching(Spec) 
method.
:app:eclipseClasspath
:app:eclipseJdt
:app:eclipseProject
:app:eclipse

BUILD SUCCESSFUL

Original issue reported on code.google.com by olle.hal...@gmail.com on 10 Nov 2011 at 7:57

Can you try with 1.1.0 release of Gradle Android Plugin and Gradle 
1.0-milestone-6?

Original comment by eal...@gmail.com on 21 Dec 2011 at 10:16

Original comment by eal...@gmail.com on 21 Dec 2011 at 5:28

  • Changed state: Verified