ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rebhan, Gilbert" <Gilbert.Reb...@huk-coburg.de>
Subject RE: setting JAVA.HOME for javac with fork="true" ?
Date Tue, 24 Apr 2007 09:24:29 GMT
 

-----Original Message-----
From: Jan.Materne@rzf.fin-nrw.de [mailto:Jan.Materne@rzf.fin-nrw.de] 
Sent: Tuesday, April 24, 2007 11:05 AM
To: user@ant.apache.org
Subject: AW: setting JAVA.HOME for javac with fork="true" ?

/*

Use properties in the called buildfile
  <javac fork="true" exe..="${javac.exe}" ...
with default settings.

When calling that buildfile you can overwrite these settings.

<ant...>
   <property name="java.home" ...>

*/

Thanks!! , that works, but i have to edit the called scripts to make that work.
If it would be possible to ' overwrite ' %JAVA_HOME% for the called
script i don't have to edit anything.

So there's no way ?!
I already tried overrriding with $project.setProperty before my
<ant ... /> call

the echo in the called script shows to the overwritten %JAVA_HOME%
but for the compile the sun jdk is used =

[echo] JAVA_HOME == c:/Programme/JavaSoft/JDK/IBM_J9_v23_SR2

...

    [javac] File to be compiled:
    [javac] C:\WKS\eclipse_3_2_2\WEB_neu\src\de\bla\blabla\Bla.java
Execute:Java13CommandLauncher: Executing 'C:\Programme\JavaSoft\JDK\1.4.2_08\bin\javac.exe'
with arguments:
...


Regards, Gilbert
 

>-----Urspr√ľngliche Nachricht-----
>Von: Rebhan, Gilbert [mailto:Gilbert.Rebhan@huk-coburg.de] 
>Gesendet: Dienstag, 24. April 2007 10:45
>An: user@ant.apache.org
>Betreff: setting JAVA.HOME for javac with fork="true" ?
>
>
>Hi,
>
>right now i have a working testfile  with <javac >  IBM_J9_v23_SR2
>that way =
>
><javac fork="true"
> 
>executable="c:/Programme/JavaSoft/JDK/IBM_J9_v23_SR2/bin/javac.exe"
>        includeantruntime="false"
>        includejavaruntime="false"
>        classpathref="ibm.jdk.classpath" 
>        srcdir="c:/WKS/eclipse_3_2_2/web/src/de/bla/blabla"
>        destdir="Y:/tempwork"
>/>
>
>fine, but in reality i need to call another build.xml and want to
>point JAVA.HOME to the ibm jdk, so that the javac task
>in the called build.xml works with ibm jdk instead of sun jdk.
>
>Is that possible ?
>
>I want to avoid to write
>
><javac 
>
>executable="..."
>/>
>
>in the called build.xml and let the JAVA_HOME decide.
>
>
>Regards,Gilbert
>
>
>---------------------------------------------------------------------
>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


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


Mime
View raw message