ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Levy-Lambert <anto...@gmx.de>
Subject Re: Multiple JVM
Date Thu, 13 Apr 2006 03:28:43 GMT
Bandaru, Jaysheel wrote:

Hello Jaysheel,

two ideas :

run your build in debug (ant -debug) or verbose (-verbose) mode to get a
better feeling of what is happening in the case
you are starting <java/> from ant running in a JDK 1.4 VM.

Also try to nest in <java> an <env/> element to tell java where is your
JAVA_HOME. Maybe this would help, I do not know.
<env key="JAVA_HOME" value="C:\jdk1_5"/>

so

<java jar="test.jar" fork="true" jvm="C:/jdk1_5/bin/java.exe">


             <env key="JAVA_HOME" value="C:\jdk1_5"/>


            <arg value="+n" />


            <arg value="test.xml" />

        </java>



or try to run your program like that :

        <java jar="test.jar" fork="true" jvm="C:/jdk1_5/bin/java.exe">

            <arg value="+n" />

            <arg value="test.xml" />

        </java>

which could work too.

In other words I think that ant or java might not "know" what is the
value of JAVA_HOME for 1.5 on your system, or does
not know how to start java.exe.

Regards,

Antoine
> Hi -
>
>  
>
> I have a build file which uses JDK1.4 to compile(javac) and run the java
> tasks , in the build file I have task which executes a jar file compiled
> using JDK1.5 .
>
> How should I execute that task ?
>
>  
>
> I tried the following , it says buildSuccessful but I don't see the
> expected results.I run the same task in a separate build file using
> jdk1.5 it executes fine,
>
>  
>
> <target name="runTest">
>
>         <java jar="test.jar" fork="true" jvm="C:/jdk1_5/jre/bin/java">
>
>             <arg value="+n" />
>
>             <arg value="test.xml" />
>
>         </java>
>
>     </target>
>
>  
>
>  
>
> Any ideas
>
>   


>  
> Thanks
>
>   


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


Mime
View raw message