Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 85263 invoked from network); 8 Apr 2008 22:32:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 Apr 2008 22:32:18 -0000 Received: (qmail 87129 invoked by uid 500); 8 Apr 2008 22:32:14 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 87107 invoked by uid 500); 8 Apr 2008 22:32:14 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 87096 invoked by uid 99); 8 Apr 2008 22:32:14 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Apr 2008 15:32:14 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of david@davidwbrown.name designates 208.240.64.5 as permitted sender) Received: from [208.240.64.5] (HELO davidwbrown.name) (208.240.64.5) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Apr 2008 22:31:32 +0000 Received: from davidwbrown.name (davidwbrown.name [192.168.1.1]) by davidwbrown.name (Postfix) with SMTP id AC96F23C097 for ; Tue, 8 Apr 2008 17:31:44 -0500 (CDT) From: "David Brown" Subject: Re: Problem with setting JAVA_HOME for Ant To: "Ant Users List" Cc: X-Originating-IP: 192.168.1.14 X-Mailer: Usermin 1.340 Message-Id: <1207693904.13608@davidwbrown.name> In-Reply-To: <011501c899c7$af9aab70$6c00a8c0@ventripoint.com> Date: Tue, 08 Apr 2008 17:31:44 -0500 (CDT) X-Virus-Checked: Checked by ClamAV on apache.org Hello, I have found the best thing to do with Windows is define JAVA_HOME in: My Computer/System Properties dialog. Click the Advance Tab Pane and click the button: Environment Variables. Don't do this as Administrator but just as the user you are when you are running Ant at the command-line. HTH Eric Chamberlain wrote .. > I have a real mystery and cannot find the solution anywhere I have looked > (including the Ant FAQ). > > Summary: When I run Ant, it looks somewhere other than JAVA_HOME for the > java directory. > > I am running Ant on Windows XP to execute a NetBeans-generated build.xml. > > One step I have tried has been to run > > ant -diagnostics > > Which confirms that java.home is located somewhere other than JAVA_HOME (not > even in the same directory tree). > > Here is my question: How can I change the value of java.home for ant? > What .properties file do I have create? Why does ant ignore it if I type > > ant -Djava.home=%JAVA_HOME% -f mybuildfile.xml > > I was expecting to override the java.home there but it didn't happen. > > I am left rather puzzled. > > Eric Chamberlain > Software Engineer > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org