On Tue, 2009-12-15 at 06:56 +1100, Adam Murdoch wrote: > > On 13/12/09 12:25 AM, Russel Winder wrote: > > I have more or less committed everyone to supporting using Gradle to > > build the Groovy system. > > > > Problem 1 is that this is a multi-phase build. > > > > Phase 1 compile all the Java code. > > Phase 2 use the Groovy compiler just compiled to compile the Groovy > > code. > > > > This means not using the Groovy plugin as that requires a prebuilt > > groovy-all jar. > > The groovy jar doesn't need to exist until the compileGroovy or > compileTestGroovy tasks actually execute. It doesn't even need a jar - > just a classes dir would do. You should be fine.
I haven't got Antlr to run as a prepass yet, given other discussions, I
am not going to try and recreate what is already lined up to be in
Gradle 0.9. Hopefully though that will not lead to problems.
There is currently the problem that two of the Java files in the main
codebase depend on Groovy files, so they have had to be explicitly
excluded from the compileJava phase. Other than that all the Java files
compile fine with the Java plugin.
This means that using the Groovy plugin and pointing to the Java classes
tree should do the right thing . . .
<goes away to try>
Thought whilst waiting . . . how does all this fit with Groovy/Java
joint compilation. Clearly it works or Gradle could not compile Gant,
but the implication of the above is that there must be a hidden stub
generation phase for creation of Java stubs of Groovy code rather than
using the joint compiler?
Hummm... it seems that:
groovy ( files ( compileJava.destinationDir ) )
is not acceptable, it gives the error:
Cause: No signature of method:
org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.groovy()
is applicable for argument types:
(org.gradle.api.internal.file.PathResolvingFileCollection) values: [file
collection]
I may just not be looking correctly, but I can't find anything
particularly helpful in the user guide since it assumes you will always
use a Groovy jar out of the Maven repository.
--
Russel.
=============================================================================
Dr Russel Winder Partner
xmpp: [email protected]
Concertant LLP t: +44 20 7585 2200, +44 20 7193 9203
41 Buckmaster Road, f: +44 8700 516 084 voip: sip:[email protected]
London SW11 1EN, UK m: +44 7770 465 077 skype: russel_winder
signature.asc
Description: This is a digitally signed message part
