On 07/08/2013, at 12:39 AM, Peter Niederwieser <pnied...@gmail.com> wrote:
> I'd like to make two proposals on how Java compilation could be improved, > based on experiences in the field. > > 1. First-class support for compiling with a specific JDK > > Many people want to compile with a specific JDK. Currently the only way to > achieve this is to set `options.forkOptions.executable`. However, this means > that Gradle can't use the compiler daemon and has to fall back to the > command line compiler integration, which forks a new compiler for each > compile task and is dead slow. > > Therefore I propose to add a `forkOptions.jdkHome` property that points to > the JDK used to run the compiler daemon. This will significantly speed up > compilation and will get more people off the command line compiler > integration. > > 2. Default to empty source path > > Currently, Gradle inherits the javac behavior of defaulting the source path > to the compile class path. This causes problems as soon as Jars on the > compile class path contain sources, which isn't uncommon (`guava-gwt` being > just one example). Most people haven't even heard about source paths and > can't explain what's going on. While useful in some cases (e.g. Java-Groovy > joint compilation), source paths seem to be a mostly historic feature. > > Therefore I propose to add an explicit `sourcepath` property that gets > defaulted to the empty source path. This makes source paths an opt-in rather > than an opt-out, solving a recurring pain for users. > > Thoughts? Both seem like good changes to me. -- Luke Daley Principal Engineer, Gradleware http://gradleware.com --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email