You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Blake Flaming <bf...@pacbell.net> on 2003/04/15 04:03:05 UTC

Javac and forking

I'm a newbie to Maven, so I hope the following question isn't too
obvious. I checked the user guide and searched the mailing lists but
couldn't find an answer, so here goes (I'm using Maven 1.0 Beta 9):
 
In MAVEN_HOME/plugins/maven-java-plugin-1.3/plugin.jelly, the javac task
contains fork="true", but in
MAVEN_HOME/plugins/maven-test-plugin-1.3/plugin.jelly, the javac task
does not contain fork="true". I noticed this because Maven couldn't
compile my source files, since the path contains spaces (I know,
probably a bad idea but I can't change it). On a hunch, I removed the
<sourceDirectory> section from my project.xml file, causing it to skip
directly to the <unitTestSourceDirectory> section. To my surprise, the
unit test source files compiled successfully, even though the path
contained spaces. I snooped around and discovered that it was related to
the fork="true" in the maven-java-plugin-1.3/plugin.jelly file. When I
remove that line, my normal source files get compiled and everything
seems to work.
 
Why is fork="true" part of the javac task in maven-java-plugin-1.3 but
not maven-test-plugin-1.3? Are there problems with removing it from
maven-java-plugin-1.3 as I did?
 
Thanks,
Blake