I see.  You are in evaluation-order hell.  You see, we made your root
project's build file declare that it's evaluation depends on the
ebj-module-session project.  So, Gradle will process that subproject first.
During it's evaluation, you then refer to a configuration called compile.
However, the java plugin is specified in the root project's build file (in
the subprojects closure) which hasn't executed yet, so there is not yet a
configuration called compile.  One solution is to move the usePlugin('java')
line to the ejb-module-session's build script.  Another is to remove the
need for evaluating the subprojects first.  Perhaps instead of looking at a
property defined in the build file, look at something else to decide how to
handle the module.  What we use is if the module has a "src/main/java"
directory, we assume it's a java plugin.  If it has a "src/main/groovy"
directory, we assume it's a groovy plugin.  You might be able to determine
how to package your modules like this, or maybe have a separate
build.properties file that the root project's build.gradle can just read and
get the needed information.


-- 
John Murph
Automated Logic Research Team

Reply via email to