You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2014/07/14 19:33:47 UTC
[Bug 56720] New: Unrecognized option: -dant.home=C:\ANT\1.7.0
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
Bug ID: 56720
Summary: Unrecognized option: -dant.home=C:\ANT\1.7.0
Product: Ant
Version: 1.7.0
Hardware: PC
Status: NEW
Severity: blocker
Priority: P2
Component: Core tasks
Assignee: notifications@ant.apache.org
Reporter: August.heinsen@jpmorgan.com
Hello, for anyone attempting to reproduce this issue. I have done a base
installation of ANT 1.7.0 on a virtual desktop. ANT_HOME and JAVA_HOME are both
set to their respective homes, and my path variable includes them as well with
the bin location.
So I have not made any custom changes to the build.xml, ant.bat, etc.
>From the command line, I have inputted these two types of options:
ant
ant -version
this is the output:
Unrecognized option: -dant.home=C:\ANT\1.7.0
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
ERROR: The file is either empty or does not contain the valid choices.
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Windows\SysWOW64>ant
Unrecognized option: -dant.home=C:\ANT\1.7.0
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
ERROR: The file is either empty or does not contain the valid choices.
Just for an indicator, here is my java version so that you may see my JRE.
C:\Windows\SysWOW64>java -version
java version "1.6.0_31-rev"
Java(TM) SE Runtime Environment (build 1.6.0_31-rev-b23)
Java HotSpot(TM) Client VM (build 20.6-b02, mixed mode)
And to restate everything, I just installed the version of Ant that was
available to me for my virtual desktop. Any help is greatly appreciated!
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 56720] Unrecognized option: -dant.home=C:\ANT\1.7.0
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
--- Comment #4 from Jan Mat <ja...@materne.de> ---
What if you change your path to a minimum?
set ANT_HOME=???
set JAVA_HOME=???
set PATH=%ANT_HOME%\bin;%JAVA_HOME%\bin
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 56720] Unrecognized option: -dant.home=C:\ANT\1.7.0
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
--- Comment #2 from Charles Duffy <cd...@apache.org> ---
I've looked at the relevant source tree, and the ant.bat in upstream correctly
uses a capital -D -- and has since that line was last changed in 2006. I'd
strongly suggest checking whether you might have any local wrappers with a
higher precedence in PATH than the upstream-provided one.
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 56720] Unrecognized option: -dant.home=C:\ANT\1.7.0
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
--- Comment #5 from German Gonzalez <ge...@gmail.com> ---
Certainly, still you have "-dant.home=C:\ANT\1.7.0" in the execution of it.
if you test:
c:\where ant
what do you get ?
The best would be to set the last idea about cleaning up on the environment
variables.
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 56720] Unrecognized option: -dant.home=C:\ANT\1.7.0
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
--- Comment #3 from August.heinsen@jpmorgan.com ---
(In reply to Charles Duffy from comment #2)
> I've looked at the relevant source tree, and the ant.bat in upstream
> correctly uses a capital -D -- and has since that line was last changed in
> 2006. I'd strongly suggest checking whether you might have any local
> wrappers with a higher precedence in PATH than the upstream-provided one.
Hi Charles, when I do this check this is the PATH provided by an echo :
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Windows\SysWOW64>echo %PATH%
C:\Program Files
(x86)\Attachmate\Reflection\;C:\Windows\system32;C:\Windows;C:\
Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program
Fil
es (x86)\Citrix\ICAService\;C:\Program Files (x86)\Citrix\System32\;C:\Program
F
iles\Symantec\Workspace Virtualization\;C:\Program Files (x86)\Windows
Kits\8.0\
Windows Performance Toolkit\;C:\Program Files\Symantec\Workspace
Virtualization\
;C:\ANT\1.7.0\bin;C:\Program Files (x86)\apache-maven-3.0.3\bin\;C:\Program
File
s (x86)\Java\jdk1.7.0_04\bin
C:\Windows\SysWOW64>
I'd like to reply to comment #1 as well from you. I looked into it and it
appears that you could be right, I changed all encounters of -dant.home to
-Dant.home which was 4 lines in the batch file. It does still reproduce the
error however.
I'm not sure though of the local wrappers containing a higher precedence in
PATH, I believe that ANT is seen by my OS though. Is this what you were asking?
Hopefully that helps with the error checking. Also, I can echo out the ant.bat
to see where it is going wrong and add that in my initial post if that might
help anyone else who may reach this issue.
--
You are receiving this mail because:
You are the assignee for the bug.
[Bug 56720] Unrecognized option: -dant.home=C:\ANT\1.7.0
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=56720
Charles Duffy <cd...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
OS| |All
--- Comment #1 from Charles Duffy <cd...@apache.org> ---
The -d needs to be an upper-case -D.
Can you confirm that the distributed ant.bat contains such an error?
--
You are receiving this mail because:
You are the assignee for the bug.