ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Nabbefeld <Peter.Nabbef...@gmx.de>
Subject Re: Override ignored for property java.home
Date Fri, 02 Jul 2004 15:36:52 GMT
Karlheinz Toni schrieb:

>Hi there,
>
>Is there any possibility to set the java.home property except via the 
>
>
>ant -Djava.home="..." console parameter?
>
>I tried a properties file and set the property in the build.xml file. 
>Both entries are ignored (shown by the -verbose output)
>
>*********property file build.properties********
>java.home=/usr/local/bin/java/
>***********************************************
>
>
>************ build.xml ***********************
><property file="/usr/test/build.properties"/>
>[...]
><property name="java.home"     value="/usr/local/bin/java/"/>
>***********************************************
>
>
>**************** verbose output ***************
>[property] Loading /usr/test/build.properties
>Override ignored for property java.home
>[...]
>Override ignored for property java.home
>***********************************************
>
>  
>
AFAIK, java.home is initialized during startup, before any property 
files are evaluated. As ant cannot overwrite properties, You cannot 
overwrite the java.home property, once it is set. So if You want to use 
just one command without writing the parameter value every time, You've 
to write a shell script.

Kind regards

Peter Nabbefeld

>Any ideas?
>
>Sincerely
>Charly
>
>
>---------------------------------------------------------------------
>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