ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vishal Vishnoi <vvish...@bea.com>
Subject Re: AW: specifying jvm for running ant tasks
Date Fri, 16 Mar 2007 13:52:37 GMT
Here's a snippet (from a macrodef and hence @{..}) of what I do when I 
need to exec Ant

          <java classname="org.apache.tools.ant.Main" fork="true"
            failonerror="@{failonerror}"
            outputproperty="@{outputproperty}"
            errorproperty="@{errorproperty}"
            classpath="${java.class.path}"
            newenvironment="false"
           >
             <arg value="-f"/>
             <arg value="@{antfile}"/>
             <arg value="@{target}"/>
             <java-elements/>
             <sysproperty key="area" value="${area}"/>
             <sysproperty key="team" value="${team}"/>
          </java>



--Vishal

thomaslarsson wrote:
> Thanks Jan but you misunderstand me.
>
> Its not java or javac task that I want to specify the java version for. 
> What I want is more similar to spawning a separate process with runs ant
> with a java version that I can specify for each project. 
> I know I can do this with the exec task, perhaps simplest by preparing a
> .bat or .sh file that makes a call to ant on my project, but I am asking for
> tips on a cleaner solution.
>
> -Thomas
>
>
>   


_______________________________________________________________________
Notice:  This email message, together with any attachments, may contain
information  of  BEA Systems,  Inc.,  its subsidiaries  and  affiliated
entities,  that may be confidential,  proprietary,  copyrighted  and/or
legally privileged, and is intended solely for the use of the individual
or entity named in this message. If you are not the intended recipient,
and have received this message in error, please immediately return this
by email and then delete it.

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


Mime
View raw message