I’m trying to move my companies huge application build (~70,000 files) from a hodge podge of ant scripts held together with duct tape and chewing gum to a cohesive gradle build. But in the process we’ll have several months (or possibly years) of needing to run our ~350 Ant build scripts during the transition. I have several of the scripts working quite well (as far as I can tell), but I’m running into one stubborn script that’s erroring out and searching the inter-webs hasn’t pointed me to a solution, so I’m hoping you good folks can help me over this hump. The gradle build that’s failing is:
ant.importBuild 'build.xml'
task build (dependsOn: dist)
Running that script produces:
:milan:components:roles:generate FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':milan:components:roles:generate'.
> Error starting modern compiler
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.
BUILD FAILED
Total time: 14.659 secs
The Ant task that’s failing is:
<taskdef name="xjc" classname="com.sun.tools.xjc.XJCTask">
<classpath>
<fileset dir="${libdir}/jaxb/2.2.6/lib" includes="*.jar" />
</classpath>
</taskdef>
<target name="generate">
<mkdir dir="src/generated"/>
<xjc schema="src/conf/roleModuleMetaData.xsd" destdir="src/generated" package="com.pearson.powerschool.roles.jaxb" >
<produces dir="src/generated/com/pearson/powerschool/roles/jaxb" includes="**/*.java"/>
</xjc>
<mkdir dir="build/classes"/>
<javac destdir="build/classes" srcdir="src/generated" debug="true" classpath="" includeantruntime="false"/>
</target>
Anyone run into this problem before? Or have any idea how to solve it? Thanks.
(*Chris*)