Thomas Kinnen wrote:
Hi,
I was wondering why the eclipse plugin uses the result of resolving
the testRuntime configuration. By resolving the configuration the
plugin also adds dependencies that are actually dependencies of
projects I am referencing. Consider the following:
Proj1
dependenciens {
compile name: "lib1"
compile project('proj2')
}
proj2
dependencies {
compile name: "lib2"
compile name: "lib3"
}
This will result in gradle creating a classpath file for proj1
containing lib1,lib2 and lib3 as dependencies. This is not needed, as
lib2 and lib3 should be added as dependencies for proj2. Proj1 should
imho just reference proj2.
Is there something I am missing or any special reason why this is done?
Thomas
After doing some more research i figured out that it doesn't actually
put the resolved runtime dependencies into the .classpath file. The
generated file is correct. Still when running the eclipse task on Proj1,
gradle needs to know the location of the proj2 libs. This means if i
have the proj2 libs in a seperate repository, which ony proj2 knows, it
will not work. I have tried telling proj1 to exclude lib2 and lib3, but
to no success.
My idea was doing the following:
dependenciens {
compile name: "lib1"
compile project('proj2') {
exclude module: "lib2"
exclude module: "lib3"
}
}
Another idea was doing something like this:
proj2
dependencies {
compile name: "lib2" {
transitive=false
}
compile name: "lib3" {
transitive=false
}
}
Sadly both options didn't lead to the expected results. Any ideas?
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email