Leiningen tried to call Java. Net from the wrong / missing JDK exe
Some time ago, two versions of JDK (1.7.0_09 and 1.7.0_51) were installed on my PC Then I uninstalled the previous one Now, when I try to run lein run (even with a virtual project), I receive the following message:
java.io.IOException: Cannot run program "C:\Program Files\Java\jdk1.7.0_09\bin\java.exe" (in directory "<...>"): CreateProcess error=2,The system cannot find the file specified
What can I do to make lein use the correct JDK? Java is not set_ Home and JDK_ Home variable
Solution
Check the following settings:
>Does Java - version display the correct version? > System variable Java_ HOME,JDK_ HOME,JAVA_ CMD or lein_ JAVA_ Does CMD point to the wrong JDK? > Does your leiningen project configuration file have Java CMD settings that enforce specific JVMs? > Your leiningen user profile ~ / lein / profiles. Does clj have Java CMD settings? > Is the JDK of the IDE project correct when using the IDE with built-in leiningen? > Is it right for lein sh / lein. Bat changed?