JAVA_HOME 或 PATH 还是两者? [英] JAVA_HOME or PATH or BOTH?

查看:71
本文介绍了JAVA_HOME 或 PATH 还是两者?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在观看 Android 开发视频,他们要求我们安装 JDK 并创建 JAVA_HOME 环境变量.我已经安装了 MyEclipse 并且我之前已经设置了 PATH 变量(给它 JDK 的目录),我还需要一个 JAVA_HOME 变量吗???如果是,那为什么???

I was watching the Android development video and they asked us to install JDK and create JAVA_HOME environment variable. I already have MyEclipse installed and I previously had setup the PATH variable(giving it the directory of JDK), do I still need a JAVA_HOME variable ??? If yes then why ???

推荐答案

如果您正在使用的应用程序正在 JAVA_HOME 环境变量中寻找特定数据集,但它不存在,它是不会幸福的.

If the application you are using is looking for a specific dataset in the JAVA_HOME environment variable and it isn't there, it is not going to be happy.

其他应用程序可能会在 PATH 环境变量中查找 JDK 路径,但仅仅因为您在那里拥有它并不意味着它适用于需要它在单独变量中的其他应用程序.

Other applications might look for the JDK path in the PATH environment variable, but just because you have it there doesn't mean it will work for other applications that need it in a separate variable.

这篇关于JAVA_HOME 或 PATH 还是两者?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆