I am trying to install Android SDK on windows 7 64-bit but it doesn't work. I keep getting this screen :
JAVA SE Development Kit (JDK) not found.
Error: Failed to find Java version for 'C:\Windows\system32\java.exe': [2] The system cannot find the file specified. (...)
If you believe you have a JDK installed and it was not properly recognized, simply set an environment variable JAVA_HOME to point to it.
I tried setting JAVA_HOME
to C:\Windows\System32\java.exe
(which is my install path) and it still doesn't work.
In the command line i tested the version with java -version
and it works perfectly.
Tried the old trick of back and next but sadly doesn't work.
this is so disappointing.... any suggestions?
It's JDK , not Java , it's missing. JAVA_HOME shouldn't point to the java.exe file. It should point to the jdk-folder. Typically C:\Program Files\Java\jdk1.6.0_23
or similar. If you haven't got a jdk-folder somewhere, you should install JDK from here .
Note that the official requirement for
developing for Android is JDK 6.
Setting the JAVA_HOME environment variable in System variable to C:\Program Files\Java\jdk1.7.0_07\ did solve my problem.
A couple of points to note:
A change in one of the batch files since release 16 of the Android Tools SDK is probably the culprit. Try the ZIP file instead of the EXE. Download android-sdk_r18-windows.zip from http://developer.android.com/sdk/index.html . Unzip to a new Android directory where your program files normally reside (other locations should also work). Replace find_java.bat in the Android\android-sdk\tools\lib directory with the one from the release 16 SDK tools (if you haven't got it get it from https://tekeye.uk/downloads/find_java.zip ). Using the ZIP instead of the EXE means the shortcuts and program groups won't be set up but you can run SDK Manager.exe in the android-sdk folder to grab the rest of the SDK.
Download JDK 64bit from http://www.oracle.com/tec.network/java/javase/downloads/jdk7-downloads-1880260.html
Add the system variable JAVA_HOME pointing to C:\Program Files\Java\jdk1.7.0_21
Here are the setup steps that worked for me starting from scratch (as of today - 6/26/2013)
[Setup Steps]
Part I - Java JDK
Result: Java JDK installation will be completed as expected
Part II - Android SDK (Preliminary Setup)
This is to make sure the change in environment variable will work
Part III - Android SDK
Result: Android SDK installation will be completed as expected
$COMMONFILES
etc into tools and plugins as appropriatetools/lib
, notepad find_java.bat
, notice it calls find_jave.exe
with -s
. find_java.exe -s
. It will say: Failed to convert path to a short DOS path: C:\Windows\system32\java.exe
(Which is a perfectly short path already - bizarre.)-s
from the two calls to find_java.exe
inside the.bat. Save it/tools/android.bat
Easiest solution I have Windows 7 x64 After installing Java JDK 64bit it didnt work but: After installing both x32 and x64 it worked:) Enjoy
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.