Hi,
I am having several problems that seem to be cause by trying to run
Maven from a subdirectory of the project. To illustrate I have the following
directory structure
Project Dir
+ antfiles
+ src
| + app
+ classes
+ maven
Where:
* <ProjectDir>/antfiles contains the project.xml, maven.xml, build.xml and
build.properties. So this is where the maven command is executed.
* <ProjectDir>/src/app contains the java source files.
* <ProjectDir>/classes contains the compiled classes
* <ProjectDir>/maven is where the documents are generated, instead of
target.
To get this approach to work I had to set the following in my
build.properties
basedir=e:\\work\\projectname
maven.build.dest=../classes
maven.build.dir=../maven
maven.src.dir=src/app
maven.docs.dest=../maven
In my project.xml file sourceDirectory is set to:
<sourceDirectory>../src/app</sourceDirectory>
I've also had to change some of the plugins as they seemed to expect
maven to be executed from the root of the project dir. I had to change
maven-jxr-plugin-1.0 in the plugin.jelly file to use
sourceDir="${maven.src.dir}"
instead of
sourceDir="${pom.build.sourceDirectory}"
Also maven-activity-plugin-1.1 fails if a copy of project.xml
doesn't exist in what is now ${basedir}, as it tries to find project.xml in
e:\work\projectname instead of e:\work\projectname\antfiles
Is there a better way to get round these issues or was maven not
designed to be run of a subdir?
Thanks
Dave
--
To unsubscribe, e-mail: <mailto:turbine-maven-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:turbine-maven-user-help@;jakarta.apache.org>