You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Bahaa Nasrallah <ba...@gmail.com> on 2005/02/25 18:27:06 UTC

compiling my project with resource files

Hi,
I am trying to migrate the build process for my project from Ant to Maven.
The problem is that i dont know how exactly to migrate the compiling.
in Ant i have: 
 
<!--Compile Java source files  debug="on" -->
      <javac srcdir="${src}" destdir="${compile.outdir}">
        <classpath>
          <pathelement path="${classpath}"/>
          <fileset dir="lib">
            <include name="*.jar"/>
            <include name="nls_charset12.zip"/>
          </fileset>
        </classpath>
      </javac>

where 

<property name="src" value="src"/>
<property name="classpath"  value="lib"/>
<property name="compile.outdir" value="classes"/>

In Maven in my project.xml i have:

<build>
      <sourceDirectory>src</sourceDirectory>
<resources>
  <resource>
  <directory>${basedir}</directory>
   <includes>
    <include>lib/*.jar</include>
    <include>lib/nls_charset12.zip</include>
   </includes> 
 </resource>
</resources>
</build>

in ${basedir} there is src directory and lib directory.

when i run  maven java:compile
i get BUILD FAILD becouse of compilation errors (seems like doesn't
recognize the files found in lib directory)

I will be thankful if anoybody has a suggestion to solve this problem.

Thanks in advance.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org