ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jain, Manish (MED, TCS)" <Manish.J...@med.ge.com>
Subject Accessing CVS
Date Tue, 10 Jul 2001 05:22:22 GMT
 Hi,
      I am using the ANT tool for the first time.. I need to compile
code for a application. The code is in CVS loaded on a Unix machine. Can
someone tell me how do I give reference to the CVS directory as source
directory in my build script which I will be running from my NT
machine.Also I need  to put my class files back on CVS after the
compilation and build the application.

Below is the build script I am using....but it is not working...can
someone point out what is wrong here....

<!-- 
 
========================================================================
       In order to use this build script, the following properties
should
       be set to appropriate values in the user environment.

       TMP_ROOT  - The root directory of the CVS repository
       What is the correct way to set the above variable?   
     
 
========================================================================
  -->

<project name="TMP" default="dist" basedir=".">
	<!-- set global properties for this build -->
	<property environment="myenv"/>
	<property name="src" value="${myenv.TMP_ROOT}"/>
	<property name="build" value="build"/>
	<property name="dist" value="${myenv.TMP_ROOT}/dist"/>
	
	<target name="init">
		<!-- Create the time stamp -->
		<tstamp/>
		<!-- Create the build directory structure used by
compile -->
		<mkdir dir="${build}"/>
		<mkdir dir="${dist}"/>
	</target>
	<target name="compile" depends="init">
		<!-- Compile the java code from ${src} into ${build} -->
		<javac srcdir="${src}" destdir="${build}"/>
	</target>
	<target name="dist" depends="compile">
		<!-- Create the distribution directory -->
		<mkdir dir="${dist}/lib"/>
		<!-- Put everything in ${build} into the
TMP_ROOT-${DSTAMP}.jar file -->
		<jar jarfile="${dist}/lib/TMP_ROOT-${DSTAMP}.jar"
basedir="${build}"/>
	</target>
	<target name="clean">
		<!-- Delete the ${build} and ${dist} directory trees -->
		<delete dir="${build}"/>
		<delete dir="${dist}"/>
	</target>
</project>

Thanks,
Manish

Mime
View raw message