执行蚂蚁清理,构建失败,错误的Java版本

问题描述 投票:1回答:3

我正在尝试安装hybris,但是在安装时,我在执行ant clean命令时遇到问题。

我使用的应该是最新版本的Java。我也在正确的路径中使用了setantenv.bat。

这里是堆栈跟踪:

Apache Ant(TM) version 1.9.1 compiled on May 15 2013

C:\work\trail\hybris\bin\platform>**ant clean**
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=128M; support
s removed in 8.0
Buildfile: C:\work\trail\hybris\bin\platform\build.xml
     [echo] C:\work\trail\hybris\bin\platform/tomcat/bin

**BUILD FAILED**
C:\work\trail\hybris\bin\platform\build.xml:20: The following error occurred w
le executing this line:
C:\work\trail\hybris\bin\platform\resources\ant\antmacros.xml:73: The followin
error occurred while executing this line:
C:\work\trail\hybris\bin\platform\resources\ant\util.xml:234: -

**** **WRONG JAVA VERSION** ****

 Environment check failed: You are using a not supported version of Java.
 Please make sure you are using Java version 1.7 or later.
 Your current Java version is: 1.8.0_40

 TIP: If you are using eclipse you can configure a different JVM under
 Preferences->Java->Installed JREs.

Total time: 1 second
java ant hybris
3个回答
0
投票

0
投票
尝试执行此操作,在platfrom文件夹下的util.xml中添加Java版本。为我工作!
© www.soinside.com 2019 - 2024. All rights reserved.