find java.exe,Find_java.exe在Android SDK中没有找到的Java

I've definitely got JDK 1.6.0 installed in C:\Program Files\Java\jdk1.6.0_35, but it never seems to be able to find it when I try to open the SDK Manager. In task manager, find_java.exe shows up until I stop it (will run for hours).

Are there some environment variables I have to set for this to work?

解决方案

As you are using Windows system, use following way to set your JAVA_HOME and CLASSPATH Environment variables.

Windows XP

Select Start, select Control Panel. double click System, and select the Advanced tab.

Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.

In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Windows Vista:

From the desktop, right click the My Computer icon.

Choose Properties from the context menu.

Click the Advanced tab (Advanced system settings link in Vista).

Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.

In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Windows 7:

From the desktop, right click the Computer icon.

Choose Properties from the context menu.

Click the Advanced system settings link.

Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.

In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Now in Addition for the Linux Based System following steps used to set JAVA_HOME and CLASSPATH variables,

Open root folder

From the View Menu , ticK "Show Hidden Files" , or press Ctrl + H.

Now you can see a system hidden file called .bashrc

Right click and open it editor, and write following command at the end.

PATH=$PATH:/opt/jdk1.6.0_21/bin

export PATH

JAVA_HOME=/opt/jdk1.6.0_21

export JAVA_HOME

NDK_HOME=/opt/android-ndk-r8

export NDK_HOME

Save and Exit.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值