GAE: Cannot get the System Java Compiler. Please use a JDK, not a JRE

When trying to deploy my application to the Google App Engine server I get the following error: Cannot get the System Java Compiler. Please use a JDK, not a JRE.

All solutions I've seen for this involve editing an eclipse configuration file, but I'm not using eclipse. I'm executing appcfg.cmd from the dos prompt. I have a jdk installed and my JAVA_HOME is pointing to it: c:program filesjavajdk1.6.0_43

Obviously appcfg.cmd is not looking at JAVA_HOME. It must be getting the JDK location from somewhere else.

Any ideas?


正如在评论中指出的那样:确保JDK在您的PATH中是第一位的。


I had the same issue with appengine sdk 1.8.1 and sts 3.6.4.

I tried adding vm properties to sts.ini file, added %JAVA_HOME% to the beginning of the path variable. But nothing was working as I kept getting the same error.

Cannot get the System Java Compiler. Please use a JDK, not a JRE

Then I found the issue was with Windowssystem32java* file. The appengine was reading the java from Windowssystem32. There were three files.

java.exe
javaw.exe
javaws.exe

I replaced these files from JAVA JDK home as they were from JAVA JRE home during installation. After that, I restarted my sts and everything worked fine as I am able to deploy without issue.

链接地址: http://www.djcxy.com/p/72286.html

上一篇: C libcurl,限制下载速度

下一篇: GAE:无法获取系统Java编译器。 请使用JDK,而不是JRE