On Mon, 2002-10-07 at 05:34, Eric Hartmann wrote:
> Hi,
> 
> I'm trying to use maven 1.0-b7 instead of Ant. 
> I cannot find the answer on the web site nor the mailing list archive.
> 
> I have multiple source directory, so I use a preGoal to copy all sources
> to the src directory :
> 
> ...
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <project>
>       <preGoal name="java:prepare-filesystem">
>               <copy todir="src">
>                       <fileset dir="../tools"/>
>                       <fileset dir="../tcp"/>
>               </copy>
>       </preGoal>   
> </project>
> ...
> 
> But the first time, Maven doesnot find any sources :

If you are copying the sources to a directory that does not yet exist
then you will have a problem. Use this as a work around:
 
  <preGoal name="java:compile">

    <!-- This will force maven into believing the source directory exists -->
    <path id="maven.compile.src.set">
      <pathelement location="${pom.build.SourceDirectory}"/>
    </path>
    
    ... whatever else you have ...

  </preGoal>

> ...
> java:prepare-filesystem:
>     [copy] Copying 215 files to
> C:\Projects\SharedValue\autocompil\llf.build\src
>     [copy] Copied 5 empty directories to
> C:\Projects\SharedValue\autocompil\llf.build\src
>     [mkdir] Created dir:
> C:\Projects\SharedValue\autocompil\llf.build\target\classes
> 
> java:compile:
>     [echo] No java source files to compile.
> ...
> 
> The second time, everything works fine (file are already copied).
> I've try to use prereqs instead of preGoal but I experience the same
> problem.
> 
> Can anyone help me ?
> 
> Eric
> 
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
-- 
jvz.

Jason van Zyl
[EMAIL PROTECTED]
http://tambora.zenplex.org

In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
  
  -- Jacques Ellul, The Technological Society


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to