java - Include libs folder containing .jars for compilation -
i have following file structure:
servercode <- src , libs, bin
i trying compile code in src. src has couple of .java files @ top level , sub-directories. libs contains .jar files required build project.
i wrote following build.xml when try compile it, compiler throws errors cannot find symbol errors libraries including.
<project default="compile"> <target name="compile"> <mkdir dir="bin"/> <javac srcdir="src" destdir="bin" classpath="libs/*.jar"> </target> </project>
define class path include jars this
<target name="compile" depends="" description="compile java source files"> <javac srcdir="." destdir="${build}"> <classpath> <fileset dir="${lib}"> <include name="**/*.jar" /> </fileset> <fileset dir="${test_lib}"> <include name="**/*.jar" /> </fileset> </classpath> </javac>
Comments
Post a Comment