Okay, so I'm trying to get an initial build of the NME sample files onto an Android device.
I can build for platforms such as HTML5, Flash and Windows, but I can't get it onto Android - I always get errors back that say:
Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
Is is currently set to "C:\Program Files (x86)\Java\jre7"
Okay - obvious enough right? But I've checked, rechecked, restarted, edited environment variables and made absolutely sure that the JAVA_HOME
variable is actually pointing at the JDK.
Any explanations?
Well, to answer my own question, I eventually found that there's an .hxcpp_config.xml
file in my user account (C:\Users\James\
), and that has an XML node which looked like this:
<set name="JAVA_HOME" value="/SDKs//java_jdk" />
I've changed it to this:
<set name="JAVA_HOME" value="C:\Program Files (x86)\Java\jdk1.6.0_29" />
And it works!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With