Quantcast

Classpath order when generating project files with Eclipse plugin

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Classpath order when generating project files with Eclipse plugin

bmuschko
I have a multi-project build with two subprojects "a" and "b". "b" depends on "a". Both subprojects declare Guava as first level dependency. "a" uses version 15.0 whereas "b" uses 16.0.1.

Running gradle b:dependencies demonstrates that the latest version is picked. However, when generating the Eclipse project files with the Gradle Eclipse plugin (by executing gradle eclipse) version 15.0 is found first on the classpath as we have a project dependency on "a". It looks like depending on another project reference also adds all external dependencies but without any conflict resolution. They are resolved first on the classpath.

You can find an example project that demonstrates the issue here: https://github.com/bmuschko/eclipse-export.

Is this a known issue? What's your take on this? I don't think this is the behavior we'd want. Reordering the project dependency on the classpath makes it work.

In a multi-project build I'd usually recommend to streamline the Guava version across all projects. The scenario I am describing could potentially occur in as part of the binary integration story.

Thanks,

Ben
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Classpath order when generating project files with Eclipse plugin

bmuschko
Never mind. Moved discussion to Google Groups.
Loading...