ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Miten Mehta" <miten_s_me...@hotmail.com>
Subject RE: java fails (could not find class)
Date Fri, 04 Aug 2000 17:14:00 GMT
Hello,

d:\work\july2000 is my current dir and has all files in it (xml, java, 
class).  javac target goes fine but java fails to find class.  I am 
providing entire xml file and msdos dump.

D:\work\july2000>ant compile
Buildfile: build.xml

init:

prepare:

compile:

BUILD SUCCESSFUL

Total time: 2 seconds
D:\work\july2000>ant run
Buildfile: build.xml

init:

prepare:

compile:

run:

BUILD FAILED

build.xml:31: Could not find QSReport. Make sure you have it in your 
classpath

Total time: 1 seconds
D:\work\july2000>


<project name="quickshop" default="compile" basedir=".">
  <target name="init">
    <tstamp/>
    <property name="build" value="."/>
    <property name="src" value="."/>
    <property name="dist"  value="."/>
    <filter token="version" value="1.0.0"/>
    <filter token="year" value="2000"/>
  </target>

  <target name="prepare" depends="init">
    <mkdir dir="${build}" />
  </target>

  <target name="compile" depends="prepare">
    <javac srcdir="${src}" destdir="${build}" includes="QS*.java">
      <classpath path="d:\work\july2000"/>
    </javac>
  </target>

  <target name="dist" depends="compile">
    <mkdir dir="${dist}"/>
    <jar jarfile="${dist}/qs${DSTAMP}.jar" basedir="${build}" 
includes="QS*.class" />
  </target>

  <target name="clean" depends="init">
    <delete dir="${build}" includes="*.class"/>
    <delete dir="${dist}" includes="qs${DSTAMP}.jar" />
  </target>
  <target name="run" depends="compile">
    <java classname="QSReport" args="report.properties">
      <classpath>
        <pathelement  location="d:\oracle\ora81\jdbc\lib\classes111.zip"/>
        <pathelement  path="d:\work\july2000"/>
      </classpath>
    </java>
  </target>
</project>






________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


Mime
View raw message