While running
sencha app build production
I am getting the following error:
Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion'
has value '1.8', but '1.7' is required. Error: could not find java.dll Error: Could not find Java SE Runtime Environment.
java -version
, command is showing following:
java version "1.8.0_40" Java(TM) SE Runtime Environment (build 1.8.0_40-b26) Java HotSpot(TM) 64-Bit Server VM (build 25.40-b25, mixed mode)
Not able to find where path is going wrong. Any idea?
----------------------- EDIT ------------------------------------------------
Note: I am using Windows 7 (64 bit).
I have tried uninstalling the sencha touch cmd and reinstalling. But still same error.
I have uninstalled all the java version instances and reinstalled the latest one, Still the problem persist.
I've had the same problem. Simple solution that worked for me is to rearrange the entries in the
PATH
forJRE/JDK
. This problem started to appear after installingJRE 8
whose installation has put some executable files inSystem32 or SysWOW64
directories, these executable files are messing up. To resolve the problem:Create environment variable pointing to JDK home as
JAVA_HOME
.set JAVA_HOME=C:\Progra~1\Java\jdk1.8.0_45
Put the entry
%JAVA_HOME%\bin
at start in your PATH environment variable. Appending existing value ofPATH
. For example:path=C:\Program Files\Java\jdk1.8.0_45\bin;%path%