ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nicholas <nwhit...@yahoo.com>
Subject RE: problem with the java task...help needed urgent
Date Fri, 05 Sep 2003 13:45:57 GMT
Do not pass in the classpath on the command line.

Use a classpath ref and dynamically build a classpath
in your script.

For example, if you want to build a classpath of all
jar files in directories A..F:

<path id="class.path">
		<fileset dir="${A.dir}">
			<include name="*.jar"/>
		</fileset>
		<fileset dir="${B.dir}">
			<include name="*.jar"/>
		</fileset>
		<fileset dir="${C.dir}">
			<include name="*.jar"/>
		</fileset>
		<fileset dir="${D.dir}">
			<include name="*.jar"/>
		</fileset>
		<fileset dir="${E.dir}">
			<include name="*.jar"/>
		</fileset>
		<fileset dir="${F.dir}">
			<include name="*.jar"/>
		</fileset>
	</path>


--- Laxma.Nandikonda@nokia.com wrote:
> Hi Stefan,
> 
>  My classpath consists of so many different
> directories involved which is why it is so long. In
> my ant build script file I am just giving $classpath
> but how about in command line ??. I think I can't go
> more than that 2046 even when I declare all my
> classpaths in Window's user variable or env variable
> Classpath..
> 
>  Regarding fork, how can I pass environment
> variables without using jvmarg for which fork is
> needed to be set true. Any other keyword ??
> 
> thanks..
> 
> -----Original Message-----
> From: ext Stefan Bodewig [mailto:bodewig@apache.org]
> Sent: 05 September, 2003 15:06
> To: user@ant.apache.org
> Subject: Re: problem with the java task...help
> needed urgent
> 
> 
> On Fri, 5 Sep 2003, Laxma Nandikonda
> <Laxma.Nandikonda@nokia.com>
> wrote:
> 
> > 1. How can I overcome this problem of too long
> command line.
> 
> Don't fork.
> 
> Use $CLASSPATH instead of expanding it.
> 
> > I have this dependcies target rmic depends
> compile1 target compile1
> > depends init target init depends clean
> > 
> >   and then a separate target run.
> >   
> >   It's saying the complete build sequence is [run,
> clean, init,
> >   compile1, rmic]. I think rather it should say
> [run, rmic,
> >   compile1, init, clean ]. Any comments ??
> 
> You are reading the output in the wrong direction
> (and the output is
> misleading as only the build sequence is important
> to you, the
> "complete" build sequence is something internal to
> Ant).
> 
> run, clean, init, compile1, rmic
> 
> means not much - if your invoke "ant run", run will
> be the only thing
> that gets invoked.  The order of clean, init,
> compile1, rmic matches
> exactly your dependenvy chain - this is the order
> the targets would
> get executed in if you invoked "ant rmic".
> 
> Stefan
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 


=====
Nicholas Whitehead
Home: (973) 377 9335
Cell: (201) 615 2716
nwhitehe@yahoo.com
Get Your News From The Crowbar: http://crowbar.dnsalias.com:443/crowbar/

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message