hello remy,
i'll try to answer ur questions, but i feel i m not the best guy to explain
that classpath behaviour
On 9/18/06, Rémy Sanlaville <[EMAIL PROTECTED]> wrote:
Hello Marco,
You help me a lot, it works now, many thanks !
But I still have some questions :
(1) I tried also to use the antrun plugin without success.
I used this classpath (that works with ant).
<path id ="xdoclet.classpath">
<fileset dir="C:/Tools/XDoclet/v1.2.3/lib">
<include name="*.jar"/>
</fileset>
</path>
<taskdef
name = "webdoclet"
classname = "xdoclet.modules.web.WebDocletTask"
classpathref= "xdoclet.classpath"
/>
But if I use the maven.dependency.classpath as you, it works well !
Strange no ?!
Well, it would not surprise me if in your fileset
dir="C:/Tools/XDoclet/v1.2.3
/lib" you are missing some jars...... cos theoretically if in that lib
dir you have
all jars needed by xdoclet, it should have worked just fine
<taskdef
name = "webdoclet"
classname = "xdoclet.modules.web.WebDocletTask"
classpathref= "maven.dependency.classpath"
/>
this i m sure it works becaue in my dependencies there is all that xdoclet
need to run the task.
If in your lib directory you h ave all xdoclet-xxx-module.jar as well as
xjavadoc, i see no reason of why your code above hsould not work
again,, any maven expert here can condraddict and give feedback, i m no
guru...i have just learned things from trying them out (and failing :) )
(2) In order to don't put the xdoclet dependencies in the WEB-INF/lib, I
wanted
to use the maven.plugin.classpath (see [1]), but it seems that it does not
exist any more
> Embedded error: Reference maven.plugin.classpath not found.
It is normal ?
It is not possible also to use the scope provided because the
maven.dependency.classpath
don't take into account this scope.
mmm, this scopes confuse me too... in your dependencies, try to put
<scope>provided</scope>
this assumes that at runtime those libraries are alredy present (if i m
correct), and thus maven won't include them in yoru war (it worked for me
while building an .ear..)
(3) Why are you the packaging phase insteed of the generate-sources phase ?
<execution>
<phase>package</phase>
ah! ignore it...i had problems wtih dependencies.... but it might have been
due to the fact that i had incorrect classpath
it should work also with <phase>generate-sources</phase>
but i haven't tried....have no time unfortunately..... i m not using maven
at work, so i have to use it in my spare time and nowadays i have very
little spare time
you might want to try and see if you have classpath problem....
hth
marco
Thanks again,
Rémy
[1] http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html